[SOLVED]Porting from esp-idf v3.3.4 to v4.2 increase bin size
Posted: Tue Feb 09, 2021 1:56 pm
Hi everybody,
For one of our products we decided to switch esp-idf from v3.3.4 to v4.2.
I installed all new toolchains and created a new project, setup cmake, configured SDKCONFIG trying to have the same options (or at least I think so) as the previous one: I have onlyremoved "Heap memory debugging" and disabled options for WiFi IRAM optimization (otherwise I have problem of IRAM0 overflow).
After compilation I discovered a big increase in size of the bin file. Just to compare:
esp-idf V3.3.4
esp-idf V4.2
A difference of about 300Kb!!
Source code are the same, except for modification of the new WiFi init which requires "esp_netif_init" instead of "tcpip_adapter_init".
Is there any guide for "safe" migration from esp-idf v3.3 to v4.2?
Or any hint to follow?
Thank you!
For one of our products we decided to switch esp-idf from v3.3.4 to v4.2.
I installed all new toolchains and created a new project, setup cmake, configured SDKCONFIG trying to have the same options (or at least I think so) as the previous one: I have onlyremoved "Heap memory debugging" and disabled options for WiFi IRAM optimization (otherwise I have problem of IRAM0 overflow).
After compilation I discovered a big increase in size of the bin file. Just to compare:
esp-idf V3.3.4
Code: Select all
Total sizes:
DRAM .data size: 18384 bytes
DRAM .bss size: 47424 bytes
Used static DRAM: 65808 bytes ( 58772 available, 52.8% used)
Used static IRAM: 124313 bytes ( 6759 available, 94.8% used)
Flash code: 1156481 bytes
Flash rodata: 250232 bytes
Total image size:~1549410 bytes (.bin may be padded larger)
esp-idf V4.2
Code: Select all
Total sizes:
DRAM .data size: 22760 bytes
DRAM .bss size: 68208 bytes
DRAM other size: 12 bytes (.noinit)
Used static DRAM: 90980 bytes ( 33600 available, 73.0% used)
Used static IRAM: 101011 bytes ( 30061 available, 77.1% used)
Flash code: 1365283 bytes
Flash rodata: 293960 bytes
Total image size:~1851234 bytes (.bin may be padded larger)
Source code are the same, except for modification of the new WiFi init which requires "esp_netif_init" instead of "tcpip_adapter_init".
Is there any guide for "safe" migration from esp-idf v3.3 to v4.2?
Or any hint to follow?
Thank you!