[Resolved] Piston with Global Variable in Trigger error


I have set up a few global variables that I use to store and edit time. One example is our Weekday Wakeup time (which can be fluid at times).

I use this variable in quite a few pistons. In many cases I use it to trigger a Piston.

This way I don’t have to open each piston edit the time and save it to reflect the time change

I also use the same Global Variable within many pistons as part of conditions, etc.

The main downside I have found is when I edit/save the global variable, the time change is not reflected immediately in each of the respective pistons. So, I came up with what I thought was a way to force the change.

The issue I am getting is the following like error in all the pistons I am using the update on. After the two above pistons executed.

Can someone please explain what is causing this error? Could you also suggest changes or another method to make the updating of each piston more dynamic?


I don’t know about that error, but this is essentially the same problem you get with sunrise and sunset times and with daylight savings changes - the piston schedules its next execution whenever it runs. The solution would be the same - have each piston wake up in the early morning and do nothing. That will update all the timers to the latest available values. By early morning I suggest having them run a little before the earliest likely WakeUp time.


I don’t know ab out your error but relative to the update, I found that if I use ‘if time happens daily at’ instead of the ‘every day’ then the execution time automatically gets updated when the global variable changes. (At least on ST, don’t know about HE).


Is also try a few seconds of timer between pause/resume task.


@eibyer, not sure I am clear on your suggestion.
I have broken the pistons into two different triggers.
I am waiting 5 minutes between:
The pause starts at 12:01 AM
The resume starts at 12:05 AM

These two pistons were one at one point with 25 seconds wait between Pause and Resume. When the error started happening, I try more seconds, with no luck, then I finally just separated them. Still no luck.


@guxdude, thanks for the suggestion. I am using ST.
Is this what you’re suggesting I do?

FYI I selected 1 minute to instead of 1 minute after by mistake.


Sorry, I meant…

Pause piston…
Wait 5 secs
Pause piston…


Sorry, I was out of town for a few days.

Yes, this has worked for me. The piston always wakes up whenever the global variable changes.


Thanks @guxdude, works perfectly. Boy, do I have lot of pistons to change/update.