-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Changing flash size setting causes SDK config corruption and crashes early in SDK initialization #1010
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Got some more information, I played changing flash size from ide then flash same board, and of course changing this break SDK config parameters. And it seems SDK does not do any check on what it find in config (at least a checksum on the config structure would have been good, I'm saving my own config in flash and I check it's correct, if not default settings). Saying that, in the example below, look, config is corrupted (after played changing flash size), and I've got a crash a boot Is there anyway to clear this config at boot ? I don't need it and seems I don't want it !
|
Another problem with corrupted SDK config data (I just had the case) is that it crash before you get hand before setup(), which can totally "brick" your device. 1st line in my setup I tried WiFi.disconnect to reset config, but it crashed before. Only way, I had to do, reflash with setting flash size back to 512Kb (it worked, lucky or not) and then flash back with 1Mb May be a 512KB sketch resetting flash of stored SDK config for 1MB config would help in this type of problem. Not sure it's possible. |
there is a function for deleting the config. but may the SDK work already with it before the void initVariant() {
} your dumps look like the usage of an null ptr. the nearest function that we know is but from where the null pointer is coming is hard to say. |
You're totally right, moving to different flash size on the same device is not a good idea. |
@Links2004 , @igrr Charles |
By the way, I made a similar feature for esptool-ck, but apparently it segfaults on windows: igrr/esptool-ck#18 |
@igrr It seems both are doing nothing with erase_flash, even with other commands, like not even trying to communicate with the module what I'm doing wrong ? |
@hallard erase_flash is a I think your best bet is to download esptool.py and use it to erase flash (you have python, don't you?) Regarding erase_flash option in esptool-ck, i have only added it in this pull request: igrr/esptool-ck#18. It has been reported to not work on windows for some reason. I don't have a windows machine now so not able to debug. |
@igrr So I got it launched and running, but It can't connect on my ESP board, I launch I tried with cygwin and with cmd line. Notice cygwin trick, port is |
@igrr My ESP07 came back to life with 1M 64K SPIFFS setting no more crash switching from AP to STA. This was so as I thought, related to corrupted SDK saved parameters. Anyway this procedure can be setup to "unbrick" devices ;-) PS : If anyone succeed to works with |
a compiled python there: I had simply installed py2.7 and it is working. |
I've just tried, with no luck, first shot, 1st time it told me I was missing c:\python27\python27.dll but found it in system folders, so copied it from c:\windows\syswow64\ didn't worked, so tried 32bits version, copied from c:\windows\system32\ then I can execute the exe but got this : |
I'm anticipating a questio, of course I get installed pyserial module (esptool.py find it);-) |
you need to download the full bin dir :) |
Oh sorry access denied, got it !!! |
this time the serial port is not found, the rest seams to work. |
this epstool version has a little differences to the standard one. |
Update es.lang.gz
Hi there,
I'm knocking my head since 2 days, I've got ESP07 1MB that is working fine (Wifi Web server, bla bla all I need is fine) until I decide to set it as an AP (1st config UI), at this point it came direct to crash.
So I tested several things, including creating new test sketch with lot of information and setup to Access point (full demo at the end of this issue).
it show that
WiFi.softAP(ssid,password)
goes direct to a core dump whatever param I passWiFi.softAP(ssid)
is the same soWiFi.softAP("Hello","World")
FYI, I do not use SPIFFS, so I don't need it.
What is very Strange is that all is working fine as soon as I do not setup AP. When setup to 1MB 64 SPIFFS (so no AP) OTA is working fine, so I think it's really an 1MB Flash chip on board ;-)
here the results I tried :
Setting 512K board (NO OTA possible)
Setting 1M board
I'm suspecting conflict with SDK config/flash config or whatever, I really would like to try with config 1MB No SPIFFS as a test just to see but we do not have this option.
You can see crash results below 👍
Here the full test demo sketch
If anybody has an idea, I'll take, this is driving me mad !!!
The text was updated successfully, but these errors were encountered: