esp8266 crashes when code in .irom.text over 192k
Posted: Tue Jul 21, 2015 2:08 am
My firmware is getting a bit larger now. I was under the impression I would have 240 kbyte of space for my program (excluding the part in iram). Linker script says 3c000, which is 240 k. The linker also doesn't complain. Esptool.py also doesn't complain.
BUT as soon as the code reaches 192 k in size (EXACTLY there, very suspicious, 0x30000 exact), the whole code won't run. Something very early in the boot process, because the UART doesn't show anything usable, just a few characters of noise. Nothing happens. Normally my code will spit some text on the UART pretty quick.
Then reduce the code size to < 192k and it runs.
Also very suspicious that it's 256k - 64k, which is two times the amount of iram available. I understand one looses 1 time that amount, but not two times.
This is with the latest SDK (1.2.0) and with opensdk + esptool.py.
On a side note, apparently half of the flash memory is reserved for OTA-updating. I am not going to do that. Anyone knows how to disable the OTA function and use all of the flash memory? Is it something like just changing the section size in the linker script?
Thanks!
BUT as soon as the code reaches 192 k in size (EXACTLY there, very suspicious, 0x30000 exact), the whole code won't run. Something very early in the boot process, because the UART doesn't show anything usable, just a few characters of noise. Nothing happens. Normally my code will spit some text on the UART pretty quick.
Then reduce the code size to < 192k and it runs.
Also very suspicious that it's 256k - 64k, which is two times the amount of iram available. I understand one looses 1 time that amount, but not two times.
This is with the latest SDK (1.2.0) and with opensdk + esptool.py.
On a side note, apparently half of the flash memory is reserved for OTA-updating. I am not going to do that. Anyone knows how to disable the OTA function and use all of the flash memory? Is it something like just changing the section size in the linker script?
Thanks!