Announcement

Collapse
No announcement yet.

Security Event Not Firing

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Security Event Not Firing

    I created a new event that is not firing. I have a variable called Away, that is manually set to On. The event:
    If device has its value set to On, and the time is after 9:30 pm (Security with a +/- 30 min), the turn off some devices.

    I have the variable set to On.
    Attached Files

    #2
    I think this will work if you switch trigger and condition.
    That is, if the time is 9:30 PM and the away device has a value of on, then. . .

    If you want to be sure the event never fires before 9:30, then choose a time after that equal to the security offset.
    Mike____________________________________________________________ __________________
    HS3 Pro Edition 3.0.0.548, NUC i3

    HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti

    Comment


      #3
      +1 on what Uncle Michael said. The only thing I might add that you can check to see that you have done the following. See pic with the arrows.
      Attached Files

      Comment


        #4
        The event in the OP will run, as long as the switch is set after 9:30PM and before midnight. Days always begin and end at midnight so "After 9:30PM" really means "After 9:30PM but before Midnight. Similarly "Before 9:30PM" really means "After midnight but before 9:30PM". Note that the trigger in the event is "This device had its value set to", meaning it does not need to change status. If it is "On" and it is set to "On" the trigger will be true. This can be a problem with plug-ins that might "set" the values of a device without actually changing them.

        The security offset needs a little further explanation. The security offset will only apply to a Trigger and not to a Condition. The security offset selected in the event would only randomize the trigger if it was for a time. The security setting will have no effect on the event in the first post.

        From reading the post it sounds like you want the lights to turn off at some random time around 9:30PM as long as you are away. If that is the case then Uncle Michael's advice would be correct. The event would be

        IF The time is 9:30PM
        AND IF Main Mode Away Mode is equal to On
        Then Set devices

        In this case the Security randomization will affect the trigger +/- the number of minutes in setup as shown by cowinger. If security Offset is enabled and 30 minutes is the value, the event will trigger at some random time between 9:00PM and 10:00PM
        HS4 Pro, 4.2.19.16 Windows 10 pro, Supermicro LP Xeon

        Comment


          #5
          Thank you for fix and explanation. It never occurred to me there was a trigger and condition. I assumed (my mistake) it was like most code and all just conditions. Makes some sense now, but never would have guessed it.

          Thanks again

          Comment


            #6
            The Trigger vs Condition is what makes HS confusing to many users, but it is also what gives HS some strength and efficiency. If you want continuous Condition evaluation, there is always a recurring Trigger available. For most Events, the key is to pick the most appropriate Trigger. That Trigger should be a time or single action that occurs, then the Conditions can be evaluated. Until the Trigger is true, the rest of the event is not even evaluated or acted upon - conserving system resources.
            HS4 Pro, 4.2.19.16 Windows 10 pro, Supermicro LP Xeon

            Comment


              #7
              Originally posted by rprade View Post
              The security offset will only apply to a Trigger and not to a Condition.
              Randy,
              I didn't realize that. I thought it would be treated as a time condition where the time was determined for each occurrence using the security offset algorithm, but I've never used it that way or tested it. Knowing how thorough you are, can I assume you have?
              Mike____________________________________________________________ __________________
              HS3 Pro Edition 3.0.0.548, NUC i3

              HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti

              Comment


                #8
                Originally posted by Uncle Michael View Post
                Randy,
                I didn't realize that. I thought it would be treated as a time condition where the time was determined for each occurrence using the security offset algorithm, but I've never used it that way or tested it. Knowing how thorough you are, can I assume you have?
                I have tested it. The description in the event "Security (Randomize Time Triggers)" is fairly implicit as are the help files:

                Click image for larger version

Name:	Capture.PNG
Views:	1
Size:	24.1 KB
ID:	1190985
                HS4 Pro, 4.2.19.16 Windows 10 pro, Supermicro LP Xeon

                Comment


                  #9
                  Originally posted by rprade View Post
                  I have tested it. The description in the event "Security (Randomize Time Triggers)" is fairly implicit as are the help files:
                  I agree. The description doesn't seem to leave much room for the time to be a condition. Just to check, I've created a test event with a time condition, and checked the security option. What I see (it hasn't run yet) is that the time condition, which was entered as 2:00 PM shows in the event as 2:17 PM. It will be interesting to check it tomorrow and see if the time has changed.
                  Mike____________________________________________________________ __________________
                  HS3 Pro Edition 3.0.0.548, NUC i3

                  HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti

                  Comment


                    #10
                    Originally posted by Uncle Michael View Post
                    I agree. The description doesn't seem to leave much room for the time to be a condition. Just to check, I've created a test event with a time condition, and checked the security option. What I see (it hasn't run yet) is that the time condition, which was entered as 2:00 PM shows in the event as 2:17 PM. It will be interesting to check it tomorrow and see if the time has changed.
                    You are correct. This is different than the behavior I confirmed in 2014 when I was testing things for the Event Clinic posts. It is obvious that features within HS are a moving target. At that time the security offset did not randomize conditions. I just built a test event to demonstrate. I will keep an eye on it. The first three were set at 2:00, 3:00 and 4:00. When I selected Security they all changed to + 17 minutes. Then I added 5:00 and it added 28 minutes. I will see what happens with the event over time.

                    Click image for larger version

Name:	Capture1.PNG
Views:	1
Size:	72.8 KB
ID:	1190986
                    HS4 Pro, 4.2.19.16 Windows 10 pro, Supermicro LP Xeon

                    Comment


                      #11
                      Based on my simple test, it appears that if you select the security option on an event with a time condition the actual time condition is randomized according to the security offset in force at the time. The time condition appears to be changed to a different offset once a day.
                      Mike____________________________________________________________ __________________
                      HS3 Pro Edition 3.0.0.548, NUC i3

                      HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti

                      Comment

                      Working...
                      X