tar -zxvf ...
locate IP adress of router
ifconfig
find the IP adress of the RPi by scanning the IP of the router
nmap -F 192.168.178.1-254
ssh to the RPi
Shutdown safely
shutdown -h now
# then pull out the power cable
Restart
shutdown -r now
Once raspbian is setup we do the digital ocean initial server setup https://www.digitalocean.com/community/tutorials/initial-server-setup-with-debian-8
-
Demo blink the LED
-
Demo read button
-
Build the sensor Follow https://thingsboard.io/docs/samples/raspberry/temperature/
python3 -m venv ~/venv
source ~/venv/bin/activate
sh install_librairies.sh
if there is a problem at this stage sudo chown -R pi ~/venv/lib/python3.5/site-packages/
Modify if needed electronics.py
with the help of https://pinout.xyz/
python electronics.py
Understanding the concept of MQTT:
- mosquitto_sub -d -t ifp_mqtt
- mosquitto_pub -d -t ifp_mqtt -m "Hello IFP"
Demo of posting sensor data to MQTT:
- first tab
python mqtt_subscriber.py
- second tab
python mqtt_publisher.py
Getting a dashboard:
python publish_to_thingsboard