Scripts and some background information for the Masterclass Dashboards held during the Data-Driven Duurzaam in Manufacturing meeting [20240228]
The presentation, with some extra slides which give some hints about making a dashboard is here also available.
Code running on the picopi. All the files in this folder are already present on the device. At the school nothing has to be done.
If you want to run the device on another network, change the settings.toml
file (a normal text file, editable by notepad++ or any other text-editor), specifically:
WIFI_SSID
WIFI_PASSWORD
The other settings can be changed if you move to another MQTT-broker.
If you want to do something completely different with the device, Pico Projects is a nice place to start.
The code relies on the Adafruit Circuitpython MQTT library:
Running the dashboard in the cloud, with only a dependency on HiveMQ makes it impossible to store data or look back at certain time intervals. There is no data storage, only a stream of data from the sensor to the Grafana dashboard.
If you want to store the data a database setup is required. One option is influxdb. They provide a cloud-version (paid), but also a open-source version which can be configured using Docker containers. There are many guides on the internet on configuring a MQTT broker, database and visualization program on a (home)server. For example MQTT - Influx - Grafana.
For this demonstration project the configuration of docker and setting up the servers is too advanced.