Adding Times

Hi all

I have added the “add on Timer” to my setup but can’t work out how to connect it up to my motion sensors (there are three). Can anyone help explain how this plugin works please.

All I need to do is have my motion sensor activated between say 20:00 at night until 09:00 the following day and I just can’t fathom out how its done using this facility. By this I mean, how do you assign each of the sensors to it ?
Any help would be very much appreciated. Thanks all

I’ve never used this, but if it’s like other some other capabilities you may need to create an actual timer instance, and then multiple rules to use it. This assume that timers have a not-completed/completed? state…

  • Create a timer instance, that can be fired and is initialized as not-fired
  • Create a rule, triggered by a sensor, that fires the timer instance
  • Create a rule that is triggered when the timer enters the “completed” state
    Reset the timer to not-completed

I do this basic flow using a Virtual Button triggered by a remote application to trigger WT lights.

Hi Eric, many thanks for your reply and advice. I’m very new to WT and I’m not sure I fully understand your suggestions only because I’ve not come across your terminology, but you have given me things to look up and that’s a big step from where I was so this is a big help. So thanks for your help it’s appreciated. Alex

The way that timers and sensors are assigned to each another is via Rules. However, I think that what you are trying to do should involve the Datetime addon rather than the Timer addon.

The rules are very fine grained, so likely you will need at least one rule per sensor, and perhaps more if what you want to do is complex.

For example, go to Rules:

  1. create a new rule

  2. drag Datetime into the input side

  3. In Datetime, select Hour from the drop down and set the condition to >=20 (or >19, if there’s no ‘>=‘ option)

  4. drag Datetime (again) into the input side

  5. in the 2nd Datetime, select Hour and set the condition to <9

  6. drag one of the Motion Sensors into the input side.

  7. in the Motion Sensor, select Motion and set the condition to = Motion

The rules engine monitors these three conditions, and when they are all met, the actions in the output side will be triggered. I’ll leave the set up of those actions to you :stuck_out_tongue_winking_eye:

Next, repeat for each of the other two sensors.

Hey, thanks so much for your help in explaining how to do this Charles as I didn’t realise/know about this. It can or will also help for me for the future too if I can get my head around it so great. I really appreciate it.

WT has so much potential if you can understand it but with yourself and others from the forum, members helping each, it’s got a great future I am sure. Thanks again. Alex.

Hi Charles,
I have just added the Datetime addon, and it says its been added, but when I go to rules its not there. I deleted it and added it again, same thing. Any idea why this might be happening has anybody else had the same problem I wonder ?

After installing, did you press + on the Things page to activate it?

Hi Charles

Eureka :grinning:

When it said in the GitHub page refresh it, I just shut it down and booted it back up again, so it’s a Duhhhhh moment considering I’ve 18 devices now on my system and have done this several times already …

Sorry to have troubled you again but thanks. But that’s another bit on the learning curve I’ve done albeit a bit embarrassing!!

Oops, there’s a logic error in my Datetime setup. It needs two separate rules, one for Hour >=20 and a different rule for Hour < 9.

Must have been nearly asleep

Hi Charles,

That’s kind of you to let me know.
And I’ll be having a bash with it later today, so this is useful.

Thanks very much