Koenkk / zigbee2mqtt

Zigbee šŸ to MQTT bridge šŸŒ‰, get rid of your proprietary Zigbee bridges šŸ”Ø
https://www.zigbee2mqtt.io
GNU General Public License v3.0
12.22k stars 1.69k forks source link

Issues with Green Power devices past 1.36.1 #24119

Open DennisJohnsen opened 2 months ago

DennisJohnsen commented 2 months ago

What happened?

Hello

So i'm in a bit of a pickle atm. I'm currently running 1.36.1, but there is a fix in 1.40.1 for something else i would like. I digress.

But all versions past 1.36.1 (I've tried 1.40.1 and 1.40.0 and 1.38.0) causes over half of my Green Powered devices to stop responding with any action. They show up in the UI just fine, but no action is sent to MQTT when clicking them, but it seems to some of them. It seems random which ones work and doesn't work, nothing with range to the Zigbee adapter. So i'm at a bit of a loss.

The devices in question: https://www.zigbee2mqtt.io/devices/PTM_215Z.html#enocean-ptm%2520215z

As soon as i revert back to 1.36.1 they all just work as expected again when Zigbee2Mqtt is running again.

I tried to interact with two switches in the log, one that works and one that doesn't. Not sure if makes a difference or not. The one that works: 0x00000000017199a1 The one that doesn't work: 0x000000000171db5f

Zigbee2MQTT version

1.40.1

Adapter firmware version

0x26690700

Adapter

Raspbee 2

Setup

Raspberry PI x86 via Docker

Debug log

log.log

chris-1243 commented 2 months ago

You should check #23814. Try the latest-dev. Your problem should be fixed.

There was unfortunately a bug in the deconz driver only.

DennisJohnsen commented 2 months ago

Hmm, the same issue with :latest-dev. Only a few of my switches work. At least it's consistent the same switches that works/fails with these different versions than 1.36.1

:latest-dev seems to be restarting though. Heres just a quick look at the logs without debug enabled:

Using '/app/data' as data directory
Starting Zigbee2MQTT without watchdog.
[2024-09-29 10:04:12] error:    z2m: Cannot find '0x00178801093e0030/11' of group 'Stue'
[2024-09-29 10:04:12] error:    z2m: Cannot find endpoint '11' of device '0x00178801093e0030'
Error: waiting for response TIMEOUT
    at DeconzAdapter.checkReceivedDataPayload (/app/node_modules/zigbee-herdsman/src/adapter/deconz/adapter/deconzAdapter.ts:718:28)
    at Timeout._onTimeout (/app/node_modules/zigbee-herdsman/src/adapter/deconz/adapter/deconzAdapter.ts:77:18)
    at listOnTimeout (node:internal/timers:569:17)
    at processTimers (node:internal/timers:512:7)
Using '/app/data' as data directory
Starting Zigbee2MQTT without watchdog.
[2024-09-29 10:06:11] error:    z2m: Cannot find '0x00178801093e0030/11' of group 'Stue'
[2024-09-29 10:06:11] error:    z2m: Cannot find endpoint '11' of device '0x00178801093e0030'
Error: waiting for response TIMEOUT
    at DeconzAdapter.checkReceivedDataPayload (/app/node_modules/zigbee-herdsman/src/adapter/deconz/adapter/deconzAdapter.ts:718:28)
    at EventEmitter.<anonymous> (/app/node_modules/zigbee-herdsman/src/adapter/deconz/adapter/deconzAdapter.ts:70:18)
    at EventEmitter.emit (node:events:517:28)
    at parseReadReceivedDataResponse (/app/node_modules/zigbee-herdsman/src/adapter/deconz/driver/frameParser.ts:361:27)
    at parseFrame (/app/node_modules/zigbee-herdsman/src/adapter/deconz/driver/frameParser.ts:566:32)
    at processFrame (/app/node_modules/zigbee-herdsman/src/adapter/deconz/driver/frameParser.ts:515:53)
    at Driver.<anonymous> (/app/node_modules/zigbee-herdsman/src/adapter/deconz/adapter/deconzAdapter.ts:63:25)
    at Driver.emit (node:events:517:28)
    at Driver.onParsed (/app/node_modules/zigbee-herdsman/src/adapter/deconz/driver/driver.ts:881:14)
    at Parser.emit (node:events:517:28)
Using '/app/data' as data directory
Starting Zigbee2MQTT without watchdog.
[2024-09-29 10:07:36] error:    z2m: Cannot find '0x00178801093e0030/11' of group 'Stue'
[2024-09-29 10:07:36] error:    z2m: Cannot find endpoint '11' of device '0x00178801093e0030'

I will try to add legacy_triggers: true to my config, and set logging info to debug and post a full log.

DennisJohnsen commented 2 months ago

Still no dice. The same switches still fail/work on :latest-dev

I attached the log for this restart, where i interacted with both a working switch and a failing one. Same devices as mentioned above

The one that works: 0x00000000017199a1 The one that doesn't work: 0x000000000171db5f

I was unsure where to put legacy_triggers: true so i tried both in the root of the config, and also nested under advanced.

log from :latest-dev

DennisJohnsen commented 1 month ago

I just tried 1.40.2 today, same issue.

DennisJohnsen commented 1 month ago

Same issue as of 28-10-2024 with latest-dev.

chris-1243 commented 1 month ago

Could you try to factory reset one device not working and try to pair it.

Carefully read this

https://www.zigbee2mqtt.io/advanced/zigbee/01_zigbee_network.html#green-power-devices

Pair your device without using the permit join all. Choose a compatible router and use permit join via router_x

DennisJohnsen commented 1 month ago

Could you try to factory reset one device not working and try to pair it.

Sure i guess. It's gonna be a pain if i have to. These PTM 215Z are super finicky to reset and repair, and i have +14 of them that are failing with the newer builds šŸ„²

Will try later when the family is in bed.

DennisJohnsen commented 1 week ago

So i tried to remove a switch.

Put it into pairing mode as specified here. And not using permit all, but directly to coordinator, with direct line of sight. And nothing.

If i remove the battery from the switch. Hold Top left button to join my zigbee channel 15 network, and then confirm as per the documentation - it pairs just fine. With its random friendly name. But it's stuck in "Offline" and nothing is exposed when i click the buttons.

Even with this pairing i did in 1.41.0 i kept, went back to 1.36.1 and it works instantly.

Something weird is going on. Is there a arbitrary limit being imposed of the number of allowed green power devices? I have a total of 17. And for some reason this error appeared after 1.36.1

chris-1243 commented 1 week ago

If i remove the battery from the switch. Hold Top left button to join my zigbee channel 15 network, and then confirm as per the documentation - it pairs just fine. With its random friendly name. But it's stuck in "Offline" and nothing is exposed when i click the buttons.

Which ZGP device do you try to pair ? Would you mind to try once but this time, do not use the coordinator but a router close to your device. This list is not exhaustive.

DennisJohnsen commented 1 week ago

I dont have any devices that is on that list though. So i tried with the cordinator, which works just fine on 1.36.1 - so i dont see why i have to specifically use one of those devices to pair to. Even pairing it just fine on 1.41.1, but nothing on exposed until i just roll software back to 1.36.1.

But i have these Ikea and Philips hue devices. Maybe you can help me indicate if one of those are considered a proper Green Power router:

IKEA

Philips Hue

chris-1243 commented 1 week ago

From version 1.36 to 1.41, the dev might have done some changes. ember driver had several changes and a huge improvement to pair ZGP devices through specific routers for example.

The list provided is not exhaustive at all. It is based on users who checked the compatibility. I added some based on what I have. What would be awsome is if you could try yours and check the output and maybe extend this list. Do not forget, a lot is done by the dev and the community. It is a way to improve the software we are using. By experience, HUE device are able to translate easily ZGP frames. There is one issue with them. Depending on the model and firmware, the data might be transmitted by unicast (much better) or broadcast. #22897 Recent IKEA devices seem to implement well ZGP translation as unicast. You should avoid to pair your device as broadcast as your network might become slow and there is a limit. Only 7-8 messages/second are sent. More messages will be queued and you will see the latency. Honestly and when you pair your device via the coordinator, I do not know how it is done (unicast/broadcast). The only way to know is to sniff your traffic.

Would you mind specify which ZGP devices is causing issues? We may then check the converters or deeper in the code to find the errors. A debug log while pairing a device not working could help as well. It might be outside of my knowledge but at least we would have data to work with.

DennisJohnsen commented 1 week ago

I would love to help expand on that list with the devices i have - but i would need some a step by step guide to check the output of the devices so i can confirm if they use broadcast or unicast for green power. Would also make me able to see if i can pair one of my failing devices directly to a unicast device instead and see if that helps.

The only greenpower devices i have is this switch.

It's always the same switches that works/fail when moving from 1.36.1 to something more recent.

Luckily i havn't had any "slow" devices, even though i have a pretty big Zigbee network.

Total 116
Router: 54
End devices: 45
GreenPower: 17

I have, because of just reading that most Phillips Hue is required for greenpower devices, scattered Phillips Hue bulbs strategically around the house. So they might just be unicast since i havn't experienced issues with performance expect when some updates came along that broke something.

I will get on the log file while paring (to the coordinator) a switch that doesn't work on 1.41.0 as soon as possible.