-
Notifications
You must be signed in to change notification settings - Fork 307
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
ESP8266 Arduino Core 2.4.0 causing reset #477
Comments
Can we have the stack trace ? |
Sure ✖/homie/config.json doesn't exist Exception (3): ctx: sys
ets Jan 8 2013,rst cause:2, boot mode:(3,6) load 0x4010f000, len 1384, room 16 |
Do you also have the translation of the stack ? https://github.com/me-no-dev/EspExceptionDecoder Will look into soon when i next have time, soz on hols atm.... |
Decoding 39 results |
@yoyanec Just want to verify something, you can only decode the stack trace correctly when you use the same build go decode as what was flashed. In other words you have to build then flash the board then decode the stack without any builds in between..... trying to use an old stack trace on a new build will give you wrong and weird results. Assuming you've does this right, looks like homie doesn't have much blood in the water. Verify you decoded the stack correctly and then i'll dive into this. |
@timpur I will reflash, reupoload and try again. Just to be sure. I was working on my project and not sure if i did it correctly. |
Decoding 39 results |
Much better, will look into. Any chance of getting your code ? or tell me if your importing Looking at https://arduinojson.org/faq/why-does-my-device-crash-or-reboot/ since it seems to be an issue with ArduinoJson atm. |
This is code i used this is the part using ArduinoJson (in loop())
But then i reflash Bare minimum sketch from http://marvinroger.github.io/homie-esp8266/docs/develop/quickstart/getting-started/ with the same error. Just to be sure, nodemcu reset just after homie recieved configuration from ui_bundle
|
As the owner of https://github.com/hiveeyes/arduino/blob/master/node-wifi-mqtt-homie/node-wifi-mqtt-homie.ino: I had similar issue with wrong flash mode. Which flash mode do you use? What is your exact ESP board? |
@Gulaschcowboy Based on line in boards.txt under esp8266/2.4.0/ folder, i believe it is DIO
|
@yoyanec: I had my ESP07 barebone once wrongly flashed using DOUT. It caused also an exception while writing the config. Changing to DIO fixed it. But it depends on your board and how the flash is wired to the ESP. As I'm not an expert in SPI/flash wiring see https://github.com/espressif/esptool/wiki/SPI-Flash-Modes and try other modes. |
Sounds like thats on the money, thanks @Gulaschcowboy |
OK, problem fixed. It is not Flash Mode (i tried all :). With ESP8266 Arduino Core 2.4.0, nodemcu 1.0 has new options in tools. I dont know, what is IwIP Variant. Default value is v2 Prebuilt (MSS = 536). After change to v1.4 Prebuilt everything works like a charm. @timpur @Gulaschcowboy Thank you very much. |
Intresting, thanks for that. |
@timpur lwIP v2 became the default and should address MTU issues when the ESP is connected over a xDSL line for example. |
I use v2.4 with lwip2.0 and all seems fine, maybe clean your dependencies and reinstall them ?? |
@timpur How did you upload the config.json? And does LwIP 2.0 mean MSS=536? Because: When I use LwIP MSS=536 and do the config upload via curl I get: EDIT: Did a quick test with MSS=1460 and there I can use curl to configure. Will do some more tests. |
hmm ill look into this, but i dont seem to be getting issues, that said i was using arduino ide, ill test platform IO Edit: been using 2.4.0 for a while on both arduino and platform io. All seems fine maybe test using bare homie sketch ? |
BTW, my tests/results are with Arduino IDE |
Did some more tests with fresh PlatformIO environment. Couldn't reproduce this issue there. :-( |
With arduino try updating all libs to latest ? especially homie, aruinojson, asyncmqtt, asynctcp |
Deleted and recreated the whole libraries folder with latest versions. Compiled, uploaded. Received config request Exception (29): This "Invalid JSON" is new and I'm 100% sure, that it is not, because in the second try same config.json works (see below) Decoded stack trace: ` 0x4021eb67: String::init() at /home/atze/.arduino15/packages/esp8266/hardware/esp8266/2.4.0/cores/esp8266/WString.cpp line 746 2nd try (yes, same config): Received config request |
yes, it has been known fresh upload weird things can happen and is recommenced to do a reset after reload, not sure its worth trying to fix this .... so all seems fine to me. |
OK, my bad. I know this behavior but forgot to do a reset after flashing. So at the moment I cant't reproduce anymore. |
Believe i have a fix for this in 2.1, will push to dev here if it does fix. |
@timpur I will check, just need few days. |
* 🔥 Remove hardcoded keepalive - fix homieiot#301 (homieiot#314) Remove hardcoded KeepAlive for MQTT connection. Default value of 15sec is already present in AsyncMQTT library * 🐎 Improve uptime accuracy (homieiot#315) improve uptime accuracy by storing milliseconds and only rounding when publishing value drawback: less time before rollover, but still long enough * 🐛 Fix truncated IP (homieiot#318) published IP is truncated. * 🎨 Fix warning with parenthesis * 🐛 Fix pio library.json bad dependency name * ✨ Add support for static IP and BSSID/MAC, channel of AP (homieiot#327) * Support for static IP and BSSID/MAC, Channel of AP - added parameters to config.json which allow to define static ip, mask, gateway, dns - added parameters to config.json which allow to define BSSID and channel of AP To run device with defined static IP you have to define ip, mask and gateway together. To point device to connect to specific BSSID and channel you haveto define bssid and channel together. ``` { "name": "The kitchen light", "device_id": "kitchen-light", "wifi": { "ssid": "Network_1", "password": "I'm a Wi-Fi password!", "bssid": "DE:AD:BE:EF:BA:BE", "channel": 1, "ip": "192.168.1.5", "mask": "255.255.255.0", "gw": "192.168.1.1" }, "mqtt": { "host": "192.168.1.10", "port": 1883, "base_topic": "devices/", "auth": true, "username": "user", "password": "pass" i }, "ota": { "enabled": true }, "settings": { "param1": 55, "param2": "abcdefghijklm", "param3": true, "param4": false, "param5": 2147483647, "param6": -2147483647, "param7": 55, "param8": "abcdefghijklm", "param9": true, "param10": false } } ``` * Addjustments for travis * Another addjustments for travis * Fix problem with prepareToSleep * 🐎 Pass all callbacks by reference Still store it by value * 🐎 Make isActive const * 🎨 Add custom settings value to initial log * ✨ Abort if default setting value does not pass validator function Fix homieiot#324 * 📝 Clarify ISSUE_TEMPLATE docs location for homieiot#331 * 📝 Implement new versioned Git docs (homieiot#341) * ✨ Add versionned in-repo docs * 🐛 Attempt to fix encrypted key * 🐛 Fix permission issue on python exec * 🐛 Add mission import * 🐛 Fix relative path * 🐛 Add missing commit * ✨ Add index * 🎨 Change index design * 📝 Update all URLs to new docs * 🎨 Fix broken doc link in README * 📝 Add edit link to docs * 📝 Move firmware_parser.py to scripts folder * 🐛 Fix out of limits abort message not showing * 👕 Be less strict on whitespace in comments * 📝 Add dummy OTA updater script (TODO) * 🎨 🐎 Use CircleCi instead of Travis CI (homieiot#348) * ✨ Add Circle CI build * 🐛 Add working_directory * 🐛 Attempt to fix perm issue * ✨ Generate docs from CircleCI * 🐛 Fix path * 🐛 Fix chmod permission * 🐛 Try to run sudo * 🐛 Attempt to use remote docker * 🐛 Change bad directories * 🐛 Remove dependency on Docker * 🐛 Fix perm problem * 🐛 Chamge tmp folder * 🐎 Use CircleCI instead of Travis CI * 🎨 Add SonoffDualShutters example * 🐛 Install current lib to platformio * 🐛 Actually ignore gh-pages in CI * 🐛 Add missing SonoffDual dep * 🐛 Fix ArduinoJSON 5.11.0 (homieiot#363) * ⬆️ Update pio dependencies * 🎨 Cleanup code a bit * 🐛 Make sure every announcements packet are sent - closes homieiot#345 * 🎨 Refactor code and implement new OTA system Closes homieiot#346 * 👕 Fix lint * ✅ Use new workflow feature from Circle * ✅ Ignore gh-pages at workflow level * ✨ Add OTA_PROGRESS event * 📝 Update docs for new OTA system * ⬆️ Upgrade AsyncMqttClient dependency to 0.8.0 * 🐛 IHomieSetting::settings first, HomieNode-settings second! (homieiot#335) * IHomieSetting::settings first, HomieNode-settings second! Set initialization priority of IHomieSetting::settings to value of highest allowed priority (101). This allows other static variables to be of type HomieSetting<T>. See https://github.com/euphi/HomieNodeCollection/blob/master/src/RGBWNode.cpp for example. Note: As shown in the example it makes sense to have a static HomieSetting member, if you have a class that may be instantiated multiple times. (e.g. two LED Strips connected to the same ESP8266, as shown in https://github.com/euphi/ESP-LEDCtrl). * Removed extra whitespaces * Removed another whitespace * 🐛 Fix not returning a value in setConfigurationApPassword (homieiot#378) `HomieClass& HomieClass::setConfigurationApPassword(const char* password)` did not returned a reference to the Homie instance. This PR fixes this. * 🐛 Fix crash when starting up without any defined node (homieiot#379) * Fix crash when starting up without any defined node Skip node publication if HomieNode::nodes.size() == 0 * Update BootNormal.cpp * 🐛 Fix topic check for OTA upload (homieiot#375) * Change topic check for OTA upload * Change firmware topics to remove the 's' * 🐛 Rename last OTA topic instance * ✨ Add OTA updater script (homieiot#384) * 🐍Add python ota updater script * 💼 Update documentation of ota update script * 😑 Add comments to ota updater script * 🔮 Use 127.0.0.1:1883 as default broker setting For the ota updater script * 📝 Add details on how to interact with range property (homieiot#393) Add hint to help people figure out how to interact with range properties. Especially document the `_` separator. * 📝 Add warning to input-handlers.md about concurrency (homieiot#400) * 🐛 Interpret firmware file as an bytearray (homieiot#403) Fix homieiot#397 * 📝 Update input-handlers.md (homieiot#401) * Update input-handlers.md Sorry, it seems that I used the `!!! warning` block in a wrong way. * Update input-handlers.md * Update input-handlers.md * ✨ Use AsyncWebServer + Refactoring (homieiot#425) * Initial AsyncWebServer * Fixed Proccessing Body Requests (JSON) * Doc Fixes + typo * Added Missing Method in Timer.cpp * Lots of Refactoring + Moved Reset Button to its own helper class for boots to use * 🎨 Update BootNormal.cpp (homieiot#426) Solve "else" errors from https://circleci.com/gh/marvinroger/homie-esp8266/136#tests/containers/0 * ⬆️ Update dependency to "ESP Async WebServer" (homieiot#434) * 📝 Add instruction for @platformio (homieiot#435) * Instruction for @platformio * Explain how to used tagged version with @platformio * Explain how to use tagged version with @platformio * 🐛 Use v2.0.0-beta.2 as a working tagged example for @platformio (homieiot#437) * 🎨 Simplify CI with @platformio (homieiot#438) * 🐛 Install library via @platformio with all dependencies (homieiot#439) * 💚 CI: Install staging version of Arduino Core for ESP8266 & @platformio (homieiot#440) * 🐛 Pin Shutters dep version * 🔥 Don't fail on CI docs step when testing a fork * 🎨 More Refactoring + Deep Sleep + Prevent WiFi Reconnect when reboot (homieiot#432) * Initial AsyncWebServer * Fixed Proccessing Body Requests (JSON) * Doc Fixes + typo * Added Missing Method in Timer.cpp * Lots of Refactoring + Moved Reset Button to its own helper class for boots to use * Lots of Refactoring. * Refactored ResetHandler + More Refactoring + Testing * Added deep sleep function + Prevent Wifi reconnect before reboot (homieiot#380)[homieiot#380] * Small typo fixes * Small Rearange of code in BootConfig + Minor Refactor of function names * Minior Commit to Triger a Github Action * circleci build fix * 🎨 First pass to fix linting * 🎨 Second pass of lint * 🎨 Final lint fix * 📝 Update docs deps * 📝 🎨 Update docs manifest * 📝 🎨 Adjust HTTP JSON API doc * 📝 Add configurators on website * 📝 Update links to configurator * Fix links under Features (homieiot#452) * Set Device Stats Interval (homieiot#451) (homieiot#455) * Add last step to uibundle README (homieiot#460) * Add last step to uibundle README * Added Arduino Support for doc * Update updater script addressing quirks (homieiot#461) * Update API for /wifi/connect from GET to PUT (homieiot#468) Docs show `/wifi/connect` as `GET` when it should actually be `PUT` * Proposal to optionally run HomieNode::loop() also in disconnected state * Show Homie version * Fix homieiot#446 homieiot#477 (homieiot#501) * Fix homieiot#446 CORS Issue * Fix for homieiot#477 * Fix Lint * Fix Safari not displaying the config bundle HTML page (Fix homieiot#476) (homieiot#502) * Fix Safari not displaying the config bundle HTML page Safari cannot deal with gzip files that have a "*.gz" file extension. Simply faking the filename solves the problem though. * Update Readme Homie Version * Fix Warnings (homieiot#503) * Update Readme - Homie Convention * Update to Homie Convention v2.0.1 (homieiot#507)
When i use ESP8266 Arduino Core 2.4.0 (KRACK fix), configuration save in configuration ui is causing reset without saving configuration.
The text was updated successfully, but these errors were encountered: