Arduino: Documentation on "rst cause" and "boot mode"

Created on 13 Nov 2015  路  7Comments  路  Source: esp8266/Arduino

I am getting errors while building firmware for the ESP8266 using a nodemcu 1.0. Are the errors define or documentation anywhere so I can try to resolve my own issues.

rst cause:2, boot mode:(3,6)
rst cause:4, boot mode:(1,6)

etc..

question

Most helpful comment

This is always the first link on google.... so i'll just put here the results of the above refered 1st file:

reset causes:
    0: 
    1: normal boot
    2: reset pin
    3: software reset
    4: watchdog reset

boot device:
    0:
    1: ram
    3: flash

All 7 comments

Here's documentation on that:

http://www.esp8266.com/viewtopic.php?p=2096#p2112

https://github.com/esp8266/esp8266-wiki/wiki/Boot-Process#esp-boot-modes

Your first one appears to be caused by the reset pin (could indicate power supply issues if nothing has actually happened to the pin itself.), the boot mode for this one is boot from spi flash memory.

The second one was caused by the watchdog timer, with the boot mode set to download new code from the serial port.

You get a freebie this time, but for next time:

I'd strongly advise signing up for the esp8266 forums and getting familiar with the search function they provide, most of the answers you seek are already available there, since this is an issues tracker with scope limited to the Arduino IDE project rather than a general help forum.

Do we have an api to retrieve the reset cause/ boot mode?

not direct the closest we have for reset cause is the resetInfo.reason
https://github.com/esp8266/Arduino/blob/master/cores/esp8266/Esp.cpp#L332

for boot mode the access is unknown

Excellent, just what I was looking for.

I had the exact same errors with a simple C program I modified. Turned out my user_init function ran to long: Adding or removing os_delay_us produced or removed the issue.

This is always the first link on google.... so i'll just put here the results of the above refered 1st file:

reset causes:
    0: 
    1: normal boot
    2: reset pin
    3: software reset
    4: watchdog reset

boot device:
    0:
    1: ram
    3: flash

@h4rm0n1c your point about "use the forums" is valid. I tried doing that on my last problem. Every message I posted took 2 to 3 days to be manually approved.
That's a total joke, what forum requires this and requires so much delay when you need help?
Sadly as a result, I don't use the forums there anymore, they're pointless as is.
Just an FYI to others so that they don't waste their time like I did :(

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Marcelphilippeandrade picture Marcelphilippeandrade  路  3Comments

tttapa picture tttapa  路  3Comments

Khorne13 picture Khorne13  路  3Comments

SmartSouth picture SmartSouth  路  3Comments

mreschka picture mreschka  路  3Comments