Order of blocky vs manual inputs
Posted: Friday 04 January 2019 23:12
I have a pi running zigbee2mqtt and it's plugin for domoticz, a philips motion sensor and a 'klikaaklikuit' magnetic door sensor.
I added the motion sensor to supported devices for the domoticz plugin (see latest repo pull request merge). This works.
Now what I want is the hallway light to be turned on for 5 minutes whenever either the motion detector detects motion OR the magnetic doorcontact is opened.
The blockly schematic for this is fairly simple. Put in text:
As said, this works as expected.
However, suppose I now go to the hallway, the light turns on. For whatever reason, I use the app to turn it off. Now no matter how much I move, it will not turn on again.
Basically I want every movement or change in the door contact status to 'open' to switch the lights on if not on and (re)set the timer to 5 minutes.
What am I doing wrong?
I added the motion sensor to supported devices for the domoticz plugin (see latest repo pull request merge). This works.
Now what I want is the hallway light to be turned on for 5 minutes whenever either the motion detector detects motion OR the magnetic doorcontact is opened.
The blockly schematic for this is fairly simple. Put in text:
Code: Select all
if
motiondetector == on OR magnetic_contact == open
do
set hallway_light level 80%
set hallway_light on for 5 minutes
However, suppose I now go to the hallway, the light turns on. For whatever reason, I use the app to turn it off. Now no matter how much I move, it will not turn on again.
Basically I want every movement or change in the door contact status to 'open' to switch the lights on if not on and (re)set the timer to 5 minutes.
What am I doing wrong?