bieniu / ha-shellies-discovery

Script that adds MQTT discovery support for Shellies devices
Apache License 2.0
295 stars 90 forks source link

Problem with Shelly Dimmer and MQTT connection flag. #524

Closed thomasleitner closed 10 months ago

thomasleitner commented 10 months ago

Hi and thanks for putting so much effort into this. I have about 50 Shellys of different kinds in my network. Among them are two Shelly Dimmer (not Dimmer 2) devices and I have a problem with one of the two. In fact the problem seems to be related with the Shelly Firmware (v1.14 currently and also older versions). The problem is: even though the Shelly is connected to by Mosquito MQTT broker, the mqtt connection status is reported as false. See here:

{"wifi_sta":{"connected":true,"ssid":"XXXXXXXXXXX","ip":"10.xx.yy.zz","rssi":-61},"cloud":{"enabled":false,"connected":false},"mqtt":{"connected":false},"time":"18:07","unixtime":1704992847,"serial":1,"has_update":true,"mac":"CC50E3F3A890","cfg_changed_cnt":0,"actions_stats":{"skipped":0},"lights":[{"ison":true,"source":"http","has_timer":false,"timer_started":0,"timer_duration":0,"timer_remaining":0,"mode":"white","brightness":35,"transition":0}],"meters":[{"power":2.48,"overpower":0.00,"is_valid":true, "timestamp":1704996447,"counters":[2.552, 2.538, 2.528],"total":35}],"inputs":[{"input":0,"event":"","event_cnt":0},{"input":0,"event":"","event_cnt":0}],"tmp":{"tC":31.70,"tF":89.06, "is_valid":true},"calib_progress":0,"overtemperature":false,"loaderror":0,"overpower":false,"update":{"status":"pending","has_update":true,"new_version":"20230913-113908/v1.14.0-gcb84623","old_version":"20231107-164639/v1.14.1-rc1-g0617c15","beta_version":"20231107-164639/v1.14.1-rc1-g0617c15"},"ram_total":50272,"ram_free":36864,"fs_size":233681,"fs_free":129014,"uptime":878}

This causes the device to be unavailable in Homeassistant.

Question: Is there any way I could ignore the MQTT connection status for this device by using a special Shelly discovery option?

Thanks a lot // Tom

bieniu commented 10 months ago

No, there is no such option. The firmware issue should be resolved by Shelly team.

thomasleitner commented 10 months ago

Yes, this would be my first idea as well ... however, I fear that the Shelly Dimmer is already EOL and not really supported anymore ... in any case, I'll check again with Allterco ... Thanks.

bieniu commented 10 months ago

Maybe you should try factory reset?

thomasleitner commented 10 months ago

Yes, will try that.