This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Presence sensor - Reset timer/delay
#5
Hi Erwin,

I tried your script once more, and this time I got it to work. I must have made a copy error or something the last time Smile
Thank you!

In regards to my 2 scripts. I am trying to understand how things work, and I don't understand how they can not be a stable solution. Could you try and explain it to me in a bit more detail. This way I get a better understanding. Because I am also writing scripts that controls one light depending on the status of two doors... and there is also a delay involved... These scripts is based on the same logic, thus making it important for me to understand (:

Just so you know the way my motion sensor is set up:
If presence is detected it will send a 1 straight away.
If presence is no longer detected, it will wait 10 seconds, and then send a 0.
As long as there is presence, nothings is being sent.

My Event-based script is triggered by my motion sensor.
If a 1 is received the script turns on the light and disables the resident script called "Sensor".
If a 0 is received it activates the resident script called "Sensor"

The resident script is called "Sensor"
If active, waits 5 min, then checks if value of my motion sensor = 0 (no presence), if so it turns the light of.

Thanks for your help so far!

BR
Mr. D
Reply


Messages In This Thread
Presence sensor - Reset timer/delay - by Mr.D - 14.04.2017, 21:18
RE: Presence sensor - Reset timer/delay - by Mr.D - 16.04.2017, 10:27

Forum Jump: