Hi,
I’ve got a problem with a rule for my floor. I want the rule to be triggered if the lux is low and motion is detected. Otherwise the light should be stay off. I’ve read some rules examples but i don’t find the perfect solution for this.
My items
Number Auge_Node2 "Auge Node2" <present> {channel="zwave:device:51cae397:node2:alarm_motion"} //, expire="5m,command=OFF"
Number Auge_Node2_Temp "Temperatur Flur [%.0f °C]" <temperature> [ "CurrentTemperature" ] {channel="zwave:device:51cae397:node2:sensor_temperature"}
Number Auge_Node2_Licht "Licht Flur [%.0f Lux]" <sun> {channel="zwave:device:51cae397:node2:sensor_luminance"}
Number Auge_Node2_Batterie "Batterie Flur [%s %%]" <energy> {channel="zwave:device:51cae397:node2:battery-level"}
Number Auge_Node2_Alarm "Flur Alarm" <fire> {channel="zwave:device:51cae397:node2:alarm_tamper"}
Switch Motion_Flur_Timer { expire="4m,command=OFF" }
My Rule:
rule "Motion sensor triggered floor"
when
Item Auge_Node2 changed from OFF to ON
then
if (Auge_Node2_Licht.state < 300 ) {
Flur_Helligkeit.sendCommand(100)
Motion_Flur_Timer.sendCommand(ON)
}
end
rule "Lights on by motion floor"
when
Item Motion_Flur_Timer changed to ON
then
Flur_Helligkeit.sendCommand(100)
end
rule "Lights off by no more motion floor"
when
Item Motion_Flur_Timer changed to OFF
then
Flur_Helligkeit.sendCommand(0)
end
The item “Motion_Flur_Timer” is working nice on my sitemap. Maybe it’s only a little problem but i can’t find my problem.
Thx for you help and sorry for my englisch