Page 1 of 1

Start and stop for a while

Posted: 12 Feb 2014 12:30
by Bipenett
Hello wonderful people! I need help to perform the following flow:

1 he if screen is turned off
2) wait 5 minutes
3) lock screen
4) (I would like to be sure that Automagic would not try to execute the whole flow again when after step 3 is executed.

Could anybody help me, please?

Re: Start and stop for a while

Posted: 24 Apr 2014 18:23
by choo
Still no takers? I'm interested too. At least for some pointers on how to execute this.

Re: Start and stop for a while

Posted: 25 Apr 2014 06:13
by Martin
Hi,

You could disable the flow when you don't want to execute the flow for a period of time:
Flow 1
-trigger Display State: Off
-action Set Flow State: Disable Flow 1 (or by using a variable Set Flow State: Disable {flow_name})
-action Sleep: 3m
-more actions ...

you could enable the flow again at a later time (or using another flow):
-action Sleep: 5m
-action Set Flow State: Enable Flow X

You could also stop a flow when the display is turned on again:
Flow 1
-trigger Display State: Off
-action Sleep: 3m
-more actions ...

Flow 2
-trigger Display State: On
-action Stop Flows: Flow 1

Regards,
Martin

Re: Start and stop for a while

Posted: 25 Apr 2014 08:42
by choo
Thanks Martin. This helped me, partially, setting up my flows with the display on-off for which I've just made a separate posting.