Skip to content

Notes regarding the website

hydrogen602 edited this page Apr 1, 2019 · 2 revisions

Data Feed Page

dataCollection.py reads sensor data and writes it to a json every minute.
dataSheet.html calls dataGetter.js which GET requests the json and places it into the table of dataSheet.html. dataSheet.html and dataGetter.js should be in /var/www/html.
The python program will be in /var/www/scripts.
Right now both dataCollection.py and dataGetter.js are configured to update every 10 minutes.

Possible Problems

dataGetter.js always fetches the entirety of the json file, which may become a problem if the code is run for a couple of hours or longer, as by then it will have a couple of hundred entries.
All three pieces of code are currently only for time and temperature, they all must be updated to include more data fields.

Location on GitHub

Can be found under code/web or code/sensors

dataSheet.html and dataGetter.js

Right now supports only time + temperature. Possible additions would be rotation (x,y,z) and acceleration (x,y,z) or also the raspberry pi's internal temperature.

Clone this wiki locally