I have used
and then used that statuses to turn my lights on and off.
i searched the Astro binding in the community and there is a bunch of guys that say it has double triggers. that was my main reason for changing to TOD.
My Rule:
rule "Stoep Light On"
when
Item vTimeOfDay changed to "EVENING"
then
if (Alarm_Status.state == "Disarmed") {
Kitchen_Light_Stoep.sendCommand(ON) }
if (Alarm_Status.state == "Armed-Stay") {
Kitchen_Light_Stoep.sendCommand(ON) }
if (Alarm_Status.state == "Armed-Away") {
Kitchen_Light_Stoep.sendCommand(ON) }
end
rule "Stoep Light Off"
when
Item vTimeOfDay changed to "BED"
then
if ( Alarm_Status.state == "Armed-Stay" ) {
Kitchen_Light_Stoep.sendCommand(OFF) }
if ( Alarm_Status.state == "Disarmed" ) {
sendBroadcastNotification("Stoep Light Still On" + " - " + now.toString("MM/dd HH:mm ")) }
end
rule "Stoep Light Off Armed"
when
Item vTimeOfDay changed to "MORNING"
then
if ( Alarm_Status.state == "Armed-Away" ) {
Kitchen_Light_Stoep.sendCommand(OFF) }
end
Thanks to @rossko57 it is working like a dream.