# \[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:** 20\
**Page:** 7

<div class="post-metadata">

**Author:** ![Marcel\_Visser](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marcel_visser/32/66024_2.png) [@Marcel\_Visser](https://community.homey.app/u/Marcel_Visser)\
**Post date:** [November 17, 2022, 8:36pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/122 "2022-11-17T20:36:57Z")

</div>

Another question… There is no option to use a scene as trigger. So, WHEN “scene x” has been triggerd, THAN…

Is this something you can fix? Or is this not possible… Please let me know if this is something I have to add to the wiki. 🤗

---

<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 17, 2022, 9:10pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/123 "2022-11-17T21:10:55Z")

</div>

I haven’t seen a scene trigger in the API. I think you cannonly set a scene. HA doesn’t send information back about a set scene because that’s a HA internal automation.

Edit: I checked in detail. There are only events for scripts started and automation triggered, but not for a set scene.

> **[Events](https://www.home-assistant.io/docs/configuration/events/)**
>
> Describes all there is to know about events in Home Assistant.

---

<div class="post-metadata">

**Author:** ![Arjan-21](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arjan-21/32/27181_2.png) [@Arjan-21](https://community.homey.app/u/Arjan-21)\
**Post date:** [November 17, 2022, 10:52pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/124 "2022-11-17T22:52:39Z")

</div>

After the new update there is no way to change the device class of a switch. The feature is really handy if you use “all the light off” or an app like Vthermo with a switch.  
The first picture is a switch I added yesterday and the second one is a device I just add. It’s both the same switch.

The picture is in dutch. To show the change.

 ![IMG_6444](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/c/1c33e6d94dfe56eeeff034411f740b5f24d718d6.png)

 ![IMG_6445](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/6/16ead8484003f66d8fc945e6296948873edee2b7.png)

---

<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 18, 2022, 6:23am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/125 "2022-11-18T06:23:42Z")

</div>

> [@Arjan-21](#):
>
> no way to change the device class of a switch

Yes, you are right.  
I changed the device type for a switch from “plug” to “button” to appear in the “right” area of the add device dialog, because as there are so many devices now it’s shown in device type rows:

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

As there is no “switch” device type in Homey I can only recert back to “socket” type.

Then it will look like this:

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

---

<div class="post-metadata">

**Author:** ![Arjan-21](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arjan-21/32/27181_2.png) [@Arjan-21](https://community.homey.app/u/Arjan-21)\
**Post date:** [November 18, 2022, 8:36am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/126 "2022-11-18T08:36:28Z")

</div>

For me, that’s the best solution. This way you can say for yourself what is plugged into a switch and use ‘turn on all lights’ or for other purposes like Vthermo.

It will be a bit more area’s, but you can use a switch the way you want.

---

<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 18, 2022, 8:43am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/127 "2022-11-18T08:43:54Z")

</div>

It’s ok. I will change it back in the next version.

---

<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 18, 2022, 9:17am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/128 "2022-11-18T09:17:21Z")

</div>

New **test version 0.4.1** :

- Changed device class for the switch back to “socket” to be able to change the device class.
- Fix for correctly unregistering devices when deleting

---

<div class="post-metadata">

**Author:** ![Arjan-21](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arjan-21/32/27181_2.png) [@Arjan-21](https://community.homey.app/u/Arjan-21)\
**Post date:** [November 18, 2022, 9:18am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/129 "2022-11-18T09:18:33Z")

</div>

Thank you!!

---

<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 18, 2022, 2:10pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/130 "2022-11-18T14:10:48Z")

</div>

## Example of adding air quality (purifier) data to Homey as compound device

@Wesley_Witjes @Marcel_Visser

I would like to show the way to define a compound device for airpurifier or air quality details in general.

Home Assistant has another way of device definition than Homey.  
The elements, HA is working with, are the entities (switch, sensor, fan…). Each entity is the base component for the Homey device you can add directly.

For example, a climate device is defined in HA as entity with a defined set of attributes, modes and services. This entity is imported as device to Homey to offer a seamless control as it would be a Homey internal device.

The HA “devices” are just a set of (independent) entities. If you don’t use special Lovelace dashboard controls, you need to add each sensor or switch as entity to your Lovelace dashboard. There you can see that they are not directly dependent to the climate/fan device.

That’s my example of a Dyson fan/heater/purifier:

 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/7/d/7df0cf2edabc251cd6d4efc178cab8534b7aace4.png)  
You can see the climate an fan entity that can be added as Homey device.  
All other entities for air quality data are differnent sensors or switches. And there will be a lot of different versions for all the purifiers of different brands.  
So there is no good possibility to add these sensors into a climate/fan device.  
You can add every sensor as single device to Homey and place all devices into a “room”. That would be analogous to the Lovelace dashboard adding each entity as Lovelace element.

The better way is to combine these air quality data into a compound device.

