Skip to content

Latest commit

 

History

History
78 lines (57 loc) · 1.59 KB

raspberry-pi3.md

File metadata and controls

78 lines (57 loc) · 1.59 KB

Running Flic Daemon

Development

sudo ~/projects/fliclib-linux-hci/bin/armv6l/flicd -f flic-db.sqlite3 -w -s 0.0.0.0

Production

sudo ~/projects/fliclib-linux-hci/bin/armv6l/flicd -f flic-db.sqlite3 -w -d

Raspberry Pi Config

sudo raspi-config

Raise Volume of Raspberry Pi

alsamixer

Install Dependencies

curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list

sudo apt update
sudo apt install -y htop curl git software-properties-common
sudo apt install -y --no-install-recommends yarn

git clone https://github.com/creationix/nvm.git ~/.nvm
sudo echo "source ~/.nvm/nvm.sh" >> ~/.bashrc && sudo echo "source ~/.nvm/nvm.sh" >> ~/.profile
bash

nvm install stable
npm i -g pm2@latest
pm2 completion install

pm2 startup
pm2 save

sudo apt -y dist-upgrade
sudo apt-get -y autoremove


mkdir scripts

nano scripts/scan-new-clients.sh
#!/bin/bash
node ~/projects/fliclib-linux-hci/clientlib/nodejs/newscanwizard.js

nano scripts/start-flic-daemon.sh
#!/bin/bash
sudo ~/projects/fliclib-linux-hci/bin/armv6l/flicd -f ~/flic-db.sqlite3 -w -s 0.0.0.0 -d
crontab -e
@reboot /home/pi/scripts/start-flic-daemon.sh

Can instead use sudo raspi-config > Network Options > Wi-Fi

sudo su -
wpa_passphrase "ssid" "password" >> /etc/wpa_supplicant/wpa_supplicant.conf
wpa_cli reconfigure