diff --git a/rules/salon.lampka-stolowa.rules b/rules/salon.lampka-stolowa.rules index 0218a8e..36e1ad1 100644 --- a/rules/salon.lampka-stolowa.rules +++ b/rules/salon.lampka-stolowa.rules @@ -48,8 +48,10 @@ rule "Zapal lampkę i kanapowe przez zmierzchem gdy pochmurno" when Item sSunset_Event_in_twohours received update ON then - /* more than 90% cloud cover && TODO: only april-octotber */ - if (wClouds.state > 90.0 && true) { + var Number hours = now.getHourOfDay + + /* more than 90% cloud cover && not before 14:00 hour && TODO: only april-october */ + if (wClouds.state > 90.0 && hours >= 14 && true) { logInfo("stollampka", "Powyżej 90% chmur, zapalam") /* sSONOFF02.sendCommand(ON) */