Scenario
I am using emoncms to store central heating data (temp, demand and setpoint) from a wiser heating controller very similar to their cloud but offline on a private network. They don’t allow uploading or downloading of the raw data.
demand and setpoint are PHPTimeseries as there is very little data and it changes slowly. Demand is potentialy only 9 data points a day. I did try writing demand and setpoint every 30 mins even if they don’t change and that helps a bit.
I am using graphs to look at the data
The temp is PHPFina every 5 mins and graphs beautifully over all time intervals
The setpoint has some major issues with missing data when showing 24 hours of data, the week view is even worse
The CSV Output for the setpoint when showing 24 hours fails to show multiple data points
Minimal interval for the setpoint data is 15 seconds, max 30 mins
Digging into the json query for Reload the 24 hours
If I change the query to reduce the interval to 15s
then the data appears, the csv says its there and the setpoint graph is correct
if I try and look at the week view then I get a mangled graph by default
if I try and drop the interval for the week view then I get
Request error: request datapoint limit reached (8928), increase request interval or reduce time range, requested datapoints = 60576
I have double checked that all the data is there by using data_downloader.py and convert_to_csv.py scripts to dump the PHPTimeseries data
screen shots and raw data available on request
What I think is involved
This could be the json download and/or the graph module. As it will graph OK if the interval is 15 I am leaning towards the json. So I may have raised this issue in the wrong place
Why I think its happening
A PHPTimeseries does not have a fixed interval so trying to download the data using one could be a mistake in three ways.
The downloaded data is
- going to be full of nulls
- massive for longer time periods and could easily hit the max download limit
- potentially missing data if the interval is too long.
It would produce a much more efficient and complete response if it just gave you the actual data points from a PHPTimeseries feed between the start and end time.
That should totally eliminate interval issues. Probably best to limit max results to 8928 just in case someone is using the wrong time series.
Possibly the interval graph options should be hidden for a PHPTimeseries feed
What do you think about my conclusions ?
I might have a look at the code myself if pointed in the right direction and if this is the right way to fix this