Hi, I need some advice. I have 5 different lights and 4 motion sensors. The lights come on 35 minutes after sunset. We can then decide to manually switch off certain lights. If there is motion from any sensor then if the light is off, switch it on and switch it off if no further motion detected in say 2 min. The problem is the automatic triggering of a logic block turns off the lights even if they were manually turned on. Is there any way to stop a logic block from running? So in my case, if light is on… Don’t run a certain logicbloc? I think if I could sequence events rather like ladder logic and select which logic blocks to run it would be great. At the moment I switch the light on through IFTTT and time off by setting the IFTTT delay but would really appreciate keeping certain lights on if there was further motion.
Why don’t you add a condition to that logicblock to run only if light is off?
Your condition for logicblock to run should “Motion detected” AND “Light is off”
I think I tried that, as soon as the light is on that goes false
Does all the automation run through Apilio, and how to you manually switch them on/off?
Do you see the current light-status in Apilio? Is there a chance to know whether you turned them on manually?
I have sonoff switches that report the on / off status to Apilio. The only way to establish “manual on” is to use a logic block that if light is off then switch it on (then it must have been mtion (not manual) that switched them on. I still can’t see resolution as the condition that monitors the motion goes false to switch the lights off therefore any false result switches off the light
If I understand this correctly, I think the core problem is that you need to only run the “idle off” logicblock if the light was previously turned on by motion.
One way could be to somehow store the information that the light was triggered by motion and then in the “idle off” logicblock only run it if this was the case.
But as I’m writing, I have another idea: In the logicblock that triggers the motion light, add a “switch off” action with delay (2min) after the “switch on” action. If there’s more motion, the logicblock should run again, delete the previous actions and set a new delayed “off” with 2mins etc.
I’ll hopefully try that later. Thanks
Tried almost everything but still get light turning off as logic bloc evaluated to false
You can’t do this with a single logic block with actions for BOTH true and false. Create one logic block for turning on and another for turning off.
@jim1664 My idea was to work only with “positive” actions:
- Condition: Motion detected
- Actions for TRUE:
– Switch light on
– Switch light off (delay: 2mins)
If continuous motion is detected, the logicblock should be triggered before the 2mins, deleting all actions and starting again.
If it works depends a bit on the behaviour of your motion sensor.
Still struggling a) to initiate timer from an action and b) a timer that operates from a positive result.
Can anyone send an example? Just to reiterate, the light off evaluation must not work if the light was turned on manually rather than by motion