Best way to store structure on flash?

newsettler_AI
Posts: 75
Joined: Wed Apr 05, 2017 12:49 pm

Best way to store structure on flash?

Postby newsettler_AI » Sat Dec 01, 2018 3:25 pm

I have such structures:
  1. typedef struct my_data_single_s
  2. {
  3.     char uid[20];
  4.  
  5.     struct connection_s{
  6.         char param_1[15];
  7.         char param_2[20];
  8.     }connection;
  9.  
  10.     struct measurement_s{
  11.         uint32_t timestamp;
  12.         char  name[50];
  13.         float longitude;
  14.         float latitude;
  15.         float offset;
  16.         float value_1;
  17.         float value_2;
  18.     }measurement;
  19.  
  20. }my_data_single_t;
  21.  
  22. typedef struct my_data_total_s
  23. {
  24.     history_single_t ID[100];
  25. }my_data_total_t;
total size is 13200 bytes.

In my project I'm using SPIFFS already.
Is it good way to use it or better go with something another?

NVS may be too small for it. FatFS - I dont see benefits from spiffs (I may be wrong).

Who is online

Users browsing this forum: fly135 and 12 guests