-
Notifications
You must be signed in to change notification settings - Fork 639
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
LITESUN_LA_WF3/BNC-50 device won't boot with firmware newer than Jan 2021. #2436
Comments
2 points of interest:
|
db-hbn-skt.zip I'll look at the other test later. A build using current |
Testing .zip binary and a custom build, it looks like it actually boots ok but stops somewhere around here and triggers hardware watchdog
espurna/code/espurna/debug.cpp Lines 409 to 413 in dfba0de
Removing the block seems to workaround the issue. However, these still trigger the wdt since they use the same API:
It does not seem to be able to calculate the heap stats |
There seems to be some kind of memory corruption going on. Adding Core build flags #define OTA_ARDUINOOTA_SUPPORT 0
#define MDNS_SERVER_SUPPORT 0 stops the crashing. I'll try to figure out what is going on though, since both are kind of nice to have enabled by default. |
A quick test defining below still doesn't allow the device to boot.
|
diff --git a/code/espurna/led.cpp b/code/espurna/led.cpp
index 4eadf41b..6269f2f7 100644
--- a/code/espurna/led.cpp
+++ b/code/espurna/led.cpp
@@ -339,7 +339,7 @@ std::vector<size_t> _led_relays;
void _ledConfigure() {
#if RELAY_SUPPORT
- _led_relays.resize(relayCount(), RelaysMax);
+ _led_relays.resize(_leds.size(), RelaysMax);
#endif
for (size_t id = 0; id < _leds.size(); ++id) { ? Hope that's all that needs to happen |
removed from the build and the above change made. Device running The LEDs were set to
Changing each LED in turn to |
And
|
@@ -512,8 +545,6 @@ void ledSetup() {
DEBUG_MSG_P(PSTR("[LED] Number of leds: %u\n"), leds);
if (leds) {
- _ledConfigure();
-
#if MQTT_SUPPORT
mqttRegister(_ledMQTTCallback);
#endif
@@ -526,13 +557,15 @@ void ledSetup() {
#endif
#if RELAY_SUPPORT
- relaySetStatusNotify([](size_t, bool) {
- ledUpdate(true);
+ relaySetStatusChange([](size_t, bool) {
+ _led_update = true;
});
#endif
espurnaRegisterLoop(ledLoop);
+
espurnaRegisterReload(_ledConfigure);
+ _ledConfigure();
}
} for relays? does not look like something crash-able though. raw stack needs a decoder to actually make sense. there's something malloc-like around the exception itself, but idk what is the context |
Fixed! We'll done again! I must set some time aside to look at the decoder software. A quick test and all appears to be working without any crashes. I'll keep an eye on it. Was it the multiple LEDs that were the issue? |
Yes. |
All seems to be working fine without any crashes. |
Thanks! |
Following on from trying to test the WiFi re-connect changes, I have been trying to get the latest
dev
firmware on this device. Its an HBN BNC 50 (#2022 (comment)) and I've up until now been using the following to build and the latestplatform
Even the with the latest
dev
commit (dfba0de) loaded via serial, the device doesn't boot and there is nothing shown via putty/serial connection even @ 74880. Power cycling the device force closes the serial connection so can't see any boot data.I have a .bin file running
1.15.0-dev8e659c94
that I can flash via serial or web OTA and it works fine, but the currentdev
just doesn't seem to work. The button doesn't do anything, LEDs aren't coming on and there is no signs of any WiFi, espurna AP or connection to my network.Should I look to try and build various firmwares between this working build and the current
dev
and try to work out which code is making the device fail?The text was updated successfully, but these errors were encountered: