Announcement

Collapse
No announcement yet.

Forced wait between triggering?

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

    Forced wait between triggering?

    So I'm sittin' there, doin my daily "business", and my "lights off" event is triggered from BLRadar's [SENSOR RECOVERY]. So I start gesticulating my arms to turn 'em back on and... nothin. I keep moving my hands around and FINALLY, after a minute, the light comes back on. Afterwards, I try editing the event my motion sensor triggers and there is this:
    Code:
    Number of minutes sensor must
    be off before re-trigger: [1]
    I tried making it [0] and got this:
    Code:
    The following validation error has occurred:
    [B][COLOR="Red"]The number of minutes to wait for sensor event must be greater than Zero![/COLOR][/B]
    Why? Instead of waiting a minute for the sensor to be off, can it instead check some other condition? ie.if a device (light) is off already, then it's ok to trigger the event instantly. Even when checking if the sensor is registering no motion, my "off" script has already fired... why not allow the firing of the "on" script right away?

    #2
    Did you get this resolved?

    Comment


      #3
      I ended up completely changing how I approach turning a light off once it's turned on via motion. Instead of using a timer and re-checking for more motion to keep the light on, I leave it on forever. I setup a bunch of pairings of my motion detectors (32 pairings so far) under the Movement tab in BLRadar and now use events and a little scripting to turn off a light. Have a look in that tab and tell it to create "from -> to" pairings for your motion sensors.

      For example, if I am in the closet/bathroom area, which is motion sensor D3, there are three motion sensors in other areas that could be triggered when I leave the closet/bathroom area.

      Those other areas are:
      Main Entrance(D1)
      Living Room(E3)
      Studio(E5)

      I created one movement device per motion sensor pairing, indicating movement from the closet/bathroom to other areas:
      Device name = "D3 -> D1", indicating movement from Closet/Bathroom to Main Entrance has occured
      Device name = "D3 -> E3", indicating movement from Closet/Bathroom to Living Room has occured
      Device name = "D3 - > E5", indicating movement from Closet/Bathroom to Studio has occured

      If I now move from the closet/bathroom area to my Main Entrance, the "D3 -> D1" device turns on. An event that looks for any of those three devices turning on now knows that I just left the closet/bathroom area and have entered another adjacent area, so it turns off the closet/bathroom lights. BLRadar keeping track of where you just came from whenever a new motion sensor is triggered is the key. All lights in every area I move into will now stay on until I move to a different area, whether I am constantly generating motion triggers in that area or not. No more timers and gesticulating to keep a light on.

      Likewise, I have three movement devices that cover moving from the Main Entrance into the Studio, Living Room or Closet/Bathroom areas.
      Device name = "D1 -> D3", indicating movement from the Main Entrance to the Closet/Bathroom area has occured
      Device name = "D1 -> E3", indicating movement from the Main Entrance to the Living Room has occured
      Device name = "D1 -> E5", incidcating movement from the Main Entrance to the Studio has occured

      NOTE: I realize the movement devices turn on to indicate movement in one direction and turn off to indicate movement in the opposite. I decided to go off of the trigger On only and not have to deal with more timeouts and tracking the trigger Off. For example, I may have gone into the Living Room from the Entrance but then moved into the Closet area, not back to the Entrance, so if "Entrace->LivingRoom" finally turned off, that doesn't mean I went backwards from the LivingRoom to the Entrance. Just going off of On activity has been dead on rock solid for me.

      If any of those three devices turn on, a separate event fires and turns off the Entrance Light because it knows I just left there.

      The scripting that I have run when these events are fired simply checks if my Home Mode is in a few different states like, "nighttime pee mode", in which case, I don't want to turn off the closet/bathroom lights when I leave the area because the Home mode has turned certain lights on to act as a night light so I can see all the way back to my bedroom. I also have a virtual variable called, "Location Tracking". If that is off, then lights turn on when I enter an area but they never turn off when I leave. It can be convenient when moving around a lot to just leave the lights on. I use the Homebridge Node.js server with homebridge-homeseer-plugin-2018 to connect HomeSeer to Apple's Homekit and have made an entry for the Location Tracking device so I can say at any time, "Hey Siri, turn Location Tracking off" and the lights stay on when walking from room to room.

      While not directly related to movement tracking, I also keep track of which room I am in via a device called, "Location" in a room named, "Randy". Since HS always knows which room I am in, I created an event simply called, "Lights". At any time, I can say (just like in Star Trek: TNG), "Hey Siri, lights" and the script checks lighting in the room I am in. If any of the lights are on, it turns all lights off. If all lights are off, it turns them all on. I will be adding an XAP800 audio matrix to my setup soon and will hopefully enjoy mic/speaker routing for the VR/TTS portion of HS to only be active in the room I am currently in. I'll then be able to transfer most Siri-related voice commands to HS itself. The main benefit of that would be that I can configure my VR scripts to leave HS in listening mode for a few seconds after each command for adjustments. ie."Computer, lights. Lower. Play some music" without having to say, "Hey Siri" in between each command. (I swear, I must say, "Hey Siri" 100 times per day!)

      Needless to say, all of this only works with one person in the home. I'm glad I don't have to try a scripting solution for automatic lighting with 2 or more people in the same place!
      Last edited by RandyInLA; September 11, 2018, 09:30 PM.

      Comment


        #4
        This seems very complicated. I simply use an event on the BLRadar virtual device. When the motion zone turns on, I turn the light on, when the zone turns off, the light turns off. The sensors feed the zone, so one, two, ten sensors all can provide input to the zone. If ANY see motion, then the zone stays active until its auto-off period (say 10 mins for a closet). The retriggering you mention would only come into play if my auto-off time was shorter than 1 minute, but since all zones are 5 mins or longer its not an issue. If I stay in say the garage, every few minutes the motion detector tells BLRadar I'm still there and the auto-of time is extended.

        Comment


          #5
          I only have one motion sensor per zone (small apartment). Even if I had 2 or 3 sensors, if I'm not moving, I'm not moving. The retriggering to turn a light back on comes into play if I didn't move enough to keep the light on. So I have to move my arms around to retrigger, but that doesn't work as I have to wait for 1 minute. I don't want to set a time limit of 5 or 10 minutes because if I go in and back out of a room right away, I don't want the lights to stay on. And I may be sitting still for longer than 5 or 10 minutes, in which case I still have the same issue. Nothing is solved by increasing the amount of sensors or the timeout because the core issue is that I have to keep moving to extend the time.

          Since using the Movement tab of the plugin, every single light turns off as soon as I leave the area and never before. It's perfect I no longer care about the retrigger limitation because I'm not relying on motion or a timeout to turn lights off. The naming of the devices is handled by BLRadar. It's not nearly as difficult to setup as it appears when reading about how it works. So as complicated as it seems on the surface, the result is an extremely simple and very reliable user experience, which outweighs the setup for me.

          Comment

          Working...
          X