jankrib / ha-xcomfort-bridge

Eaton xComfort integration with Home Assistant
Apache License 2.0
30 stars 13 forks source link

Wrong Device classes and Unit of measurement for Power entities generated based on Heating Actuator with energy measurement. #30

Open gunmalmg opened 7 months ago

gunmalmg commented 7 months ago

Hi Thank you for providing us with a HA-integration for X-confort Bridge 👏

But there is i bug on Device class and Unit of measurement for Power entities generated based on Heating Actuator with energy measurement. These Heating Actuator with energy measurement provides 2 separate sensors:

The integration generates a correct entity for Energy (kWh) , but the Power entity has wrong Device class and Unit of measurement. (it has the same as the Energy entity) The Power entity should have Device class: Power , and Unit of measurement: W

This is a fundamental error - and I hope it is a easy error to fix. 🙏

Regards Gunnar

8A0E7016-1213-4E19-823C-6F081E820E48_4_5005_c

alex-w2 commented 1 month ago

@gunmalmg I made some changes in #34 which also includes the change you suggest. I don't have any devices actually reporting power/energy so can't test it though. Great if you're able to test, else we'll need to wait for the pull request to be merged.