Add exposed feature for SE summation polling#660
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #660 +/- ##
======================================
Coverage ? 97.51%
======================================
Files ? 62
Lines ? 10949
Branches ? 0
======================================
Hits ? 10677
Misses ? 272
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
This is updated to use a constant for the exposed feature from quirks. Tests will pass with the bump, though diagnostics will need to be regenerated then. I'll mark this as ready for review, so it's not forgotten about. This is required for Ubisys devices to work properly. |
d8f2905 to
0d6f27a
Compare
|
I'll add all the Ubisys diagnostics in a follow-up PR in the next few days. It's not critical for the release. |
Proposed change
This adds separate entity classes based on an exposed quirks feature/hint, so that the Smart Metering's
current_summ_deliveredandcurrent_summ_receivedattributes are polled automatically by ZHA then.Additional information
The
"se_poll_summation"exposed feature will be added to zha-quirks. Then, this PR will be changed to use that exposed feature constant.Weirdly enough, the Zigbee spec doesn't specify that these two attributes are reportable, yet some devices seem to support it. For the EM cluster, we always poll by default. For the SE cluster, we only poll for select models
"TS011F", "ZLinky_TIC", "TICMeter". These can (mostly) be switched to instead expose the polling feature/hint in quirks soon.Ubisys diagnostics will be added soon. That should be enough to cover these new entities IMO, since the polling is the same and already tested elsewhere. The diagnostics will contain the class name, so check if the exposed feature matching works in this case.