- Search all the sensors and switched by the device name in the HA entity list
- If you need to know the data type (numeric/char), you can list the entities in the developer view.
- Create a compound definition, use the best fitting Homey measure type (or the generic measure\_numeric for numberns or measure\_generic for text)  
All possible meassure capabilities can be found in the repository description (link below).
- If you are using a capability more than once in the capabilities list, make sure you add a subcapability id using the format “capability.subcapability”.

```yaml
dyson_air:
  name: Dyson Air quality
  capabilities:
    onoff.continuous: switch.pure_hot_cool_continuous_monitoring
    onoff.night: switch.pure_hot_cool_night_mode
    measure_humidity: sensor.pure_hot_cool_humidity
    measure_temperature: sensor.pure_hot_cool_temperature
    measure_numeric.no2: sensor.pure_hot_cool_nitrogen_dioxide
    measure_numeric.pm25: sensor.pure_hot_cool_pm_2_5
    measure_numeric.pm10: sensor.pure_hot_cool_pm_10
    measure_numeric.organic: sensor.pure_hot_cool_volatile_organic_compounds
    measure_numeric.filtercarb: sensor.pure_hot_cool_carbon_filter_life
    measure_numeric.filterhepa: sensor.pure_hot_cool_hepa_filter_life
  capabilitiesTitles:
    onoff.continuous: Continuous Monitoring
    onoff.night: Night Mode
    measure_humidity: Humidity
    measure_temperature: Temperature
    measure_numeric.no2: NO2
    measure_numeric.pm25: PM 2.5
    measure_numeric.pm10: PM 10
    measure_numeric.organic: Organics
    measure_numeric.filtercarb: Filter Carbon
    measure_numeric.filterhepa: Filter Hepa

```

Added to Homey it looks this way:

 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/6/b68e8738c419521473a5d1524d3886f962850737.png)  
The first uses switch is used as quick action for the tile.  
The sensors are shown in device details:  
 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/9/c9fe4d4f19ec9510f1c92863ad28743db94cc97f.png)

If your HA entity does not provide a unit, you can set it in the YAML definition:

```yaml
  capabilitiesUnits:
    measure_numeric.no2: my unit

```

Don’t know how to install the custom component to HA?  
Here is a description:

> [@\[APP\]\[Pro\] Home Assistant - Community App](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/4):
>
> Detailed descriptions and examples HA custom\_component Installation (HACS) Open HACS in Home Assistant, select “Search and download repositories”. Search for “homey” and install the integration. [grafik] Installation (manually) → Download the files from [Github: custom\_component/homey](https://github.com/RonnyWinkler/homeassistant.homey) and copy them to a new folder “homey” in your HA configuration: /config/custom\_components/homey → Then restart HA to load this component. YAML configuration → If you want to include the YAML defi…

And here you can find the component:

> **[GitHub - RonnyWinkler/homeassistant.homey: Homey compound device component](https://github.com/RonnyWinkler/homeassistant.homey)**
>
> Homey compound device component

You can install it as file of if you are using HACS, you can just add this repository as custom component.  
A direct HACS import is in work…

---

<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 18, 2022, 3:23pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/131 "2022-11-18T15:23:35Z")

</div>

> [@Marcel\_Visser](#):
>
> Another question… There is no option to use a scene as trigger. So, WHEN “scene x” has been triggerd, THAN…

Hi Marcel,  
good news. I found a way to react on a activated script. The entity state (timestamp) changes on activation and that can be used as trigger.  
So there will be a device trigger for scripts in the next version 🙂

---

<div class="post-metadata">

**Author:** ![Marcel\_Visser](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marcel_visser/32/66024_2.png) [@Marcel\_Visser](https://community.homey.app/u/Marcel_Visser)\
**Post date:** [November 18, 2022, 6:21pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/132 "2022-11-18T18:21:43Z")

</div>

Great!! Thanks for the explanation! 😃 I’m running an custom compound already. I will follow your example for my purifier. 👍🏻

---

<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 19, 2022, 10:11am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/133 "2022-11-19T10:11:07Z")

</div>

**Test version 0.4.2** is online

Added trigger for:

- scene device trigger
- script device trigger
- script app trigger with script name filter
- automation app trigger with automation name filter

Now all scenes/scripts/automations can be traced in Homey.

@Marcel_Visser You can test the trigger for scene device now 🙂

---

<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 20, 2022, 5:23pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/134 "2022-11-20T17:23:34Z")

</div>

If you have HACS already installed in your HomeAssistant system, you can add the Homey Compound integration directly to HACS (sorry, screenshot is only german):

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

Open HACS / Integrations, click on “Search and download repositories” and search for “homey”.

---

<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 21, 2022, 7:23am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/135 "2022-11-21T07:23:20Z")

</div>

New **live version 0.4.3** :  
You can **send now notifications via HA** using the three new flow action cards (on app level):

1. This is a general version for sending simple text notifications to HA. HA will use the defautl notify service to process this message. As default this will result in a push message for the HA mobile app.  
 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/5/1535d4334b4bf6da0cdcfad824ae5f2c70cc8a12.png)

2. The second is similar but offers a service selection. You can send notification to other services (your TV, message provider…).  
 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/6/a/6af22bce3f93f96a8be88a5d5ea97b4292365eee.png)

3. The 3th one offes an image token in addition. You can send a notification including a Homey image like it’s done with the Homey image push messages.  
 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/4/c43fe62aff845741d2b75fe5f10364d5903b11bb.png)  
The image is passed as URL. You can select whether Homeys local or cloud URL should be used (dependent on your network topology)

This works with the HA notify domain (all services starting with “notify.”) and with other services named “.send\_message” or “.send\_photo” like the telegram bot.

---

<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 23, 2022, 8:30am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/136 "2022-11-23T08:30:31Z")

</div>

New **test version 0.5.0** :

- Added cover and lock device  
 ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/d/4/d4356fba4fdd2d2050b17557d4d8e5d829a2d5d1.png) ![grafik](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/a/b/ab705f6b1e2bb044bc266a517f067a2bb45fc707.png)

---

<div class="post-metadata">

**Author:** ![Marcel\_Visser](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marcel_visser/32/66024_2.png) [@Marcel\_Visser](https://community.homey.app/u/Marcel_Visser)\
**Post date:** [November 23, 2022, 6:18pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/137 "2022-11-23T18:18:58Z")

</div>

Great progress again!!!

---

<div class="post-metadata">

**Author:** ![Robin\_van\_Kekem](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robin_van_kekem/32/8187_2.png) [@Robin\_van\_Kekem](https://community.homey.app/u/Robin_van_Kekem)\
**Post date:** [November 23, 2022, 7:13pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/138 "2022-11-23T19:13:55Z")

</div>

It just never stops! 🥰

---

<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 25, 2022, 3:37pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/139 "2022-11-25T15:37:01Z")

</div>

New **test version 0.5.1** :

There are some new flow action for lights for different light adjustments:

- set light color with color picker (including hue, saturation, dim)
- set light color by name
- set light color by name and adjust dim value
- set light temperature and dim value
- set light hue, saturation and dim value

The first one is the easiest color selection.  
The name selection offers the original color in one card and a combination with dim in the other card.  
The last two cards are combining color selection and dim for light change with only one service call. This avoids a seperate dim and color step and enables you to create instant and smooth light transitions.

---

<div class="post-metadata">

**Author:** ![Andi](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/andi/32/160466_2.png) [@Andi](https://community.homey.app/u/Andi)\
**Post date:** [November 26, 2022, 10:13pm UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/140 "2022-11-26T22:13:24Z")

</div>

is there a possibility to “round” values to 2 decimals (AUSGABEN & EINNAHMEN)?

example:

```auto
> huaweipricing_compound:
> name: Stromkosten
> icon: measure_generic
> capabilities:
> **measure_numeric.consumption_cost: sensor.huawei_power_meter_consumption_cost**
> measure_numeric.energy_price: sensor.energy_price
> **measure_numeric.exported_compensation: sensor.huawei_power_meter_exported_compensation**
> measure_numeric.energy_price_export: sensor.energy_price_export
> capabilitiesTitles:
> measure_numeric.consumption_cost: "Ausgaben"
> measure_numeric.energy_price: "Tarif"
> measure_numeric.exported_compensation: "Einnahmen"
> measure_numeric.energy_price_export: "Rückliefertarif"
> capabilitiesUnits:
> measure_numeric.consumption_cost: "CHF"
> measure_numeric.energy_price: "CHF/kWh"
> measure_numeric.exported_compensation: "CHF"
> measure_numeric.energy_price_export: "CHF/kWh"

```

 ![20221126_221125000_iOS](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/9/8/98dec30e6b61976b37a2d76874e802c63638bdc2.jpeg)

---

<div class="post-metadata">

**Author:** ![GRat](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/grat/32/17928_2.png) [@GRat](https://community.homey.app/u/GRat)\
**Post date:** [November 27, 2022, 11:02am UTC](https://community.homey.app/t/app-pro-home-assistant-community-app/71477/141 "2022-11-27T11:02:43Z")

</div>

I’m wanting to add power consumption to my lights so I can track these in Homey, so looked at creating a compound device for these.  
The power works well, but how do I add Dimmer and colour functions?

```auto
light:
  name: Kitchen Light
  capabilities:
    onoff: light.kitchen_light
    dim: input_number.set_value
    meter_power: sensor.kitchen_light_power_2
    measure_power: sensor.kitchen_light_electric_consumption_kwh
  capabilitiesConverters:
    dim: 
      from: (state) => { return parseFloat(state) * 0.01; }
      to: (value) => { return value * 100; }

```

[Previous page](https://community.homey.app/t/app-pro-home-assistant-community-app/71477.md?page=6)

[Next page](https://community.homey.app/t/app-pro-home-assistant-community-app/71477.md?page=8)
