X10 Community Forum

🖥️ActiveHome Pro => Plug-ins => Smart Macros => Topic started by: donutlou on November 14, 2006, 04:37:37 PM

Title: Trying to Understand Macros and Flags
Post by: donutlou on November 14, 2006, 04:37:37 PM
sooo,
can someone configure a scenario that would accomplish this action so i can better understand .
i have a motion sensor in my front hall that i want to trigger a macro to turn a light on and dim it when i come home, but as to only turn the light on once so when i trigger the motion sensor as im walking around my house it doesnt sequence through the absolute 100 and the dim setting i want. i know this can be settled using flags that would tell ahp that it has already been tripped and not to re-run the macro, But i have no idea how to set meaning to flags or incorporate them into the actions.  so when i come home at 4pm my lights will turn on and dim to a certain level, but as i walk around the same lights wont be triggered anymore.
if you can be very basic i would appreciate it.
thanks
Title: Re: Trying to Understand Macros and Flags
Post by: Puck on November 14, 2006, 07:54:39 PM
A great man once said, "a picture is worth a 1000 words" .... (I think it was Tuicemen last Sunday...)

If you have any questions, let us know.

(http://www.geocities.com/puckx10/macros/light_flag/lightON.jpg)
Title: Re: Trying to Understand Macros and Flags
Post by: Puck on November 14, 2006, 07:59:37 PM
Oops... almost forgot the Macro Off.

I use the Motion Sensor's Timer to turn the light off.

(http://www.geocities.com/puckx10/macros/light_flag/lightOFF.jpg)
Title: Re: Trying to Understand Macros and Flags
Post by: Tuicemen on November 14, 2006, 08:11:58 PM
Quote
A great man once said, "a picture is worth a 1000 words" .... (I think it was Tuicemen last Sunday...)
:-[ :-[ ;)
I was just repeating a very well used phrase! ;) :D ;D
donutlou:
Have you checked out Topic: Having X10 AHP Problems? Please Read This First!  (Read 8719 times) (http://www.x10community.com/forums/index.php?topic=7951.msg49167#msg49167)
There are some very usefull links there including this one Topic: how to use flags  (Read 4083 times)   (http://www.x10community.com/forums/index.php?topic=4590.0) 
 And yes there are pics in the post! ;) :D
Title: Re: Trying to Understand Macros and Flags
Post by: donutlou on November 15, 2006, 12:53:06 AM
hey thanks,
i appreciate it, ill try it out...
Title: Re: Trying to Understand Macros and Flags
Post by: Tuicemen on November 15, 2006, 04:43:17 PM
Puck has supplied simple macros with flags for you to examine and get you started.
Reading the other threads will turn you into a "power macro\flag user/creator"
If you wish to get realy creative! ;) :D ;D
Title: Re: Trying to Understand Macros and Flags
Post by: Vandalized Victim on November 16, 2006, 03:35:49 PM
Hi Puck,

It's a good example. But no offense, I've tried the same effect without the flag. What difference does it make of a flag then? Can you throw us more samples?

Thanks,

VV
Title: Re: Trying to Understand Macros and Flags
Post by: Tuicemen on November 16, 2006, 03:42:40 PM
Pucks examples are just showing how to set/clear flags, unless you look more deeply at the first pic where the flag status is looked at in the condition!
For more info check the flag link I supplied earlier;)
Title: Re: Trying to Understand Macros and Flags
Post by: Puck on November 16, 2006, 03:55:04 PM
When I first started with AHP, every time I retiggered the motion sensor, the light would go back to 100% then dim to the 50% I wanted, this occurred every few seconds... WAF go down.

On the board here I found out about Flags and how to prevent that. WAF return to normal.  ;)

Read the link Tuicemen provided and experiment.  :)
Title: Re: Trying to Understand Macros and Flags
Post by: Tony Olson on December 16, 2006, 05:43:20 PM
All the items and examples in this thread were a great help to me. At night a sensor in my small bathroom turns on a light in my kitchen (and dims it) and a light in another room (for four minutes). I set the flags up as illustrated to prevent the light turning on actions from repeating themselves (during my 4 minute delay), but I couldn't get it to work. My kitchen light would turn on (and dim) and my other light would turn on every time I walked in front of my sensor.

The problem seemed to be my time condition for the macro. Initially I said that this macro would execute between the times of 9:30 p.m. and 4:30 a.m. I ultimately set up two exact macros except the conditional time on one was 9:30 p.m. to 11:59 p.m. and the second macro was 12:00 a.m. - 4:30 a.m.

Everything works fine since then.

Just my 2 cents.

Tony