Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Application crashed with core panic #207
My current Application crashed with the last version of arduino-esp32. Last Friday, everything worked very well. I cloned the last version this morning, started get.exe etc. everything looks good. The Application compiles fine & upload finishes with no errors, but immediately after upload:
ets Jun 8 2016 00:22:57
rst:0x10 (RTCWDT_RTC_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
Connecting to SmartCubeAP
Backtrace: 0x40008155:0x3ffcf510 0x40007d16:0x3ffcf530 0x40097144:0x3ffcf570 0x400f3a5c:0x3ffcf5c0 0x400ed50f:0x3ffcf5e0 0x400d14fe:0x3ffcf610 0x400d155a:0x3ffcf640 0x400d15d3:0x3ffcf660 0x400d0ed7:0x3ffcf760 0x400d0f37:0x3ffcf790 0x40105a3a:0x3ffcf7b0
ExceptionDecoder give me this:
Decoding 11 results
For me this issue just appear after some normal use. So I revert a lot of commits and the problem continues. The ESP just back to work after flash a blank bin. Now it's working fine with last version of this git and I am not sure where is the bug.
hmm... this is rather strange, though I have a clue where is the problem, I'm not exactly sure why it happens. I slightly changed the partition scheme which made NVS smaller with 8K and some data does stay there, but at the same time I made that change when I enabled WiFi data to be stored in NVS, so in theory, unless you had run at some point with setting to NVS, you should have been fine.
I'm thinking of spending some time soon and making an IDE plugin to easily wipe, reflash and so on.
referenced this issue
Feb 20, 2017
We happened to figure out the root cause of this issue today.
In some cases, when the board was first used with the default non-OTA partition table, and was later used with OTA-enabled partition table, NVS partition may be corrupted after some time (or immediately after such an update).
In the non-OTA partition table, NVS was allocated 6 sectors of space. But in the OTA-enabled partition table, NVS is allocated only 4 sectors. This means that when partition table is changed, NVS library will only "see" the first 4 sectors of the old 6-sector partition.
One of the invariants maintained by the NVS is that it always has at least one spare sector which is not used to store data, but is used when moving things around. When NVS partition is cropped from 6 sectors to 4 sector, it is possible that the only spare sector is no longer part of NVS partition. NVS didn't check this invariant upon initialization, and would only error out with
We will update NVS to detect and handle the case of cropped partitions better, when possible, and we will update NVS documentation with the instructions about dealing with those issues. In the meantime, consider erasing flash using
referenced this issue
Mar 14, 2017
I should have done more testing before my post.
I retested and the OTA example ran fine, if unmodified. The failure occurred in my sketch when I added the example's code to it. To pin down the problem, I added my #include's into the working example line by line. The inclusion of #include "esp_system.h" into the OTA example causes the crash. Can someone confirm?