Did you know that you can enjoy many members-only features simply by quickly registering (no CAPTCHA!)?
Registering gives you access to our giveaways, forum features, increased search performance, access to our Download Library, create your own blog & gallery, and more!
Once you have registered, stop by in 'Hello World', and introduce yourself.
will this event work?
Posted 29 March 2018 - 11:30 AM
Posted 30 March 2018 - 01:01 PM
I'm trying to keep the notification from occurring in a short time frame 5:30-6:20am, but work all other timesWHEN DRIVEWAY SENSOR NOT READYAND IF TIME IS GREATER THAN 12:01 AMAND IF TIME IS LESS THAN 5:30 AMORAND IF TIME IS GREATER THAN 6:20 AMTHEN SHOW CAR ON DRIVEWAY WITH BEEPI also think I need something to remove the message from the console.
Should work. There are a few ways to do this. You didn't give your model number, but you probably have three timers you can use as well. You set the start time and the end time, and the timers turn off and on. You could use one to control is your message is displayed or not.
As you get more things going, you will find your code is more readable and easier to maintain using flags instead of using times for each actions. For example, you could create a flag called "DriveMon" or something like that, and have the flag turn on and off at the appropriate time every day. Then you can just test for the flag in your action. It may not make your code any shorter, especially if you just test for this time condition once, but it makes it easier to debug when you have lots going on.
Posted 31 March 2018 - 11:53 PM
I agree with Ano. I would use a flag.
Timed 6:20 AM MTWTFSS
Then Driveway Sensor Flag on
Timed 5:30 AM MTWTFSS
Then Driveway Sensor Flag off
When Driveway Sensor Zone NOT READY
And if Driveway Sensor Flag on
Then Show Car on Driveway with Beep
Posted 01 April 2018 - 10:45 PM
Thank you for your replies. I have not used flags much but see how they can be very useful. I have reworked my code in order to turn a driveway flag on at 12am, then turn it off for one hour at 5:30 am. Then have the message and beep occur if the the sensor is not ready and the flag is on.
the purpose is to keep the message and beep from occurring when my son leaves for work between 5:45 and 6:15 am. I'll find out tonight if it works.
Posted 02 April 2018 - 09:31 AM
It worked great!
I have my system set up to beep when a perimeter door is opened. Is there any way to have that bypassed during this same one hour period? The only way I can think of doing it would be to turn off the HAI notification setting and simply write a line of code for each zone that is on a perimeter door. Then use a similar code as the driveway sensor.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users