[APP][Pro] Virtual Devices - Virtual Devices to simulate 1 or more real devices

Heeft zich vanzelf opgelost! :slight_smile:

1 Like

Great!

Live 1.0.4

Improved: Target/measure temperature adjustments:

  • Min (-100 min, 50 max, 0.1 step)
  • Max (0 min, 200 max, 0.1 step)
  • Step (0 min, 5 max, 0.1 step)
  • Decimals (0 min, 5 max, 0.1 step)
3 Likes

Need some help here :neutral_face:

I use the App “Virtual device” and have made two devices that now show my Gas a Electricity consumption:

Schermafbeelding 2022-11-17 om 13.00.41

This is the advanced flow that updates the two devices:

I also have the App “Advanced Capabilities” installed. That would possible allow me to delete the first App and use this more sophisticated (and complex) App to update my two devices. I am stuck on how to do this. Any suggestions?

Thanks!

I think you mean Device Capabilities with the Advanced Virtual Devices. :wink:

Hang on one sec.

1 Like

Here you go. 2 AVDs.
image

image
image

image

Create a new AVD and paste this TEF (it’s without flows).

[tef:AVD:"H4sIAAAAAAACA21UXY+iSBT9KxNe7Q6fCnSyD4KAgFqggsBm0ymhxAIEGgoBJ/PfF3d20v3Q9XKTe+4556bqpH5SCbrjGJlxVVJv1FpozeXvoy559nA80eft8iHbi8ExhpWtfQTmoV5qp36rqZGSXgfPQN3g7fqFy2l6yxksTXupaPAhdM2SQfQg1A1bdRhIgTT3W+Zhk4YHjHi8I9k/+8kM2Kcb8aS5Wa1anz458j3vGWilMK9Bq6czcyWq9ccAZzLjH4O+CXmzUu+qXQhJvL6sSSZ2PjBjrF3zi5Qu6jDgFBrngU+rceaEUrSIOoYW7U2SBNvwzBkDl/SHXDJW4UPiAX8duNDZ17nVgHsQpos1n4ALXUhRV4rxsUWjkliaK/sWytnUZzwd23ddhh4RglO0VieY62Y2TLd3EG16aVzxZOPtH8Qv6pncyQBsTgivdpo++Lm7JDiKO2u1UAd9FUdjHulgrkXNCLTEBaaxV7TaG4RHlCx1Yu/Nu51I83vMjRY23fBEXxc9ZqxHeFBdtzUi+ZHZyPIveTN6t21xa9YHZz0rncyV4nEDPE5ajI4cCpl5cLZzQwyzg2lYmwvYh6zWbOc5rCKQsREeLWaTe3qkjW2f5WiIOF3IeF3gHfMj3g5ZCJResGoRGOcbPz0r2rFK8nD2Fp6d2uMm28vdgWH1ZfDRtYchZZx0BpW4xsbWVELSQldyIFKjIBvc4KKea4h1egYqvj8q6tLNV1Pe/qJeqLhrSXV7ZrGl3n7+eqGqBqe4hIWZTOGML4wMJRa9IlZCr8IiQa9QjsVXAYmiJMGLxAnzSaRFhOAyfSpQqERNOr7fYdGh96csgSWh3squKF6osrudUQMuRzQQHaMimSjMZ3v3X/0DsJ+AUlUFguU3FKUjpPoOUOENNfAbYIPbr95xMVWqIlfUUH+G2N1EnrormLawSKpP4IBq2ECCVFjDMy4wwWiiX2DRos+Za9Uvn6I3RFDzXlf9V2m1QRNfL6pehc1zB9J0aLr335/C/8Y/Xn988YbU29///PoX1+ddLDgEAAA=":/tef]

Then create another AVD and paste this TEF, and at the end, create the flow (follow the steps and complete the script in the Playground, you’ll see).

[tef:AVD,FLOWS:"H4sIAAAAAAACA7VWW4+qTBb9Kx0fxzbcL3YyD4KIyE1ERJxMToqiQO7IRYRO//fB7u+b7knOw3kZSSyoXWvt2mvv2vA+C9A9hkiBZTF7m23pRll9/cQVSZxwl4ZGP/IbtGXv6+qwEd0bL2QKFtTzyODdywjNRsnXj/0548cm4Q6eIHei2Q2BTeiDRRjEMsR4j0r4JYUxNHaWmOoiiPD8MGkYFhy8U8O8yDhE1dw8HLkz0AyavFMjiyBeV8mGLOZcd2eXrYa0G8SaEjR4ZcW2WgurTN+JW9JLNn4HL8AbCKHM3GS0z6mqFoc4BfcGtb2omEA+DNUpu9bb/G6Tmoyutc7War12vXYLPTLfg7K3UJmBDPGnwPRCmXXpgz7Ou2Jsm/WOmLOkrY92xAN3zuyS+lGpranUjtBhKY/bzVxfac2J1dTCFRxrdbA7DKMdspBFV2G2hNVzh3UWbhzrBKuUOsZOv7mOiKkil0+1o3vxBc+roZ6RQWiSducFtwf0UlPrRPkopMo8Z6gdFdpnST5b/k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d+vWkbUHRzt6KLsteZ0WX+6g2wyN6tJsYZcEEwb+njc/xbwPxbRDKMkOg+A1E6Nq2/J1BBDmqwW8MWtz89A2zaZyV7RXVs78XEcYEnmZPqPbrLk6/DTaqQA1aJIIK+HEWtzGa4CHIGvS95lr2qydpjlpU/4pA840XazShN1nZi6B+7qCtOzSp/vX6+8vty+Llh+fgqSoM8SXgCbRABI8WNBugBVhCbkEjjuN5EPIkzTzXFV/wqXM0IAvKZ4L/G93k5o/y+U3zYxc/aCYeMHv71/ssnuY4CJgwROGCwuFyQYc+vfAhSS0YnmVASPGAQdQz/Gmp9AB5laEXGTSfykzT6EuAT/r3GR9QEFBTfEuaCxc0weMLPvTRRA1oEHAhyxOfQT5mb+yUuWEqEXIay4n7WuZoePtS8e2PxHr93P49rttuUuoT+Guq41/oUdWoaeLpQ+R1NhXuDMD26wE8fYfPynnexM/z8VdWnwF+pe6H8AFqYB1Xn+C32VdpvxDPLPxw8TZ7f395IfFJbOLj40tbiuNYAIIFYkh8QUMeLHwODxaAJQI+8GkekOz/qkDSv1PhD8/u/0OFn9X7xyoQ+Ms/pr9PFT4+/v3xH/XkjJoUCgAA":/tef]

