opendata-stuttgart / sensors-software

sourcecode for reading sensor data
572 stars 311 forks source link

Store the last 40 measurements in JSON file #940

Open githubtobi opened 2 years ago

githubtobi commented 2 years ago

Hi there, Thank you for your work and effort you put into this projects. It's just awesome. I am running it with a SDS011, a BMP280 and a HTU21D. It's running stable since a looong time.

Now I ran into an issue and maybe you have an idea.

The Wifi of one of the stations is shut down from 23:00 - 07:00 and so the device is not sending measurements or storing last measurements.

Is there any way to do this? I know that there is very limited space on the device but I am talking about 4 measurements per hour, so 32 measurements until it's beeing reconnected to Wifi. I also don't care how it's stored. In the json or stored in a temp way in the html webinterface (maybe display always the last 40 measurements). I can scrape the data then via html, that's not an issue.

I quickly browsed through the code but couldn't find a quick solution.

pjgueno commented 2 years ago

It is not possible because you would also have to change the API and the database. The WiFi has to stay on. Maybe you could use a 4G router.