Store data in different time intervals then upload them all to cloud every 24 hour

Hello,

My device is Particle ELECTRON, I need to read different data in different time intervals, and publish them to the cloud every 24 hours.
i.e read data1 and data 2 in 2 hours, but data 3 in every 6 hours, and then after 24 hours, all the data need to be published to the cloud at once.
Furthermore, these data need to be stored in spreadsheet as well.

I’ve been using ThingSpeak API to grab the data and export to spreadsheet, and using EEPROM to store all the data then pull them out every 24 hours.
However, when I use EEPROM to pull the data out, I can’t send them to ThingSpeak channel for analysing.
I use the Time.hour() function to guide the scheduling process, but this isn’t working somehow.
Does anyone has a better solution for this, please let me know!
Thanks!

This is not clear. It shouldn’t matter where you store the data, only the form of the data should matter to the ThingSpeak API.[quote=“Aliza, post:1, topic:36980”]
I use the Time.hour() function to guide the scheduling process, but this isn’t working somehow.
[/quote]

You nee to say what result you’re getting from Time.hour(), not just that it isn’t working. Posting your code would be helpful.

2 Likes