# Virtual Device invalid capability

**URL:** <https://community.homey.app/t/virtual-device-invalid-capability/63636>\
**Category:** Apps\
**Tags:** app, flow\
**Created:** [May 14, 2022, 2:14pm UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636 "2022-05-14T14:14:59Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Thomas\_Buran](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/thomas_buran/32/107750_2.png) [@Thomas\_Buran](https://community.homey.app/u/Thomas_Buran)\
**Post date:** [May 14, 2022, 2:14pm UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636/1 "2022-05-14T14:14:59Z")

</div>

Hello guys,

I made simple weather station using ESP8266 Wemos which can measure temperature, humidity, maximum wind speed, wind speed, rainfall…

All of them are triggered to Homey as float. Looks like this:

```auto
Homey.trigger("temperatureOut", (float)Temperature);
Homey.trigger("windSpeed", (float)windSpeed); 

```

I created Virtual Device where I can “store” values…its working perfect with Temperature and Humidity but others don’t work. This is how looks my Virtual Device:

 ![Untitled](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/2/22871a740e7c2053f125daf7e48f2b23c446eb6c.png)

and here is example of flow which doesn’t works.  
[https://homey.app/f/9XlW23/](https://homey.app/f/9XlW23/)  
I get just “invalid capability” error. Any ideas? Thanks a lot.

---

<div class="post-metadata">

**Author:** ![JPe4619](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jpe4619/32/9017_2.png) [@JPe4619](https://community.homey.app/u/JPe4619)\
**Post date:** [May 14, 2022, 3:40pm UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636/2 "2022-05-14T15:40:49Z")

</div>

replace the “rain” tag with the capability in text.

---

<div class="post-metadata">

**Author:** ![Peter\_Kawa](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/peter_kawa/32/173848_2.png) [@Peter\_Kawa](https://community.homey.app/u/Peter_Kawa)\
**Post date:** [May 14, 2022, 4:29pm UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636/3 "2022-05-14T16:29:40Z")

</div>

Yup, something like `measure_rain`

List of all capabilities → [link](https://apps-sdk-v3.developer.homey.app/tutorial-device-capabilities.html)

---

<div class="post-metadata">

**Author:** ![RikkerdNL](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rikkerdnl/32/79224_2.png) [@RikkerdNL](https://community.homey.app/u/RikkerdNL)\
**Post date:** [October 25, 2023, 7:28am UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636/4 "2023-10-25T07:28:18Z")

</div>

Sorry to bump a old topic, but this was the only thing I could find. When using the capability in the flow like `measure_rain` how does the flow know which device to use?

Lets say we have 3 devices that has the capability `measure_rain` how does Homey knows which one we want to update? Because setting a virtual sensor to update the value does not work and shows the error `invalid capability`

---

<div class="post-metadata">

**Author:** ![JPe4619](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jpe4619/32/9017_2.png) [@JPe4619](https://community.homey.app/u/JPe4619)\
**Post date:** [October 25, 2023, 10:56am UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636/5 "2023-10-25T10:56:19Z")

</div>

> [@RikkerdNL](#):
>
> how does Homey knows which one we want to update?

The name of the device is in the top of the Card, and you have chosen the card that belongs to the virtual device:

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/d/1dea4a33c3fb205ba47d06a34c7a311487808f78.png)

> [@RikkerdNL](#):
>
> Because setting a virtual sensor to update the value does not work and shows the error `invalid capability`

In my opinion, you are thinking the wrong way around. The virtual sensor is not setting a value, but the value is set to the (capability off) the sensor.

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [October 25, 2023, 10:57am UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636/6 "2023-10-25T10:57:54Z")

</div>

> [@RikkerdNL](#):
>
> Because setting a virtual sensor to update the value does not work and shows the error `invalid capability`

Look one post up from yours. Or post a screenshot of your flow card.

---

<div class="post-metadata">

**Author:** ![RikkerdNL](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rikkerdnl/32/79224_2.png) [@RikkerdNL](https://community.homey.app/u/RikkerdNL)\
**Post date:** [October 25, 2023, 11:32am UTC](https://community.homey.app/t/virtual-device-invalid-capability/63636/7 "2023-10-25T11:32:08Z")

</div>

Thank you for the reply, after rechecking my flow I see it. Sorry for all the trouble. I have made a Homeyscript that gets a json and put in 1 of the json values to a homey tag. That one I use in a flow that saves the value to a sensor.

I am very new into Homey so again sorry for bumping this old topic.

@robertklep Yes this topic solved my issue because I first tried to save the value to the sensor instead of the capability.
