1technophile / OpenMQTTGateway

MQTT gateway for ESP8266 or ESP32 with bidirectional 433mhz/315mhz/868mhz, Infrared communications, BLE, Bluetooth, beacons detection, mi flora, mi jia, LYWSD02, LYWSD03MMC, Mi Scale, TPMS, BBQ thermometer compatibility & LoRa.
https://docs.openmqttgateway.com
GNU General Public License v3.0
3.59k stars 790 forks source link

Upgraded Lilygo Lora T3 v1.6.1 to OMG 1.7 from 1.6 and it is repeatedly rebooting #1836

Closed vincenpt closed 5 months ago

vincenpt commented 10 months ago

Before submitting a problem please check the troubleshooting section https://docs.openmqttgateway.com/upload/troubleshoot.html

Describe the bug I have several Lilygo LORA t3 v1.6.1 boards that are listening on the 433 mhz frequency. Each of these boards had v1.6 of OMG installed on them and was working fine.

Today I saw there was an update available for OMG to 1.7 so I used the built in WebUI to initiate an upgrade to v1.7. Immediately after the upgrade I noticed the boards were repeatedly rebooting.

The screen reports:

I took one of the malfunctioning devices, unplugged it, let it sit for a few minutes and plugged it back in and it exhibited the same behavior.

I then connected it via USB to my laptop and reflashed it with 1.7 via Chrome (checking the checkbox to erase the flash). I was able to connect to the self hosted wifi connection & setup my Wifi & MQTT settings, but once I saved the settings the device started the same boot loop again.

During one of the boot cycles I was able to grab the console log via the web interface:

N: OpenMQTTGateway URL: http://192.168.1.215/
N: ZwebUI setup done
N: RF Config not found using default
N: Enable RTL_433 Receiver: 433.92Mhz
N: ZgatewayRTL_433 setup done 
N: OpenMQTTGateway modules: ["LilyGo_SSD1306","WebUI","rtl_433"]
N: ************** Setup OpenMQTTGateway end **************
W: MQTT connection...
N: Connected to broker
N: Send on /RFtoMQTT msg {"active":3,"frequency":433.92,"rssithreshold":-82,"rssi":-86,"avgrssi":0,"count":10,"ookthreshold":15}
N: Update check, free heap: 104572N: Update check done, free heap: 64828N: Send on /SYStoMQTT msg {"uptime":18,"version":"v1.7.0","disc":true,"ohdisc":false,"env":"lilygo-rtl_433","freemem":107044,"mqttp":"1883","mqtts":false,"msgprc":0,"msgblck":0,"maxq":0,"minmem":102248,"tempc":53.89,"freestck":5980,"eth":false,"rssi":-62,"SSID":"1qw0pou","BSSID":"80:2A:A8:47:79:98","ip":"192.168.1.215","mac":"64:B7:08:89:FE:08","modules":["LilyGo_SSD1306","WebUI","rtl_433"]}
N: Send on /SSD1306toMQTT msg {"onstate":true,"brightness":50,"display-flip":true,"idlelogo":true,"log-oled":false,"json-oled":true}
N: Send on /WebUItoMQTT msg {"displayMetric":true,"webUISecure":true,"displayQueue":0}
N: Send on /RLStoMQTT msg {"latest_version":"v1.7.0","title":"OpenMQTTGateway","release_url":"https://github.com/1technophile/OpenMQTTGateway/releases/tag/v1.7.0","installed_version":"v1.7.0","entity_picture":"https://github.com/1technophile/OpenMQTTGateway/raw/development/docs/img/Openmqttgateway_logo_mini_margins.png","release_summary":""}
N: Send on /RTL_433toMQTT/Acurite-Tower/A/7575 msg {"model":"Acurite-Tower","id":7575,"channel":"A","battery_ok":1,"temperature_C":19.4,"humidity":38,"mic":"CHECKSUM","protocol":"Acurite 592TXR Temp/Humidity, 592TX Temp, 5n1 Weather Station, 6045 Lightning, 899 Rain, 3N1, Atlas","rssi":-76,"duration":250000}
N: Send on /RTL_433toMQTT/Acurite-Tower/C/15652 msg {"model":"Acurite-Tower","id":15652,"channel":"C","battery_ok":0,"temperature_C":19.6,"humidity":44,"mic":"CHECKSUM","protocol":"Acurite 592TXR Temp/Humidity, 592TX Temp, 5n1 Weather Station, 6045 Lightning, 899 Rain, 3N1, Atlas","rssi":-48,"duration":127000}
N: Send on /RTL_433toMQTT/Acurite-Tower/A/6190 msg {"model":"Acurite-Tower","id":6190,"channel":"A","battery_ok":1,"temperature_C":18.6,"humidity":48,"mic":"CHECKSUM","protocol":"Acurite 592TXR Temp/Humidity, 592TX Temp, 5n1 Weather Station, 6045 Lightning, 899 Rain, 3N1, Atlas","rssi":-80,"duration":211000}

I am not sure if it is related, but my MQTT base topic is set to 433_direct/raw/, which I know is non-standard.

To Reproduce Steps to reproduce the behavior:

  1. Install OMG 1.7 on a Lilygo LORA T3 v1.6.1
  2. Configure Wifi & MQTT server settings
  3. Once the device restarts from the settings change, it will reboot after receiving messages.

Expected behavior I expect the device to not repeatedly reboot.

Screenshots If applicable, add screenshots to help explain your problem. Video link showing the issue - https://photos.app.goo.gl/hJ7EdvSELMk9ZLGU7

Environment (please complete the following information):

Additional context Add any other context about the problem here.

1technophile commented 9 months ago

It is available in dev: image

oscarb commented 9 months ago

It is available in dev:

Ah, I think we've misunderstood each other. What I meant was that my hardware ESP32 device no longer shows in that Chrome popup of connected devices whenever I try to do the "upload from the web" installation. Tried different browsers and different computers. My best guess is that my ESP32 needs to be put into some mode where it will show up again on my computer, or maybe even factory reset, but I haven't figured out how to do that yet.

khorovatin commented 9 months ago

Sharing to add one more (possibly duplicate) data point: I experienced the same issues with the 1.7.0 update. After updating my Lilygo T3_v1.6.1 to OMG 1.7.0 it would either go offline after a very short time (minutes), or reboot repeatedly (after seconds, or, at most, a minute or two). I did a complete reinstall (several times) with a memory clear, but that did not change the behaviour. After reverting back to v1.6.0, the device appears to be stable again and working as it did before (including the memory leak that is seemingly caused by interpreting my Acurite 5-in-1 weather station's messages--a problem I deal with by having an automation that restarts the gateway every six hours).

BowenMarmot commented 9 months ago

A confirmation that the DEV version of a week or so ago (4e4487) installed via the dev web page is now rock solid on my Lilygo T3_V1.6.1. I have the acurite 5-in-1 station (and some occasional other stations from neighbours) and after updating to 1.7.0 I would see a slow decline in FreeMem until it would crash. I never saw reboots, only crashes.

With the dev version, freemem now stays between 110000 and 114000 on my device and I haven't had a crash since. THANKS!!

github-actions[bot] commented 6 months ago

This issue is stale because it has been open for 90 days with no activity.

github-actions[bot] commented 5 months ago

This issue was closed because it has been inactive for 14 days since being marked as stale.