Eclipse spiffs

MPCEngineer
Posts: 3
Joined: Tue Jul 28, 2020 2:42 pm

Eclipse spiffs

Postby MPCEngineer » Tue Jul 28, 2020 3:02 pm

Hi,

I am using eclipse to debug the ESP32 and its working great.

My problem is when I try to use spiffs.

I have included the line

spiffs_create_partition_image(my_partition ./data FLASH_IN_PROJECT )

in the base project CMakeLists.txt and I also have a folder data in the base project folder.

I keep getting the error Failed to create SPIFFS image for partition 'my_partition' and also Check project configuration if using the correct partition table file.

Any ideas?

Thanks.

MPCEngineer
Posts: 3
Joined: Tue Jul 28, 2020 2:42 pm

Re: Eclipse spiffs

Postby MPCEngineer » Wed Jul 29, 2020 8:20 am

Hi.

I have changed the sdkconfig to use a custom partition table csv and have included a partitions.csv file in the project base directory.

When I build the project using eclipse the output shows the new partition table.

Then I debug the project openOCD flashes the project and it runs okay but I can see from the bootup messages that the partition table has not been changed to the new one.

Questions:
1) Can openOCD flash a new partition table. How can this be done from eclipse?
2) I changed the flash size in sdkconfig to 4Meg but the boot messages when debugging the project say the binary image header is set to 2048K

Many Thanks,

MPC

MPCEngineer
Posts: 3
Joined: Tue Jul 28, 2020 2:42 pm

Re: Eclipse spiffs

Postby MPCEngineer » Wed Jul 29, 2020 9:00 am

Hi,

Found how to use eclipse with spiffs.

You have to add the following two lines to the debug configuration, Startup

mon program_esp ${workspace_loc:Spiffs/build/partition_table/partition-table.bin} 0x8000 verify
mon program_esp ${workspace_loc:Spiffs/build/storage.bin} 0x110000 verify

Where Spiffs is your project name and storage.bin is the binary file created by the following line added to your CMakeLists.txt

spiffs_create_partition_image(storage ../spiffs_image FLASH_IN_PROJECT)

partition-table.bin is created from your partitions_example.csv provided you have changed the sdkconfig to use a custom partition table.


Enjoy.....

Who is online

Users browsing this forum: No registered users and 2 guests