From ea16341b277c19fa9a9e175c5374edc69a2d9397 Mon Sep 17 00:00:00 2001 From: Tomasz Torcz Date: Tue, 14 Dec 2021 16:02:02 +0100 Subject: [PATCH] =?UTF-8?q?salon:=20przed=20godz.=2014=20nie=20w=C5=82?= =?UTF-8?q?=C4=85cza=C4=87=20=C5=9Bwiate=C5=82=20nawet=20jak=20jest=20poch?= =?UTF-8?q?murno?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- rules/salon.lampka-stolowa.rules | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) 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) */