"druck" wrote in message
news:rjd29r$5pj$1@dont-email.me...
> On 10/09/2020 10:55, NY wrote:
>> "The Natural Philosopher" wrote in message
>> news:rjcjf8$kee$1@dont-email.me...
>>> I have a yen to make a weather station as well, one day.
>>
>> I have a Davis Vantage Vue weather station (a remote sensor unit which
>> measures wind speed/direction, rainfall amount/rate, outside temperature
>> and humidity) and communicates these to a base station by radio link
>> (proprietary, not wifi). The base station has a USB output.
>
> I've got an Oregon Scientific weather station which can communicate with
> an Android app via Bluetooth LE. Someone reverse engineered the protocol,
> so I can use a Python program on a Pi to download temperature, humidity
> and pressure readings. I combine these with readings from Htu21d and
> BME280 I2C sensors on other Pi's which are around the house and shed, and
> log to an SQLite database.
>
>> Some time, I will investigate uploading the data to an SQL database on
>> the server so a PHP program can extract and display graphs of specified
>> parameters over a specified interval of time.
>
> I've got another Pi running nginx web server with uwsgi, so it can use a
> Python program (rather than PHP) to retrieve data from the SQL database
> and generate HTML+javascript to plot it using Google charts.
Yes the only bit I haven't cracked is running a process on the Pi that
uploads data to the web server (maybe in daily batches, maybe every 10
minutes when a new entry is added to the local log file on the Pi) so as to
add it to the SQL table. Doing it manually is easy enough from cPanel
accessed by web page (LOAD DATA INFILE from a file on the Pi or Windows
PC) - I've done it for a big database of WWI soldiers' details that my
parents gradually add to as they do research, so I save an Excel spreadsheet
as a CSV file, wipe the SQL table of its existing data, and then upload the
whole lot again (including additions and changes). It would be nice to find
a way of automating this, preferably so it only uploaded data that it
doesn't already have.
Extracting the data - selected fields between selected dates - and passing
it to Google Charts is easy enough: I can use a variant of the PHP code that
my parents' website uses to extract data, and I've already worked out a
specimen Google Chart, though I wonder where I put that code...
It's so we can see graphs over a longer period of time than the last 48
hours that I've configured into Cumulus.
The hosting is on GoDaddy (which I always want to call Big Daddy!).
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|