Rebooting when joining WiFi
Using latest version 1.6.1-esp8266-1-1054-g3183c7c
I have a project that has been working fine (at least booting and joining wifi.) now it crashes upon trying to join wifi...
NORMAL ACCESS MODE ENABLED
Scanning for Networks
Joining Wifi Network....
ets Jan 8 2013,rst cause:2, boot mode:(3,7)
load 0x4010f000, len 1464, room 16
tail 8
chksum 0x7a
csum 0x7a
e���(�SQS�(RQ�)HT�)SHHHC���r
Not sure what to do next, to help? I should add that the same code compiled on a previous IDE works fine.
I had the same problem with pubsubclient and it seems to be solved with this version 1.6.4-835-g77d77e8 ( https://github.com/esp8266/Arduino/issues/324 ) See https://github.com/Imroy/pubsubclient/issues/8
Thanks Buddy I will try a fixed IP out now and then test the version you specify after with DHCP.
Awesome, fingers crossed.
Dans
You are a hero, so Far I have a static IP assigned and no more WDT resets. Superb so it does seem DHCP related.
Not only that I have a really good test router that links to my main wireless network and does several drop connections before it becomes solid. An Ideal unit to test for harsh network conditions,
I will now look at my current build of the Arduino IDE which is 1.64, how do I find out donwload version of this eg g77d77e8 ?
Massive thanks again
Dans
See issue #324 for details how to get Package for nightly build
Very simple sketch leads to out of heap:
#include <ESP8266WiFi.h>
void setup() {
delay(2000); // debugging purposes
Serial.begin(115200);
Serial.setDebugOutput(true);
WiFi.printDiag(Serial);
WiFi.mode(WIFI_STA);
// with or without this string result is the same
WiFi.config({192, 168, 78, 233}, {192, 168, 78, 1}, {255, 255, 255, 0}, {192, 168, 78, 1});
// correct AP name with wrong pass
WiFi.begin("atmosphere", "wrong password!");
}
void loop() {
Serial.println(ESP.getFreeHeap());
delay(500);
}
The log http://pastebin.com/M80fvhxs
The original issue should be fixed in esp8266-1.6.5-804-g2d340c7. Will also check the out-of-memory issue with wrong password.
i was having a number issues with random wdt reboots while trying to connect to the AP - all at different times after startup. What's interesting is that it seems random - will connect fine for hours then stop working for hours (wdt reboots) then it starts working again. Problem seems greatly improved with the latest code (no reboots yet).
BTW - what's the best way to get the arduino IDE to detect and reload any updates to the board manager .json code?
Also, what tools do you use to debug crashes - gdb?
Thnx,Reza
I also had my ESP8266 (NodeMCU) rebooting on WiFi.begin() with the following messages:
ets Jan 8 2013,rst cause:4, boot mode:(3,6)
wdt reset
load 0x4010f000, len 3460, room 16
tail 4
chksum 0xcc
For me the issue was that I used WiFi.h (used in many old examples) instead of ESP8266WiFi.h.