[Hai-users] input debounce or swinger control

Dan@Starwolf Systems dan at starwolfsystems.com
Sat Jan 28 12:04:21 CST 2012


On 1/28/2012 9:32 AM, John Purnell wrote:
> Hi Listers,
>
> I'm looking for an easy way to start an action based on an input but 
> only after input has been activated for say 5 seconds. In all my 
> security panels I can program an input time for the system to ignore 
> the input until that time has expired. I think they call a bouncy 
> input a "swinger", (hey... big spender...)
>
> I have a hot tub with a separate pushbutton for the tub light. I wired 
> everything up and paralleled a relay off that circuit and now when I 
> push the light on I raise the tub temp by 1F. Works great, no getting 
> out of the tub to walk into house to keypad to raise temp just for a 
> few minutes when you want that little extra oomph. (you know before 
> you've used up all your Tanqueray and tonic you took with you into the 
> tub...)
>
> But, in the ever-constant search for perfection, I'd like to delay 
> this temp raise by a few seconds so that when I really want the 
> super-jets on but not the temp raise, and I accidentally press the 
> wrong push-button (remember, I'm on T&T by now...) and instead of the 
> super-jets, I hit the light, then quickly turn light off and find 
> super-jet button, I don't want system to react. I can wait 5 seconds 
> to make sure the user has made the correct choice.
>
> In my access control panels at work I can just program in a swinger 
> delay of 5 sec, so the system won't react until the input has been on 
> for that duration.
>
> is there a simple way programmatically to do this in OP2? Or would I 
> have to go through the whole scenario of watching for the input to 
> change, then set a delay timer on a flag and wait for the delay to 
> time-out then if input still high do the maneuver...yaddayadda...
>
> I just wonder if I'm missing a simpler way to do this.
>
> I would like to use this same delay on my driveway sensor which really 
> bounces when cars come through, and my front porch IR beam, which also 
> will pop on/off very quickly as your leg breaks beam, then clears, 
> then your next leg...etc, so my alerts kinda go crazy. I was hoping to 
> avoid an external timer circuit and just do with HAI programming.
>
> Thanks for any ideas.
>
> John.
> Wisconsin.
> jpurnell.com
>
>
> _______________________________________________
> HAI-users mailing list
> HAI-users at tssi.com
> http://romaine.tssi.com/mailman/listinfo/hai-users
>
I use a simple timer to do much of that

When <event> start timer
When <event = timer expires> do <action>

Typical example from one of my installations:

16.    WHEN ARM AWAY
         AND IF DARK
             THEN Laundry Room Light ON
             THEN Exterior Front Door Light ON
             THEN Exterior Front Patio ON
             THEN Garage Overhead Lights ON
             THEN Detached Garage Front Lights ON
             THEN FL - Exit Light Delay Timer ON FOR 5 MINUTES
17.    WHEN FL - Exit Light Delay Timer OFF
             THEN ALL UNITS OFF



More information about the HAI-users mailing list