# \[APP\]\[Pro\] Device Capabilities - Enhance the capabilities of devices

**URL:** <https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287>\
**Category:** Apps\
**Tags:** flow, virtual-device, homey-pro, device-capabilities, avd\
**Created:** [February 19, 2021, 8:20am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287 "2021-02-19T08:20:51Z")\
**Posts on this page:** 20\
**Page:** 34

<div class="post-metadata">

**Author:** ![Kai\_Engvik](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/kai_engvik/32/48687_2.png) [@Kai\_Engvik](https://community.homey.app/u/Kai_Engvik)\
**Post date:** [September 21, 2022, 5:46pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/668 "2022-09-21T17:46:02Z")

</div>

Do you mean like this, with a dash instead?  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/7/87c438656b804f69304a5b8e185b90e8c9baeeb1.png)

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 21, 2022, 7:23pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/669 "2022-09-21T19:23:02Z")

</div>

Indeed.

I have requested Athom to be able to show a text without a number or dash, since there is a difference between the Web App en Mobile App and the need to fix that: i hope they will make it a possibility, but we’ll see.

---

<div class="post-metadata">

**Author:** ![HuisCHovens](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/huischovens/32/16973_2.png) [@HuisCHovens](https://community.homey.app/u/HuisCHovens)\
**Post date:** [September 21, 2022, 8:22pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/670 "2022-09-21T20:22:01Z")

</div>

Nice addition sharing devices and flows.  
@Peter_Kawa I have tried your ram flow i only get this.

 ![Screenshots_2022-09-21-22-17-50](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/9/c9eb054b1ea4beff1d4760867a3cbd02f44cf7bb.png)

I kept name as in the example. And tokens don’t change.

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 21, 2022, 8:23pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/671 "2022-09-21T20:23:12Z")

</div>

I’ll check his avd and flow out tomorrow.

---

<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:** [September 21, 2022, 9:14pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/672 "2022-09-21T21:14:19Z")

</div>

