You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
That's quite the complex script you have :D The card doesn't have very much insight into the entire script; it only is able to see the last action taken by examining the attributes of the script entity. So you're right, it's only going to use the time in the first delay instance.
I don't think there's any other way around this besides further complicating your setup and adding two timer entities. I would create a "Sprinkler status 15m" timer and "Sprinkler status 30m" timer. At the beginning of your script, you would start the timer, and assuming all goes well the timer should stop by the time the script finishes.
Then, you can configure the card with the timer. To keep more-info pointing to the correct entity, you can use the more_info service in the browser mod addon.
So, I have a sprinkler system that always turns off after 10mins
I created 2 buttons that will turn the sprinklers on for both 15 and 30mins
15mins button code :
script.irrigation_on_15mins code :
30mins button code
script.irrigation_on_30mins code :
The problem is that the timer only takes the first "delay" instance into account and shows a 10min countdown for both buttons.
Using duration fixed : 00:15:00 and fixed : 00:30:00 does not work, because then both buttons start to countdown even when I only clicked on 1
What solution can you provide, please ?
The text was updated successfully, but these errors were encountered: