Hello,
I' trying to get data back from flukso.net with CURL and the API from Flukso but I have some trouble to get all data back in one time.
I'm using this request : curl -k -v -X GET -H "Accept: application/json" -H "X-Version: 1.0" -H "X-Token: mytoken" "https://api.flukso.net/sensor/mysensorid?start=1419418800&unit=lpermin&resolution=minute"
The timestamp = 24/12/2014 à 12:00:00 but in the JSON data, the first data begin at 1421869380 (now : 21/1/2015 à 20:43:00)
What's wrong ?
Thank you,
Fabrice
Perhaps you're simply requesting too much data at a time. Since 24 Dec there have been over 40,000 minutes. Start with specifying no interval and then slowloy expand your interval.
Hi, I changed the request but it's the same problem, with resolution set to minute I can only get the last 24h.
Simply because there is not more data on minute base stored; it's a round robin database that aggregates and overwrites data to save space; if you want to store more detailed data you have to take care for yourself or look at tmpo: https://www.flukso.net/content/time-series-file-format-fluksometer - which I actually haven't achieved to get running (since I don't want to install half the internet to just get a numeric library working)...
I try with the tmpo python script, but there is no data... with the sample code it works but with my id and token not.
s.list() return
[[], []]
@fabricemedol Your FLM is running the latest official firmware (r232). If you want to experiment with tmpo, we can upgrade your FLM to r24x remotely.
@gebhardm It's not that you have to copy the bits by hand. Just run (a.o.) these commands on your Linux box and go for a coffee break:
@icarus75 thank you for your proposition but I'll stay with the r232 firmware. All is running perfectly.
@gebhardm, I'm using your persist.sh script to get all MQTT message from Flukso and push it to a mysql server on my synology (I changed the adress of the mysql server on your script and it works perfectly !)
Thank you.
There is a way to show water, gaz and electricity on a single graph ?
@FabriceMedol - the "combined" script does just that; there is a node.js capability available for Synology NAS drives directly from its package management, thus https://github.com/gebhardm/flmdisplay/tree/master/combined should also work on this - it makes no differentiation between sensor types... The "higher sophisticated" version evolved with https://github.com/gebhardm/flmlocal
@gebhardm unfortunatly my Synology doesn't support nodejs ds213+