> [@HuisCHovens](#):
>
> i only get this

(Link to [that shared ADV](https://community.homey.app/t/advanced-virtual-device-share-your-device/68676/12) , for your and my convenience)

Thanks for trying. This one has a bit explanation needed.

As explained in the flow card you’ll have to run the flow at least once, then the HomeyScript variables are created on the fly. Then, the “onbeschikbaar” (“unavailable”) tags should change into the ones of my flow screenshot.  
 ![Screenshot from 2022-09-21 23-11-06](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/f/1/f11933afb1a7fcf594bf2de2b0315dba22424ade.png)

And, _keep in mind, the HomeyScript flowcard is imported as DeviceCapabilities ‘clone’._ **Explanation below!**  
 ![Screenshot from 2022-09-21 23-22-29](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/f/0/f06dc1d9c2e00537efa737a49abd8bbf4161ba43.png)  
  
  
So, click on the blue text, copy the script inside of it (ctrl-A ctrl-C),

![Screenshot from 2022-09-21 23-15-54](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/f/bf9deef235904584898279b44adca09a3535c7fb.png)  
  
  
and replace the card with an _ **AND type card** _ HomeyScript “Run code”,  
 ![Screenshot 2022-09-21 at 23-37-28 1.HomeyPro Peter](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/f/2/f2fcad052daec069a03561aedab5081a1ce7ba49.png)

so it should look as the card in the screenshot above, and paste the just copied script.  
  
  
**Homeyscript and Device Capabilities import**

> [@Arie\_J\_Godschalk](#):
>
> HomeyScript has been “disabled” in the import.  
> Whenever a flowcard is of HomeyScript, it gets replaced with my App.  
> Meaning that the flow stays allright, the code just cannot be triggered automaticly, and you need to replace the card with the HomeyScript cards, keeping (when clicking Replace) the lines and tags all in order!
> 
> It also means, that whenever HomeyScript adds cards, it will still gets replaced, just with a card that doesn’t exists (i’ve “copied” all current HomeyScript cards), thus it will just grey-out (giving me time to implement the new card).
> 
> This implementation might feel straings to some, but you don’t want the ability to import “random” flows which might contain a HomeyScript that runs every seconds and sends keys and codes (only accessible to HomeyScript) to a server somewhere, only to find out what is in the code after it has allready send it.
> 
> Beter save then sorry.

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 22, 2022, 9:53am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/673 "2022-09-22T09:53:25Z")

</div>

Hey @HuisCHovens and @Peter_Kawa,

I’ll build a solution where you, if there are HomeyScript cards in it, can read the code(s) before creating the flow script, so you can **choose to not** override it with dummies.

(not right now tho) 😉

---

<div class="post-metadata">

**Author:** ![HuisCHovens](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/huischovens/32/16973_2.png) [@HuisCHovens](https://community.homey.app/u/HuisCHovens)\
**Post date:** [September 22, 2022, 12:14pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/674 "2022-09-22T12:14:06Z")

</div>

Okay thanks for the explanation. It’s easier on the computer i will try again in evening.  
Android is not always easy with this kind of program. 😉  
.

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 22, 2022, 12:37pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/675 "2022-09-22T12:37:12Z")

</div>

# [Device Capabilities 2.6.19](https://homey.app/nl-nl/app/nl.qluster-it.DeviceCapabilities/Device-Capabilities/) is Live!

With Templates, Import and Export for [The Flow Exchange(r) - Exchange Your Flows with Others!](https://community.homey.app/t/the-flow-exchange-r-exchange-your-flows-with-others/68981/3)

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/0/7/07bec281fac22f0da3520d11fbc79cc6d0460253.png)

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

Also Templates, Import and Export for [Advanced Virtual Device - Share Your Device!](https://community.homey.app/t/advanced-virtual-device-share-your-device/68676) (optional includes flows):

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

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/4/2/42525822ea6cf976cca0c65e9a4480f94f53e477.png)

## Start share your AVDs and Flows!

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 22, 2022, 1:51pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/676 "2022-09-22T13:51:00Z")

</div>

**New, also in live:**  
In The Flow Exchanger (and AVD Export), when you export, there will appear a new button:

When you press the Goto Topic button, there will be a pre-typed message in your clipboard, and you will be send to the bottom of the topic-site, so scroll down a bit and there is your reply button.

Press it, paste your clipboard, alter the header, description and picture and you’re readyto: Post that Flow!

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

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

---

<div class="post-metadata">

**Author:** ![RogerSt](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rogerst/32/12432_2.png) [@RogerSt](https://community.homey.app/u/RogerSt)\
**Post date:** [September 23, 2022, 9:29am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/677 "2022-09-23T09:29:54Z")

</div>

I tried creating a adc-VD of type wall socket. I expected this to add the on/off capabilities. Is my line of thought correct, or why does this not happen?

Like a wall plug device, I would like to switch the device on/off (so when in off state, the device is greyed out in the UI).

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 23, 2022, 10:54am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/678 "2022-09-23T10:54:44Z")

</div>

You need to add a button: on off, and create flow cards.  
I am at home in about 30 minutes, ill create a AVD for you!

---

<div class="post-metadata">

**Author:** ![RogerSt](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rogerst/32/12432_2.png) [@RogerSt](https://community.homey.app/u/RogerSt)\
**Post date:** [September 23, 2022, 11:38am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/679 "2022-09-23T11:38:10Z")

</div>

Thanks for the offer Arie, but I now have sufficient info I think.

Really generous though!

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 23, 2022, 11:45am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/680 "2022-09-23T11:45:45Z")

</div>

Okay Roger 😉

Still, since i was allready done when reading this, i’ve posted the AVD (including the flows) on [Share Your Device](https://community.homey.app/t/advanced-virtual-device-share-your-device/68676/14).

You can select it while creating a new AVD:  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/3/e/3e172ee36f6310c120562effb545eb1839581155.png)

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/e/9/e9f730baa40e2c0358bb22caf9b78abd47556eff.png)

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 23, 2022, 12:07pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/681 "2022-09-23T12:07:13Z")

</div>

Known bug: I am having some issues creating a device from templates, while creating and then reading templates works fine.

In debug it works, when i install normal, it doesn’t always work.

Working on it.

## EDIT

Resolved in 2.6.31, in test now (waiting for the review).

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 23, 2022, 12:34pm UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/682 "2022-09-23T12:34:00Z")

</div>

Hey Roger, and other people.

I just created one more AVD Template [OnOff and Dim AVD with Default Flowcards (with Flow)](https://community.homey.app/t/advanced-virtual-device-share-your-device/68676/15).

This to explain how Homey handles Devices classes and capabilities.

Device Class doesn’t create anything in Homey, as far as i know.  
It only **reacts**.

Capabilities (what i call Fields) are what creates Homey default flowcards.  
For instance, when a Device, no matter the class, has an OnOff capability (only one real OnOff can exists), you will get several flowcards: Devices Turned On, Device Turned Off, Turn On Device, Toggle Device on/off and Turn Off Device.  
All the cards on the next image, are created because the AVD has a OnOff(button)+create-flowcards and a Dim(number)+create-flowcards.  
 ![afbeelding](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/7/6/76e63c8122eaf8d6f2900498967b5d8c7baf67d6.png)

This is why there is a Create FlowCards property when you select a default ShowAs type.

Back to Device class.  
The example AVD can be turned On Off / dimmed through the flowcards in the image above.  
But if you use Default Zone/Class flowcards, it would only react if you have the same Class.  
Also other apps, like Group search for classes (sometimes).  
Thats why i included the Class option.

Lets say you use the AVD as “real light control”, then you might want it to react to the default flowcard: Turn [[device-class]] On/Off.  
If you put this on Turn All Lights On, the AVD is only gonna react if the class is Light (and it needs the OnOff button with flowcards).  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/3/8308f3303a4d045de1f864cfb4ff3ffb90bcd80a.png)

