You can chat about native SDK questions and issues here.

User avatar
By Atlantis
#69082 I need some help with saving my data to flash memory.
I have struct containing my configuration data and I would like to save it into flash memory and then load into RAM during init of module.
As far I know, on Arduino I could use EEPROM library, but I prefer native SDK.
I know there are specialized functions:

spi_flash_erase_sector()
spi_flash_write()
spi_flash_read()

Most important question is where should I save my data? Which sector/address should I use to do it safely, without messing up my program?

I don't know if it is important, but I am using esphttpd library, so there is already compressed file system with webpages loaded into my module.