# \[APP\]\[Pro\] Home Assistant - Community App

**URL:** <https://community.homey.app/t/app-pro-home-assistant-community-app/71477>\
**Category:** Apps\
**Tags:** app, tools, homey-pro, home-assistant\
**Created:** [October 31, 2022, 8:25pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477 "2022-10-31T20:25:26Z")\
**Posts on this page:** 1\
**Showing post:** 1196

<div class="post-metadata">

**Author:** ![RonnyW](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ronnyw/32/10879_2.png) [@RonnyW](https://community.homey.app/u/RonnyW)\
**Post date:** [November 13, 2024, 3:04pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/1196 "2024-11-13T15:04:05Z")

</div>

Hi,

1st: You should think about removing the compound devices and replace it with custom devices.

About energy in general:  
Homey only uses measure\_power capability for the EnergyDashboard. That means, a device can only have one power capability. All others can only be added as subcapability (like measure\_power.sub1) and aren’t used for EnergyDashboard.

So let’s start 🙂  
I also use the Fronius HA integration. There is also a Homey app, but importing HA data into custom devices is a lot more flexible. You will see why…

I thought about all energy values I want to have…

- solar production
- grid usage
- grid feed-in
- house usage
- battery charging
- battery discharging

So I added all as a custom device with custom icon.  
Then I added the corresponding HA entity in rerpair view as measure\_power capability.

 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/9/b/9b24fa19e9975d77c9eb3a96e39a10850ef4c2eb.png)

Now you can change the device settings.  
Select “solarpanel” as device class for your solar production device.

 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/9/4/944ca4ce4ad503f06f69dfda5b9f3bac1922f9d3.png)  
Set house usage and grid usage as “cumulative” power usage.  
 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/7/8/78e132db894403240a45a6acd7eae7c29c56a629.png)  
Feed-in is also set as “cumulative” but also as “include in total”. This way it’s counted as power usage and substracted from production.  
 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/a/6/a61b43a8bf8c5440b0c9f6f7551f22e4661ff7de.png)

Battery is a special one. The HA integration has a sensor which has positive value for battery discharging (usage) and negative for charging.  
I want to see battery charging as “usage” power in Homey because it should be substracted from production.  
Battery discharging “returns” this energy. It works like a solarpanel. So I defined this device also as “solarpanel” device class.  
Both devices should only get “their” battery power part (negative/posisitve). I use the converter for:

Battery charging: Positive values are cleared (set to 0), negative values are used as negative (\*1 to convert HA string state into numeric Homey value). Solar panels have to report negative values (see developer docs for details).

 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/a/2/a2009c7376ed9ea8187c5807e9f4f99c37d46d5a.png)

Battery discharging: same, but for positive range:

 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/8/c82740d3bce61a086c00520025c3315fe282434e.png)

Good luck. To try the result, I used the mobile app for EnergyDashboarb while changing the devices in WebApp.

---

_[View the full topic](https://community.homey.app/t/app-pro-home-assistant-community-app/71477)._
