zigbee2mqtt icon indicating copy to clipboard operation
zigbee2mqtt copied to clipboard

Hue connectivity issues

Open Koenkk opened this issue 6 years ago • 115 comments

It seems that still some users experience connectivity issues with Hue devices (especially the end devices like Hue dimmer remote and the motion sensors). While the issue of devices completely leaving seems to occur much less (#2693) the famous red LED still occurs (also for my Hue outdoor motion sensor).

The red LED will blink if the device did not receive an acknowledgment from the coordinator after it sends a command (default response in Zigbee terminology). I believe this happens when the Hue end device switches parent while the coordinator still has an old route to the end device. Eventually the coordinator recovers, but this will take a few seconds which is too late for these Hue devices causing the red LED to blink.

The latest dev branch contains a possible fix, it tries to detect when a Hue device switches parent and immediately rediscovers the new route after that. (https://www.zigbee2mqtt.io/how_tos/how-to-switch-to-dev-branch.html)

If with the latest dev branch people still experience we need to herdsman debug logging combined with a sniff at the moment the red LED blinks:

  • https://www.zigbee2mqtt.io/how_tos/how_to_sniff_zigbee_traffic.html
  • To enable herdsman debug logging, see https://www.zigbee2mqtt.io/information/debug.html#zigbee-herdsman-debug-logging

Koenkk avatar Oct 17 '20 14:10 Koenkk

Issue still persist with the latest dev branch and latest FW SW: 1.16.1-dev commit: ca33e22 FW: 20201026 Coordinator: cc1352p-2

timota avatar Nov 13 '20 19:11 timota

Some info regarding sensor. When sensor disappeared from network - 5 min later i just allowed joined (Permit Join) and it back again. Hope this cab be helpful. Unfortunately no debug.

timota avatar Nov 15 '20 00:11 timota

Hi @Koenkk, finally i have managed to catch debug for sensor. (link below) It contains 2000 lines before leave message and 500 after, hope this is enough for debug. Sensor is 0x001788010647face

Debug

Please let me know if you need more info.

Thanks in advance.

timota avatar Nov 27 '20 01:11 timota

@timota thanks for the good logs. I think the problem here is that the motion sensor switches parent, sends a message to the coordinator, the coordinator fails to acknowledge because it still think it has a different parent, the recovery takes too long making the motion sensor start rejoining/leaving. Looking at the logs we cannot fix this from zigbee2mqtt since we know too late if the acknowledgement fails and we have no indication that the motion sensor switched parent. That means it has to be fixed in the coordinator firmware.

I know this is hard but would you be able to create a sniff from the working situation till it stops working? https://www.zigbee2mqtt.io/how_tos/how_to_sniff_zigbee_traffic.html

Koenkk avatar Nov 27 '20 14:11 Koenkk

@Koenkk Sorry for late response. Debug and sniffer have been started. As soon as sensor fails i will post my findings.

Thanks

timota avatar Nov 29 '20 17:11 timota

@Koenkk, finally i managed to get dump (hope i sniffed traffic correctly). So, some background info:

issue happened: 2020-12-02T17:51:36.233Z zigbee-herdsman:controller:log Device leave '0x001788010647face'

Debug is huge (201m) so can't put it on pastebin - sharing google drive link sniff

If you will need zigbee2mqtt logs for this sniff - let me know.

Hope this helps. Thank.

timota avatar Dec 03 '20 15:12 timota

The problem seems to be that the coordinator sends a leave request to the motion sensor with rejoin set to false:

image

Not sure why it happens, but can you check if it is fixed with the following firmware: znp_CC1352P_2_LAUNCHXL_20201203_skip_leave.hex.zip

Koenkk avatar Dec 03 '20 21:12 Koenkk

FW installed. Container started with Full debug.

Will let you know results. Hopefully it will work as expected, fingers crossed.

timota avatar Dec 04 '20 00:12 timota

Fingers crossed, hoping for good results at your side so the FW can be fully released. Thanks both for the investigation/fixing time !

netweaver1970 avatar Dec 04 '20 08:12 netweaver1970

@timota No news is good news? No funny things happening/happened and no drop-out of the Hue motion sensor anymore?

netweaver1970 avatar Dec 14 '20 09:12 netweaver1970

Unreliable here

warn 2020-12-20 19:37:47: Device 'ID_HIDDEN' left the network info 2020-12-20 19:37:48: Device 'Sensor living room' joined info 2020-12-20 19:37:48: Starting interview of 'Sensor living room' info 2020-12-20 19:37:48: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":{"friendly_name":"Sensor living room"},"type":"device_connected"}' info 2020-12-20 19:37:48: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"interview_started","meta":{"friendly_name":"Sensor living room"},"type":"pairing"}' error 2020-12-20 19:40:40: Failed to interview 'Sensor living room', device has not successfully been paired

I use Electrolama zig-a-zig-ah! with official CC26X2R1_20201026.hex firmware Zigbee2mqtt 1.16.2

Can you provide a test firmware for CC26X2R1?

Thank you

I switched to 1.16.2-dev according to the first post to see if this is better.

0rsa avatar Dec 21 '20 05:12 0rsa

@netweaver1970 @Koenkk Morning guys,

sorry for a long response, was busy... During my testing with a new firmware i didn't see any disruptions. All sensors, including Hue are working as expected. Before consider fw as stable i would like to do another final test - move sensor outdoor as it should be and connect it via router. I'm going to do that today. I will let you know, hope to the end of this week, usually, before it (hue) fails at 2-3 days.

Regards.

timota avatar Dec 21 '20 09:12 timota

I have the LAUNCHXL-CC26X2R1 and am experiencing this issue. Dimmers I've never had a problem with, but motion sensors are the bane of my life right now.

It wasn't really a problem before the last 2 months or so, but I have added a lot more routers and this seems to tie in with what is being described here. Before they were most likely directly connected to the coordinator, now they are not.

It'll be good to see if this fixes the issue 😃

ellnic avatar Dec 22 '20 09:12 ellnic

I have CC2530_CC2591_20190523 zigbee 3.0 firmware now, and i sometimes experience the same problem. Unsure if it also has the same cause. Anyway, new firmware is always nice

ChessSpider avatar Dec 23 '20 21:12 ChessSpider

I can see this fix in latest release: #1925 #2274 Xiaomi Motion Sensor RTCGQ11LM not reporting occupancy true I have exactly the same behaviour for Hue sensors. After a couple of day, one sensor (random one) is sending occupancy: false even if the even is triggered by a motion. I give up, I purchased and I'm waiting for Xiaomi sensors working with gateway to remove zigbee2mqtt from my system.

0rsa avatar Jan 02 '21 10:01 0rsa

Any news on this? @Koenkk, if patch znp_CC1352P_2_LAUNCHXL_20201203_skip_leave.hex.zip is working are you going to port this on the main CC fw and on the Source Routing version? Thx

podi62 avatar Jan 04 '21 11:01 podi62

@timota is it working correctly now?

@podi62 yes but it needs more testing (first CC2652, after that CC2531)

Koenkk avatar Jan 04 '21 16:01 Koenkk

I have a CC2652RB and the same symptoms with my hue motion sensors.

So I could test the CC2652RB firmware. Is there a prebuilt one? And a tutorial how to flash the new firmware?

foxylion avatar Jan 04 '21 16:01 foxylion

Issue doesn't seem to be fixed, got a red light today on my hue motion outdoor sensor. 99% sure the issue has to be fixed in the firmware. Asked TI for support: https://e2e.ti.com/support/wireless-connectivity/zigbee-and-thread/f/158/t/968896

Koenkk avatar Jan 06 '21 19:01 Koenkk

Same issue also happens on ZHA (HomeAssistant) sometimes. So it doesn't look like it's a bug in either ZHA / Z2M.

TheJulianJES avatar Jan 06 '21 19:01 TheJulianJES