Using Flash Memory while also using Autoconnect

Imstarboard
Posts: 6
Joined: Thu Sep 17, 2020 3:17 pm

Using Flash Memory while also using Autoconnect

Postby Imstarboard » Sun Jan 03, 2021 2:38 pm

The tutorials I have found for storing and retrieving flash memory on the ESP32 only provide examples that presume you are not using flash for anything else.

I am using autoconnect (hieromon.github.io/AutoConnect)... can someone explain and provide links to sample code where I can learn to store and retrieve small amounts of data in flash without interfering with autoconnect?

Thanks in advance!

ESP_Sprite
Posts: 9759
Joined: Thu Nov 26, 2015 4:08 am

Re: Using Flash Memory while also using Autoconnect

Postby ESP_Sprite » Mon Jan 04, 2021 1:45 am

You probably want to use Preferences (which maps to NVS on the ESP-IDF side, which saves things to flash)

Imstarboard
Posts: 6
Joined: Thu Sep 17, 2020 3:17 pm

Re: Using Flash Memory while also using Autoconnect

Postby Imstarboard » Tue Jan 05, 2021 12:00 am

Thanks - can you share any links that might get me started in the right direction with this?

ESP_Sprite
Posts: 9759
Joined: Thu Nov 26, 2015 4:08 am

Re: Using Flash Memory while also using Autoconnect

Postby ESP_Sprite » Tue Jan 05, 2021 1:39 am

Sorry, not really - I don't use Arduino myself. You can put 'esp32 arduino preferences example' in your favorite search engine to get some useful examples.

ESP_Minatel
Posts: 364
Joined: Mon Jan 04, 2021 2:06 pm

Re: Using Flash Memory while also using Autoconnect

Postby ESP_Minatel » Tue Jan 05, 2021 9:04 am

Maybe you can have a look at this lib: https://github.com/rpolitex/ArduinoNvs

If you're using PlatformIO you can easily import to your project.

https://platformio.org/lib/show/5989/ArduinoNvs

Who is online

Users browsing this forum: Baidu [Spider] and 48 guests