ESP32 Flash Download Tool

selec1
Posts: 3
Joined: Tue Apr 06, 2021 7:40 am

ESP32 Flash Download Tool

Postby selec1 » Tue Apr 06, 2021 7:46 am

Hello,

I am trying to upload firmware to my ESP32 using Flash Download Tool. Project is created in PlatformIO using Arduino framework
Everything works fine when I add 4 files with their addresses (bootloader @0x1000, partitions @0x8000, boot_app @0xe000, and firmware @0x10000), but when I use CombineBin command, it erases my NVS.
I know that CombineBin erases everything that is not defined, but how I can keep my NVS partition? Is there any way to "skip" this part of flash when combining all files in single .bin?

Thanks!

chegewara
Posts: 2364
Joined: Wed Jun 14, 2017 9:00 pm

Re: ESP32 Flash Download Tool

Postby chegewara » Wed Apr 07, 2021 9:28 pm

Hi,

no, there is no such option, because all files are combined into 1 big file/image, which is most like flashed from address 0x0000. I am saying probably, because its natural logic, which i also found in adafruit script that is combining files with python script, but i am not sure.

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: ESP32 Flash Download Tool

Postby ESP_Angus » Thu Apr 08, 2021 8:29 am

Hi selec,

chegewara is right, the only way to "skip" part of the flash is to flash two files (which can still be done in a single command) so that the range with nvs_flash isn't covered by the file contents.

The "combined binary" is a plain binary file where any gaps are filled with 0xFF, so this will write over any parts of the flash in between the different addresses of the input files.

If you flash the input files individually (can still be at the same time), the gaps are preserved.

selec1
Posts: 3
Joined: Tue Apr 06, 2021 7:40 am

Re: ESP32 Flash Download Tool

Postby selec1 » Thu Apr 08, 2021 10:48 am

Thank you both for answers.

Who is online

Users browsing this forum: Bing [Bot], mikemoy and 94 guests