Simple use case - just want a little countdown for my car payments.
I created a number variable set initially to the number of payments i have left. I thought it would be easy to just have a virtual device tile that would display the number, then if I clicked it, I could recognize the click in a flow and decrement the variable by 1.
No luck so far. I’ve played around with Virtual Devices and Device Capabilities to no luck. Could be missing something but didn’t see a way.
For something so simple I’m struggling lol. Anyone implemented something like this and if so, how?
Do you have the Better Logic Library app as well as Device Capabilities app?
Create an AVD with a basic push button, and a number field that reflects a number variable from BLL. You can then set the Quick Action of the device tile of your AVD to the button. And have a basic Flow WHEN button pressed THEN Decrement number variable. The BLL app has a THEN card to decrement a number variable. And with the number field of your AVD set to Reflect your BLL variable, as long as you have the option in the Device Capabilities app enabled to Reflect BLL variables it will automatically update and display your countdown. You can also set the device tile settings of your AVD to use the number field as the status so your countdown will show up on the tile.
I made this for our dishwasher tabs more or less the way @Drako74 described.
I created the following AVD using the Device Capabilities app, and I use it to track the number of dishwasher tabs we have:
After each dishwashing cycle, 1 dishwasher tab is automatically subtracted. And when there are only 5 dishwasher tabs left, a notification is sent out reminding us that we need to buy more dishwasher tabs.
If you need to change the quantity by hand, for example, if you’ve bought new dishwasher tabs, you can tap the AVD, switch to the correct screen, and change the quantity by pressing the right buttons:
Create the variable in Better Logic Library app’s settings page.
Then add/create a new AVD device with the Device Capabilities app, and in the new device’s Repair setup, add a button, and a number field that is set too Reflect the BLL variable. You can also enable insights at this point so you can have a nice graph over time showing your progress.
Once you’ve saved the device changes, then go to the device settings and change the status to the number variable, and it will show up on the tile.
A very simple and reliable Flow decrements the number by your desired quantity on each press of the button, and when you reach your goal you can perform any actions you like (in the example a message on the Homey Timeline).