I hope this clarifies things?

---

<div class="post-metadata">

**Author:** ![RogerSt](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rogerst/32/12432_2.png) [@RogerSt](https://community.homey.app/u/RogerSt)\
**Post date:** [September 24, 2022, 7:45am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/683 "2022-09-24T07:45:26Z")

</div>

Hi,  
I just got my device working nicely.  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/3/7/3797cb0a81e845a65d31ec26a212b0c41a2f4637.png)

The device is greyed out when not charging, the charging power and energy are neatly updated when charging is in progress.

Now I wanted to add a charging duration, and there are 2 struggles I encountered.

- I added a text field and called it Duration.
- I tried choosing a clock as icon for this field, but cannot seem to find the right icon for that. I have seen it, but I just cannot select the right one in one go - and a trial and error is time consuming.
- I cannot get the duration to work

**Struggle/Question 1:** could someone please post a complete overview of the default icons in the app?

**Struggle/Question 2:** I try to calculate the duration since charging started. I can foresee several ways to do it but I’m sure there’s an easier way:

- use a timer/stopwatch/chronograph… app but I cannot seem to find a way to extract the elapsed time (there are no flow cards for this it seems)
- use javascript - but I’m not very proficient at this it seems. Taking two snapshots and calculating the time elapsed is a bit of an over-ask for me.

What would be a simple way - and do you have an example somewhere?

Thanks for considering to spend time on my request.

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 24, 2022, 8:13am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/684 "2022-09-24T08:13:03Z")

</div>

> [@RogerSt](#):
>
> could someone please post a complete overview of the default icons in the app?

You can see al Default icons in the App Settings, where you can change the Custom Icons.  
Also, you can give the customicons a name in App Settings by double-clicking in the textarea with the Custom\_\*\* name in it. A field will appear and you can alter the custom name to what you want.  
After that, the custom icon list in the Device Settings will show your own custom name.

> [@RogerSt](#):
>
> I try to calculate the duration since charging started. I can foresee several ways to do it but I’m sure there’s an easier way:

I was allready thinking about to more DC Flowcards:

- One to ask for the duration (hours, minutes, seconds) that an Insight was changed.
- The average of a Insights in the last \*\*\*\*

I think card one would solve your question 2?

---

<div class="post-metadata">

**Author:** ![Dennis\_van\_Dinter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/dennis_van_dinter/32/28180_2.png) [@Dennis\_van\_Dinter](https://community.homey.app/u/Dennis_van_Dinter)\
**Post date:** [September 24, 2022, 10:16am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/685 "2022-09-24T10:16:34Z")

</div>

Aaaah H.O.O.P! That was/is a great app.

---

<div class="post-metadata">

**Author:** ![RogerSt](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rogerst/32/12432_2.png) [@RogerSt](https://community.homey.app/u/RogerSt)\
**Post date:** [September 24, 2022, 11:05am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/686 "2022-09-24T11:05:51Z")

</div>

Hi Arie,

Yes, excellent:  
Question 1 solved in App Settings icon overview (which displays an error btw. when opening app settings: _Error: Cannot read properties of undefined (reading ‘flow’)_ - but it works nonetheless)

Question 2 - yes it would be great if there were a flow card duration-since-last-change for a property. Thanks for considering.

Roger

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [September 24, 2022, 11:30am UTC](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287/687 "2022-09-24T11:30:14Z")

</div>

> [@RogerSt](#):
>
> _Error: Cannot read properties of undefined (reading ‘flow’)_ - but it works nonetheless)

@RogerSt Please send me a app diagnostic after you recieved that error, that would help me resolve it.

Wait, are you running Test or Live?  
Live has a bug yeah, solved in test (with a lott of other improvements and bugfixes).

[Previous page](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287.md?page=33)

[Next page](https://community.homey.app/t/app-pro-device-capabilities-enhance-the-capabilities-of-devices/43287.md?page=35)
