Blockly PIR motion detection lights control issue
Posted: Thursday 20 October 2016 22:38
Hi,
I'm total noob with LUA hence I need to rely on Blockly. Here's the issue I'm experiencing:
- PIR sensor - Everspring SP103 PIR Motion Sensor
- LED flood light controlled by FIBARO System FGS222 Double Relay Switch 2x1.5kW
I have a blockly already created as follows:
The way that PIR sensor works is once there's a movement it stays active for 6 seconds.
What I need to achieve is:
- if there's a movement the floodlight stays on for 30 seconds (already done - 6 seconds + 24 = 30)
- if the floodlight is already turned on don't turn it off after 30 seconds, e.g. when we dine in the backgarden after sunset
- if the floodlight is off and there's a movement turn it on and when the movement reoccurs within that 30 seconds, reset the timer so the floodlight stays on.
LUA is too complex for me at this stage. Hence Blockly approach.
Thanks in advance,
Rafal
I'm total noob with LUA hence I need to rely on Blockly. Here's the issue I'm experiencing:
- PIR sensor - Everspring SP103 PIR Motion Sensor
- LED flood light controlled by FIBARO System FGS222 Double Relay Switch 2x1.5kW
I have a blockly already created as follows:
The way that PIR sensor works is once there's a movement it stays active for 6 seconds.
What I need to achieve is:
- if there's a movement the floodlight stays on for 30 seconds (already done - 6 seconds + 24 = 30)
- if the floodlight is already turned on don't turn it off after 30 seconds, e.g. when we dine in the backgarden after sunset
- if the floodlight is off and there's a movement turn it on and when the movement reoccurs within that 30 seconds, reset the timer so the floodlight stays on.
LUA is too complex for me at this stage. Hence Blockly approach.
Thanks in advance,
Rafal