Announcement

Collapse
No announcement yet.

How do I setup this event...

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

    How do I setup this event...

    I want a light to turn on if the motion sensor senses motion if the time of day is 15 minutes before sunset until 11:59PM.

    Currently I have the following:
    Time is before 11:59 PM AND Time is anytime after sunset AND Device: Zwave Hallway Overhead Light is OFF
    But I want to extend the time to read 15 minutes before sunset. If I change "Time is anytime after sunset" to "15 minutes before sunset" my event on triggers once - 15minutes before sunset!

    Any suggestions would be appreciated.

    Thanks!

    #2
    An alternative approch is to create an event which is triggered 15 minutes before sunset which insert an new event which is triggered by motion (by using hs.createEvent(....).

    Then create a second event which runs at 11:59 PM which checks if the motion-triggered event is still present, and if so, removes it.

    Comment


      #3
      This is one of those events that I would use a virtual device as a flag. Turning on the flag at 15 minutes before sunset and off at 11:59pm.

      Then you just use that flag being on as one of the conditions for your motion controlled light.
      Marty
      ------
      XPpro SP3 /w HS Standard 2.5.0.80, HSTouch Server - 1.0.0.70, HSTouch Client 1.0.0.73 HSTouch Android - 1.0.0.2, HSTouch iPhone - 1.0.0.2
      Playing with HS3 a bit but it's just play at this point.

      Comment


        #4
        Hello,
        That's it! I setup a virtual device and used it as my condition. This will work fine.

        Its a bit more complex than I wanted to have but this will work.

        One day I'm going to get the scripting education I need so I can write a few scripts.

        Thanks!

        Comment


          #5
          glad i could help in a small way, not being a scripter either I find most things can be done without.
          Marty
          ------
          XPpro SP3 /w HS Standard 2.5.0.80, HSTouch Server - 1.0.0.70, HSTouch Client 1.0.0.73 HSTouch Android - 1.0.0.2, HSTouch iPhone - 1.0.0.2
          Playing with HS3 a bit but it's just play at this point.

          Comment

          Working...
          X