Chat freely about anything...

User avatar
By gggggggg
#64417 I have a ESP-12f, it has the worlds most simple code:

Code: Select allvoid setup() {
    Serial.begin(115200);
    Serial.println("Booting");
}

void loop() {

}


I Have Debug Port turned onto Serial, and Level turned to All. I push the code to the ESP, and after a random period of time (under 10 minutes normally), I get this.

Code: Select allBooting
scandone
state: 0 -> 2 (b0)
state: 2 -> 3 (0)
state: 3 -> 5 (10)
add 0
aid 7
cnt

connected with MyWiFi, channel 6
dhcp client start...
ip:192.168.1.68,mask:255.255.255.0,gw:192.168.1.1
pm open,type:2 0
Fatal exception 9(LoadStoreAlignmentCause):
epc1=0x402067ff, epc2=0x00000000, epc3=0x00000000, excvaddr=0x40101b07, depc=0x00000000

Exception (9):
epc1=0x402067ff epc2=0x00000000 epc3=0x00000000 excvaddr=0x40101b07 depc=0x00000000

ctx: sys
sp: 3ffffc20 end: 3fffffb0 offset: 01a0

>>>stack>>>
3ffffdc0:  00000022 40102dd5 00040000 40105488 
3ffffdd0:  3ffe90a0 401057fa 00000000 00000100 
3ffffde0:  00000000 0b8320e5 00000000 40101b07 
3ffffdf0:  40101ae8 3fffc100 3ffef9f4 00000000 
3ffffe00:  40101b01 40101afe 3ffea464 3ffed81c 
3ffffe10:  400005e1 00000030 0000001a ffffffff 
3ffffe20:  4020a721 00000030 0000001a 000000a5 
3ffffe30:  4020a7ba 00000000 3ffefde0 00000000 
3ffffe40:  4010258c 00000000 00003a98 00000000 
3ffffe50:  3ffe8e8c 3ffe9314 3ffe8e8c 0398da02 
3ffffe60:  3ffef9f0 3ffef9f4 00000000 00000000 
3ffffe70:  00200000 00008000 00000000 3ffe90a0 
3ffffe80:  00000000 3fffdcc0 3ffe95f0 00000030 
3ffffe90:  3ffe8a20 3ffefe74 00000000 40226614 
3ffffea0:  00000000 0398d9b3 4022666b 3ffefe74 
3ffffeb0:  3ffefe5c ffffffce 00000000 00000001 
3ffffec0:  00000001 0000003c 4010474b 3ffecdb8 
3ffffed0:  00000020 00310606 3ffef530 00000002 
3ffffee0:  3ffef530 000000dd 000000dd 401002a8 
3ffffef0:  00000000 3ffe8944 3fff040c 4010097c 
3fffff00:  402031dd 00000000 00000001 40107210 
3fffff10:  3ffef530 00000018 00000018 401002a8 
3fffff20:  3ffef9f4 3ffef9f0 0398da02 4020a7ba 
3fffff30:  00000000 3fff0414 0398da02 40102598 
3fffff40:  40101142 0398f87a 3fff0414 4020d091 
3fffff50:  4010258c 00000000 0398f87a 00000000 
3fffff60:  40202f24 3ffe8e8c 3ffe8a20 60000600 
3fffff70:  0b8322c7 3ffe8a20 3ffe8e8c 40202f31 
3fffff80:  40202f76 3fffdab0 00000000 3fffdcb0 
3fffff90:  3ffe8a38 3fffdad0 3ffee418 40201f9b 
3fffffa0:  40000f49 3fffdab0 3fffdab0 40000f49 
<<<stack<<<

 ets Jan  8 2013,rst cause:2, boot mode:(3,6)

load 0x4010f000, len 1384, room 16
tail 8
chksum 0x2d
csum 0x2d
v6000001c
~ld
Booting
scandone
state: 0 -> 2 (b0)
state: 2 -> 3 (0)
state: 3 -> 5 (10)
add 0
aid 7
cnt

connected with MyWiFi, channel 6
dhcp client start...
ip:192.168.1.68,mask:255.255.255.0,gw:192.168.1.1
pm open,type:2 0
Fatal exception 9(LoadStoreAlignmentCause):
epc1=0x402067ff, epc2=0x00000000, epc3=0x00000000, excvaddr=0x40101b07, depc=0x00000000

Exception (9):
epc1=0x402067ff epc2=0x00000000 epc3=0x00000000 excvaddr=0x40101b07 depc=0x00000000

ctx: cont
sp: 3ffef130 end: 3ffef440 offset: 01a0

>>>stack>>>
3ffef2d0:  00000000 00000000 0000001f 40101295 
3ffef2e0:  4000050c 11cebe4e 00000000 4000050c 
3ffef2f0:  00000000 00000000 0000001f 40101b07 
3ffef300:  40101ae8 3fffc100 3fffdad0 00000003 
3ffef310:  40101b01 40101afe 00000011 ffffffff 
3ffef320:  400005e1 00000023 00000001 00000001 
3ffef330:  4020203f 00000030 00000010 3ffee418 
3ffef340:  40100114 00000000 00000001 00000001 
3ffef350:  3fffdab0 00000000 3fffd9d0 3ffee418 
3ffef360:  00000000 00000000 00000001 3ffee420 
3ffef370:  00000000 3fffdad0 3ffee418 00000003 
3ffef380:  00000000 3fffdad0 3ffee418 00000030 
3ffef390:  00000018 feefeffe 3ffef530 0001c200 
3ffef3a0:  0000001c 00000000 00000018 4010078c 
3ffef3b0:  feefeffe 00000001 3ffe8461 40202238 
3ffef3c0:  00000000 00000006 3ffe842e 3ffee418 
3ffef3d0:  3fffdad0 00000007 3ffee3f4 40201e5d 
3ffef3e0:  3ffe8460 00000000 3ffee3f4 40201e5d 
3ffef3f0:  3ffe8428 feefeffe 3ffee3f4 40201e78 
3ffef400:  feefeffe feefeffe 3ffee3f4 40201e9c 
3ffef410:  00000000 00000000 00000001 40202001 
3ffef420:  3fffdad0 00000000 3ffee410 4020203a 
3ffef430:  feefeffe feefeffe 3ffee420 40100114 
<<<stack<<<

 ets Jan  8 2013,rst cause:2, boot mode:(3,6)

load 0x4010f000, len 1384, room 16
tail 8
chksum 0x2d
csum 0x2d
v6000001c
~ld
Booting
scandone
state: 0 -> 2 (b0)
state: 2 -> 3 (0)
state: 3 -> 5 (10)
add 0
aid 7
cnt

connected with MyWiFi, channel 6
dhcp client start...
ip:192.168.1.68,mask:255.255.255.0,gw:192.168.1.1
pm open,type:2 0


I have two questions please:
1) What causes such a crash. I have tried many different power sources and serial connection combinations. This is just simple code, but when I have my more complex code, it can crash and reboot, or it can crash and hang. At the end of the day, the reboot does not bother me, its the crash and hang that is annoying.

2) How is it connecting to MyWiFi (which is my AP), without any code to make the connection? I can even ping it.
User avatar
By Pwolf
#64423 What I would do is start by looking at your wiring, make sure the Reset pin and grounds are all hooked up right. Your test code is pretty simple and should not create any reboots. You can also use the ESP Exception Decoder (needs to be installed, it will be in the Arduino Tools menu, you can copy and paste the dump trace into the decoder and it will give you the last few things that happened before the crash.