energy measurement broken in latest dev version with MTS0121_plug (poll)
See original GitHub issueHi,
I’m runing the latest dev version (this to be specific) and the energy reporting doesn’t seems to work consistent.
I have 5 BlitzWolf SHP13 energy plugs in my zigbee network which support energy measurement via poll and the measurment worked fine until a few days(?) ago. It looks like that only a single device gets updated correctly now. All other 4 devices doesn’t seem to get updated energy measurements?
I saw the commit that changed the default poll interval to 60 seconds so I configured it back to 30 seconds (later to 15 sec for faster debugging).
This is my current devices config:
devices:
'0x842e14fffe359b2e':
friendly_name: niklas/plug/pc
measurement_poll_interval: 15
'0x842e14fffe3665fb':
friendly_name: niklas/plug/monitor
measurement_poll_interval: 15
'0x842e14fffe3665eb':
friendly_name: bathroom/plug/prusa_light
measurement_poll_interval: 15
To quickly debug I switched back to the latest stable version 1.16.2 and everything worked again. Here is how it looks in Home Assistant:
After that I switched back to the latest dev version and now only a single device (niklas/plug/pc) gets updated every 15 seconds:
I did enable the debug log but I can only see log entries for the niklas/plug/pc device. So there was not even an attempt to update the energy metrics from the other devices.
I don’t know how the internals work in zigbee2mqtt but my guess would be that the poll event loop is buggy and only checks the first device in the device config list?
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (5 by maintainers)
Found the bug, fixed now.
Changes will be available in the latest dev branch in a few hours (https://www.zigbee2mqtt.io/how_tos/how-to-switch-to-dev-branch.html)
I’m pretty sure it only started working with the new poll rate after I restarted mine…