X10 Community Forum

🖥️ActiveHome Pro => Plug-ins => Smart Macros => Topic started by: bsmurph on February 07, 2010, 11:15:14 PM

Title: One Shot Macro
Post by: bsmurph on February 07, 2010, 11:15:14 PM
How do you make a one shot Macro????

P1 Motion trigger B4
Kitchen lights on 30%
delay 30 sec..
Brighten 15%
delay 30 sec.
Brighten 15%
Rub my eyes and say good morning

Works great until P1 is triggered again then it starts all over again!!!!?
How can I make it only trigger one time?

Thanks Murph! B:(
Title: Re: One Shot Macro
Post by: dbemowsk on February 07, 2010, 11:38:01 PM
How do you make a one shot Macro????

P1 Motion trigger B4
Kitchen lights on 30%
delay 30 sec..
Brighten 15%
delay 30 sec.
Brighten 15%
Rub my eyes and say good morning

Works great until P1 is triggered again then it starts all over again!!!!?
How can I make it only trigger one time?

Thanks Murph! B:(

Try using an if-then condition with a flag

if flag (whatever flag # you choose, 1 - 16) off and P1 Motion trigger B4
    set flag (whatever flag # you choose) on
    Kitchen lights on 30%
    delay 30 sec..
    Brighten 15%
    delay 30 sec.
    Brighten 15%

At a later time, set flag (whatever flag # you choose) off.  Using the flag lets you choose when the macro will run based on the status of the flag.

Dan B.
Title: Re: One Shot Macro
Post by: bsmurph on February 08, 2010, 06:48:27 PM
I tried to do it with another Marco that time out in 1hr and reset the flag but it seemed like it only timed for ten minutes and restarted. Maybe I will have one reset the flag only when the B4 switch is turned OFF.... 
Title: Re: One Shot Macro
Post by: dbemowsk on February 08, 2010, 07:11:08 PM
If you are running the macro with a timer, just set another timer that will run a second macro to reset the flag one hour after running the one shot macro.  Unless the B4 switch is a transmitting switch, AHP may not recognize it if it is manually turned off.

Dan B.