I have managed to reduce the used D/IRAM from 137,323 to 110,855 leaving me 77,561 (on an ESP32-S2 ESP-IDFv4).
I need to reduce the RAM because soft app provisioning is now failing irregularly because it cannot allocate the memory for the httpd_server task when setting up soft app provisioning.
The thing is, my code is using very little memory, but a bunch of the ESP components grab huge chunks.
Looking for help on what to trim and how.
This is what the size-components looks like.
https://docs.google.com/spreadsheets/d/ ... sp=sharing
And when I start soft app provisioning this is what happens:
Code: Select all
E (16068) wt_wifi_prov: About to start provisioning
Heap summary for capabilities 0x0000180E:
At 0x3ffcd110 len 192240 free 48404 allocated 137388 min_free 20148
largest_free_block 24564 alloc_blocks 390 free_blocks 13 total_blocks 403
At 0x3fffc000 len 14864 free 13096 allocated 0 min_free 13096
largest_free_block 13044 alloc_blocks 0 free_blocks 1 total_blocks 1
Totals:
free 61500 allocated 137388 min_free 33244 largest_free_block 24564
I (16108) wifi:state: run -> init (0)
I (16108) wifi:pm stop, total sleep time: 10462756 us / 13473309 us
W (16118) wifi:<ba-del>idx
I (16118) wifi:new:<9,0>, old:<9,0>, ap:<255,255>, sta:<9,0>, prof:1
E (16168) osal.h: Requesting httpd_server task with stackSize=4096 bytes
Heap summary for capabilities 0x0000180E:
At 0x3ffcd110 len 192240 free 19528 allocated 165904 min_free 19528
largest_free_block 12276 alloc_blocks 420 free_blocks 12 total_blocks 432
At 0x3fffc000 len 14864 free 13096 allocated 0 min_free 13096
largest_free_block 13044 alloc_blocks 0 free_blocks 1 total_blocks 1
Totals:
free 9880 allocated 188528 min_free 9552 largest_free_block 4084
E (16238) osal.h: Could not return Task ret=-1
William