Koenkk / zigbee2mqtt

Zigbee 🐝 to MQTT bridge 🌉, get rid of your proprietary Zigbee bridges 🔨
https://www.zigbee2mqtt.io
GNU General Public License v3.0
11.78k stars 1.64k forks source link

Xiaomi ZNCZ04LM energy monitoring does not working with Sonoff Dongle -E #14299

Closed artlov closed 1 year ago

artlov commented 1 year ago

What happened?

Power, energy, device temperature, voltage , current, consumer_connected - all they with status Null. When try to refresh power, error generated: 2022-10-03 11:57:36 Publish 'get' 'power' to '0x04cf8cdf3c7e3215' failed: 'TypeError: Cannot read properties of undefined (reading 'read')'

What did you expect to happen?

No response

How to reproduce it (minimal and precise)

No response

Zigbee2MQTT version

1.28.0-1

Adapter firmware version

6.10.3.0 build 297

Adapter

SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2

Debug log

Debug 2022-10-03 12:15:42 Received MQTT message on 'zigbee2mqtt2/0x04cf8cdf3c7e3215/get' with data '{"power":""}' Debug 2022-10-03 12:15:42 Publishing get 'get' 'power' to '0x04cf8cdf3c7e3215' Error 2022-10-03 12:15:42 Publish 'get' 'power' to '0x04cf8cdf3c7e3215' failed: 'TypeError: Cannot read properties of undefined (reading 'read')' Debug 2022-10-03 12:15:42 TypeError: Cannot read properties of undefined (reading 'read') at Object.convertGet (/app/node_modules/zigbee-herdsman-converters/converters/toZigbee.js:2263:28) at Publish.onMQTTMessage (/app/lib/extension/publish.ts:273:37) at EventEmitter.emit (node:events:539:35) at EventBus.emitMQTTMessage (/app/lib/eventBus.ts:109:22) at MQTT.onMessage (/app/lib/mqtt.ts:140:27) at WebSocket. (/app/lib/extension/frontend.ts:94:27) at WebSocket.emit (node:events:527:28) at Receiver.receiverOnMessage (/app/node_modules/ws/lib/websocket.js:1178:20) at Receiver.emit (node:events:527:28) at Receiver.dataMessage (/app/node_modules/ws/lib/receiver.js:528:14) Info 2022-10-03 12:15:42 MQTT publish: topic 'zigbee2mqtt2/bridge/log', payload '{"message":"Publish 'get' 'power' to '0x04cf8cdf3c7e3215' failed: 'TypeError: Cannot read properties of undefined (reading 'read')'","meta":{"friendly_name":"0x04cf8cdf3c7e3215"},"type":"zigbee_publish_error"}'

cfluegel commented 1 year ago

I have the same issue. I get no information from the power plug. The firmware of my ZNCZ04LM is 01-23-2022. It seems to be a "problem" with the firmware because another power plug with the same coordinator works flawlessly.

I can guess the answer but I hopeful that I am wrong. There is no way of downgrading a firmware, right?

The coordinator revision is 20210708. Would it be helpful to update my coordinator usb stick? the latest coordinator firmware did not change the behavior of the power plug. So, do not use OTA would be the answer for right now, I guess.

hugocib commented 1 year ago

I report the same issue after updating OTA to the 01-23-2022 firmware

Slayer-24 commented 1 year ago

Same issue here. Is there still no option to downgrade the firmware?

sfiel commented 1 year ago

I needed to upgrade the firmware of the coordinator USB stick and then everything was working fine again. HowTos can also be found on the zigbee2mqtt homepage

cfluegel commented 1 year ago

That sounds great. Could you post the release date of the firmware that worked for you? The version I tested two weeks ago did not work and I want to make sure I use the same release for my adapter.

hugocib commented 1 year ago

That sounds great. Could you post the release date of the firmware that worked for you? The version I tested two weeks ago did not work and I want to make sure I use the same release for my adapter.

I confirm that updating the coordinator's firmware got it reporting again. It's running Z-Stack_3.x.0 20220219 (SONOFF Zigbee 3.0 USB). I unpaired the ZNCZ04LM, rebooted the system and paired it again. It did the trick.

cfluegel commented 1 year ago

Thank you my friends. Indeed it is working with the newest (20220219) firmware. It seems I forgot to remove the power adapter from my network, but it seems that is necessary. So, update your coordinator; remove the zigbee device from zigbee2mqtt and re-add it.

Slayer-24 commented 1 year ago

Thank you all, I did replace my old CC2531 with a Sonoff CC2653P (with latest FW). After re-join everything works fine.

github-actions[bot] commented 1 year ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days

github-actions[bot] commented 1 year ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days

gyraksi commented 1 year ago

I still have this issue with another coordinator as well. My coordinator is tindie zzh! CC2652R Multiprotocol RF Stick with firmware zStack3x0 revision 20210120. The ZNCZ04LM Mi Power Plug firmware is 01-23-2022.