arendst / Tasmota

Alternative firmware for ESP8266 and ESP32 based devices with easy configuration using webUI, OTA updates, automation using timers or rules, expandability and entirely local control over MQTT, HTTP, Serial or KNX. Full documentation at
https://tasmota.github.io/docs
GNU General Public License v3.0
22.12k stars 4.79k forks source link

V6.4.1 in and out of "Unavailable" On Home Assistant / Switch turning red TasmoAdmin #4859

Closed c3reeman closed 5 years ago

c3reeman commented 5 years ago

IMPORTANT NOTICE If you do not complete the template below it is likely that your issue will not be addressed. When providing information about your issue please be as extensive as possible so that it can be solved by as little as possible responses.

FAILURE TO COMPLETE THE REQUESTED INFORMATION WILL RESULT IN YOUR ISSUE BEING CLOSED

Describe the bug A clear and concise description of what the bug is.

Also, make sure these boxes are checked [x] before submitting your issue - Thank you!

This could be due to the latest upgrade to V6.4.1 but not guaranteed it was a few days after the upgrade i noticed it. Ive got 28 devices running and up until a few days ago they were solid as a rock with no problems so wifi signal strength shouldn't be the problem in TasmoAdmin I've checked my lowest wifi signal is 65% i run a google mesh network with 5 nodes ensuring good coverage everywhere. The runtime of the sonoff's is not affected so this isn't a device restarting problem, its not a device specific problem either as its affecting all tasmota switches.

I wondered if interference could be an issue because i recently started using zigbee2mqtt, I've unplugged that and turned off any other device that i could think might cause interfearnce but it didn't make any difference... still the "unavailable"

below is a copy of my Home Assistant entry for an example switch, but like i say nothing has changed and this config has worked for the least 6 months.

 - platform: mqtt

    name: "Dressing Room Lights"

    state_topic: "stat/sonoff003/POWER"

    command_topic: "cmnd/sonoff003/POWER"

    availability_topic: "tele/sonoff003/LWT"

    qos: 1

    payload_on: "ON"

    payload_off: "OFF"

    payload_available: "Online"

    payload_not_available: "Offline"

    retain: false

This could be a home assistant fault but i have also noted that on TasmoAdmin the switches occasionally turn red, and this is at the same time HomeAssisistant shows "Unavailable" additionally i haven't upgraded home assistant in a while.

Jason2866 commented 5 years ago

Please fill out complete issue template with Status 0 Without this template we cant help Probably the Wifi Mesh is the problem. Please read https://github.com/arendst/Sonoff-Tasmota/wiki/Troubleshooting#wifi-issues-arduino-core-versions-and-expressif-sdk

c3reeman commented 5 years ago

Sorry about that please check now, Apologies

c3reeman commented 5 years ago

it appears it is a MQTT connection issue, Cant understand why this has only just started happening though, here is the log straight after the fault occurs

18:11:49 WIF: Connecting to AP1 Mill House in mode 11N as Sonoff005...
18:11:55 WIF: Connected
18:11:55 DNS: Initialized
18:11:56 MQT: Attempting connection...
18:11:56 MQT: Connected
18:11:56 MQT: tele/sonoff005/LWT = Online (retained)
18:11:56 MQT: cmnd/sonoff005/POWER = 

MQTT Broker in Home assistant constantly giving new connection status

Jason2866 commented 5 years ago

Try if with core 2.3.0 your issue is solved http://thehackbox.org/tasmota/release/020300/sonoff.bin Do an OTA with this firmware

andrethomas2 commented 5 years ago

Please follow https://github.com/arendst/Sonoff-Tasmota/wiki/Troubleshooting#wifi-issues-arduino-core-versions-and-expressif-sdk

Closing this issue as it has been answered.

Support Information

See Wiki for more information. See Chat for more user experience.

c3reeman commented 5 years ago

Thanks all, @Jason2866 your suggestion was the one that worked and as you said flashing OTA to 2.3.0 works fine, so pleased i didn't have to hard wire into them and re flash would have taken me days pulling them all out of the ceiling

