Announcement

Collapse
No announcement yet.

Trigger when 1+ device status *ALL* ON or OFF??

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

    Trigger when 1+ device status *ALL* ON or OFF??

    Hello all,

    I want to have a virtual device show if the lights are on/off on *any* light upstairs. Upstairs I have 10+ light switches. If ANY of them are ON, then the virtual device will be ON. If ALL are OFF, then the device is set to OFF.

    I created an event that sets the virtual device to ON *if* any of the switches are turned on. This is the easy part.

    How do I create an event that turns the virtual device OFF if *ALL* of the switches are off? What becomes the trigger?

    The only way I can think to do this is by having it be manually triggered, and having multiple AND IF statements where each device is checked for OFF, and if all match, then it sets the virtual device to OFF. Then I have to create another event (one per device upstairs) where if the device is turned OFF, then it runs this other event that checks for all OFF conditions before setting the virtual device to OFF. This seems like WAY TOO COMPLICATED.

    Any other ideas?

    Marco

    #2
    First event:

    If switch 1 had its value set to off
    Or if switch 2 had its value set to off
    Or if switch 3 had its value set to off
    Then, if conditions are true, run second event

    Second event:

    If this event is manually run
    And if switch 1 is off
    And if switch 2 is off
    And if switch 3 is off
    Then set virtual device to off
    Michael

    Comment


      #3
      Thank you.

      that worked beautifully...and I learned something new!

      Comment


        #4
        Indeed, clever way to process it. I'll file that one away for future use...

        Makes me glad to have Ra2 switches with a scene to do that for me. I just check the LED state for a status scene for the desired devices.

        Comment


          #5
          Hi,

          I followed the instruction, Trying this and the result wasn't as I expected. If I turn both light 1 and 2 on, the virtual device sets to ON. If I turn light 1 OFF and keep Light 2 ON, the virtual device reports its status as OFF. Anyone has same issue ?
          Last edited by NL_Logan; April 10, 2017, 11:23 PM.

          Comment


            #6
            If you post a screen shot of your events someone may be able to see the problem.
            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


              #7
              Do you have the check box ticked: Run Only If Other Event Conditions are TRUE
              Attached Files
              Michael

              Comment


                #8
                Hi guys,

                Thanks for the help. Here is my set up. And the result as well.
                Alright, thanks in advance guys. Really appreciate it !
                Attached Files

                Comment


                  #9
                  Are you able to close the yellow arrow that is pointing down in the first event where you have the THEN?

                  Michael
                  Michael

                  Comment


                    #10
                    Hi Michael, yes I can close it. The problem is the virtual devices will change to "ON" if I turn "On" the light but wont go OFF if I turn OFF the light. So weird. I am thinking this supposes to work. No idea what's going on with this one

                    Comment


                      #11
                      If you trigger the manual event directly from the event page (with the '>' button) does it turn the virtual device off?
                      When you turn the light switches off and the virtual device does not go off, what messages do you see in the HS log?
                      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


                        #12
                        Hi Michael,

                        FRom the Log:
                        Apr-13 2:00:44 PM Event 'Run Event' action execution skipped, the conditions applied were not met: Demo 2017 All Light Off_set 2
                        Apr-13 2:00:44 PM Event Event Trigger "Demo 2017 All Light Off _ set 1"
                        Apr-13 2:00:44 PM Device Control Device: Node 6 Z-Wave Light 1 to Off (0) by/from: CAPI Control Handler

                        My 2nd could not trigger, thats weird.

                        Apr-13 2:23:16 PM Event 'Run Event' action execution skipped, the conditions applied were not met: Demo 2017 All Light Off_set 2
                        Apr-13 2:23:16 PM Event Event Trigger "Demo 2017 All Light Off _ set 1"
                        Apr-13 2:23:16 PM Device Control Device: Node 6 Z-Wave Light 1 to Off (0) by/from: CAPI Control Handler
                        Apr-13 2:23:14 PM Event Event Trigger "Demo Work Home Light_On"
                        Apr-13 2:23:14 PM Device Control Device: Virtual Devices Z-Wave House Light to On (255)
                        Apr-13 2:23:14 PM Event Event Trigger "Demo 2017 Any Light On _ Set To On"
                        Apr-13 2:23:14 PM Device Control Device: Node 6 Z-Wave Light 1 to On (255) by/from: CAPI Control Handler
                        Last edited by NL_Logan; April 13, 2017, 02:27 AM.

                        Comment


                          #13
                          Originally posted by NL_Logan View Post
                          My 2nd could not trigger, thats weird.
                          For some reason HS does not think one (or both) of the conditions on the event has been met. My first guess is that there might be a short delay after the trigger light goes off before it is reflected in the HS condition, but that is just a guess. To test the idea you could add a short delay of a second or two to the run event action.
                          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


                            #14
                            Also try changing the "Had its value set to off" to "changes and becomes" to see if that helps.

                            Greig.
                            Zwave = Z-Stick, 3xHSM100� 7xACT ZDM230, 1xEverspring SM103, 2xACT HomePro ZRP210.
                            X10 = CM12U, 2xAM12, 1xAW10, 1 x TM13U, 1xMS13, 2xHR10, 2xSS13
                            Other Hardware = ADI Ocelot + secu16, Global Cache GC100, RFXtrx433, 3 x Foscams.
                            Plugings = RFXcom, ActiveBackup, Applied Digital Ocelot, BLDeviceMatrix, BLGarbage, BLLAN, Current Cost, Global Cache GC100,HSTouch Android, HSTouch Server, HSTouch Server Unlimited, NetCAM, PowerTrigger, SageWebcamXP, SqueezeBox, X10 CM11A/CM12U.
                            Scripts =
                            Various

                            Comment


                              #15
                              Originally posted by enigmatheatre View Post
                              Also try changing the "Had its value set to off" to "changes and becomes" to see if that helps.
                              I think that event is working as expected. It's the event it runs as an action that is not executing because its conditions are not met.
                              Apr-13 2:00:44 PM Event 'Run Event' action execution skipped, the conditions applied were not met: Demo 2017 All Light Off_set 2
                              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