You can alter the AVD device icons in the App Settings (restart the DC App after change to take effect).
You can change you icons for capabilities also of you want, but that would mean you need to change a few things. Let me know if you want that.

1 Like

Thanks @Arie_J_Godschalk!

If you put it like this, you can have a custom icon in the sensor tab aswell:
image

image

Or round the decimals to 0 or not.
(dont forget to set the field as Status Indicator in the Homey App.)

I just recently saw this Device Capabilities app and I must say I love it so far but it also seems a little complicated. I have been playing around with it and the first steps are made but also running into some difficulties.

I have created multiple “Control 2 dimmable lights as one” devices for rooms with only two lights and they are all working just fine. It seems to work faster than when I used those lights in the groups app.

I have also rooms with more than two lights so I added for one of those rooms another “Control 2 dimmable lights as one” device and added the other lights manually. The manually added lights are not visible in the flow that are created with this device and when I try to adjust the flows with the manually added lights, options are not available.

Is there a way to get the code for all manually added lights as well to use in the Homey Api playground?
Or if this is not possible, how do I add those manually added lights to the flow with the options that are available for the automatically added lights?

Thanks

Hey @Heula,

Since this question has nothing to do with the Virtual Device App, and is all about the Device Capabilitities and more specific the Advanced Virtual Device, do you mind reposting your question here [APP][Pro] Advanced Virtual Device (Device Capabilities App) with Unique Text Status Indicator - Apps - Homey Community Forum so we can continue there, and other people can make use of it in the right topic?

Thanks in advance!

in the meanwhile, i’ll work on the answer :wink:

1 Like

Still need some help Arie…

I got the AVD’s created a flow to put values in the AVD’s:
Schermafbeelding 2022-11-19 om 15.02.40

What I don’t get is the flow. Does the import create a flow too? I ran the script, but don’t see a flow anywhere.

Or, put differently, what does running the script do?

Create the flow/flows in the Root of your flow-folders.

The edited messages, there are some timeouts to wait for the AVD to be created, before i can create the fields.
But the default timeout is 10 seconds, so i guess it timeout sometimes.
I will have a look at it next week, ill create a waiting screen (“indefinite” time to wait till homey creates the AVD).
Can you create a ticket for it?

Edit, i just see its the VD topic, let’s continue at [APP][Pro] Advanced Virtual Device (Device Capabilities App) with Unique Text Status Indicator - Apps - Homey Community Forum.

1 Like

What is the ‘trick’ to select all the code to import?

If I put my cursor in the field ald use ‘copy all’ not all code is selected.

Thanks!

Click three times.
Double click selects the whole word/part.
Three clicks, selects the whole codeblock.

1 Like

Hi All,
Recently i created a VD - Sensor with Motion capability, I tried created a flow to inject the result from a Door sensor but it isn’t working, see below test error - Invalid capability: [Null]
What does it mean ?

Hi,
In the first top field,
you’ll have to enter the capability, alarm_motion, do not pick a tag.
In the second field,
the allowed values are true/false, or a boolean variable/tag like your [Motion alarm]
But there’s a bug with the latter when you use the mobile flow editor (see below the screenshot)

@Arie_J_Godschalk When I use a bool variable instead of entering ‘false’, it errors.
It seems to read true / false as words (string) instead of boolean.

Nevermind, This error below does not occur in the web app flow editor
It is a Homey issue, not your app

1 Like

Additional space after the tag? It looks like the error says "false " not “false”.

1 Like

Ah, sharp! That would be indeed the “additional added trailing space” bug in variables, in the mobile app flow editor…

Check, in the web app flow editor this works without errors:

Only after saving the flow in the web app, it works in the mobile app:

.
I just created a ticket @ Athom for this bug.

“alarm_motion false” is working for me, thank you!

2 Likes

@Arie_J_Godschalk

Any luck to request an attribute on the sensor device that says “amount” or something? I want to have a virtual device to display a cost since midnight, e.g. 5 without any unit sign on the icon, or even better to be able to choose currency from a lot of countries