john5788 commented 5 years ago

I just ran into this problem too. Are the future releases going to be built with 2.3.0 core or a fix will be in place for 2.4.2? Using @Jason2866 provided build allows device to show up in Home Assistant.

Jason2866 commented 5 years ago

@john5788 core 2.3.0 will not be supported in future. As long as it is possible without restrictions to upcoming features Tasmota will support it. For core 2.3.0 and 2.4.2 there will be no more fixes and updates from Arduino ESP team. The core(s) are just used from Tasmota and such issues cant be fixed in Tasmota. The new upcoming core 2.5.0 seems to work fine

sir106 commented 5 years ago

just flashed the nightly build, and still have the same issues. Seems that there is improvement, but still happens (round about all 3 min). Using SonOFF S20 and T1 2ch, Router is FritzBox 7490.

Program Version 6.4.1.9(b5824fc-sonoff) Build Date & Time 2019-01-18T12:13:06 Core/SDK Version 2_5_0_BETA2/3.0.0-dev(c0f7b44)

Logfile: 4:44:07 MQT: iot-so-10-t1/stat/STATUS6 = {"StatusMQT":{"MqttHost":"geminipi.fritz.box","MqttPort":1883,"MqttClientMask":"DVES_%06X","MqttClient":"DVES_CA951313","MqttUser":"DVES_USER","MqttType":1,"MAX_PACKET_SIZE":1000,"KEEPALIVE":15}} 14:44:07 MQT: iot-so-10-t1/stat/STATUS7 = {"StatusTIM":{"UTC":"Sat Jan 19 13:44:07 2019","Local":"Sat Jan 19 14:44:07 2019","StartDST":"Sun Mar 31 02:00:00 2019","EndDST":"Sun Oct 27 03:00:00 2019","Timezone":99,"Sunrise":"08:35","Sunset":"17:26"}} 14:44:07 MQT: iot-so-10-t1/stat/STATUS10 = {"StatusSNS":{"Time":"2019-01-19T14:44:07"}} 14:44:07 MQT: iot-so-10-t1/stat/STATUS11 = {"StatusSTS":{"Time":"2019-01-19T14:44:07","Uptime":"0T18:07:43","Vcc":3.486,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":19,"POWER1":"OFF","POWER2":"OFF","Wifi":{"AP":1,"SSId":"BitSchleuder24","BSSId":"xx:xx:xx:xx:xx:xx","Channel":11,"RSSI":66}}} 14:44:18 MQT: Attempting connection... 14:44:22 MQT: Connected 14:44:22 MQT: iot-so-10-t1/tele/LWT = Online (retained) 14:44:22 MQT: iot-so-10-t1/cmnd/POWER = 14:44:33 MQT: iot-so-10-t1/stat/STATUS = {"Status":{"Module":29,"FriendlyName":["Gartenbrunnen","Zisterne"],"Topic":"iot-so-10-t1","ButtonTopic":"0","Power":0,"PowerOnState":3,"LedState":1,"SaveData":1,"SaveState":1,"SwitchTopic":"0","SwitchMode":[0,0,0,0,0,0,0,0],"ButtonRetain":0,"SwitchRetain":0,"SensorRetain":0,"PowerRetain":0}} 14:44:33 MQT: iot-so-10-t1/stat/STATUS1 = {"StatusPRM":{"Baudrate":115200,"GroupTopic":"sonoffs","OtaUrl":"http://sonoff.maddox.co.uk/tasmota/sonoff-minimal.bin","RestartReason":"Software/System restart","Uptime":"0T18:08:09","StartupUTC":"2019-01-18T19:36:24","Sleep":50,"BootCount":1817,"SaveCount":2010,"SaveAddress":"FA000"}} 14:44:33 MQT: iot-so-10-t1/stat/STATUS2 = {"StatusFWR":{"Version":"6.4.1.9(b5824fc-sonoff)","BuildDateTime":"2019-01-18T12:13:06","Boot":31,"Core":"2_5_0_BETA2","SDK":"3.0.0-dev(c0f7b44)"}}