This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Best way to save sensor data with FDS?

Hi,

I want to collect sensor-data, save it to flash and access it later. I´m not quite familiar with ways to save data and get a little bit confused by the fds library (but already managed to save and retrieve data).

Let`s say I want to save an int32 every minute. If i give each value a Record Key and a File ID am I right, that I have 12 byte of record header for every value?

My next Idea was to store the values in an array, and then save it. So I only get the header once per array. Is this the way to go? Are there any recommendations to the array size?

Or is there a way I can just add my data at the end of the already stored data under the same Record Key and File ID?

If I access my data I never need to access a specific part of it. I just need everything in the order it was saved, so I can send it to my android app, the rest is done there.

Thanks for your help :)

P.S.: I use SDK 13

Related