Page 1 of 1

if os or domoticz time is....

Posted: Monday 07 May 2018 17:27
by poudenes
Hi All,

can someone give me a start how to do follow. The commands are not correct one but to explain what i want:

if domoticz.time (or os.time) is 19:05 then

else if domoticz.time (or os.time) is 20:00 then

i tried everything form information of dzVents Wiki but can't find it

cheers
:D

Re: if os or domoticz time is....

Posted: Monday 07 May 2018 20:17
by dannybloe

Code: Select all

if domoticz.time.matchesRule('at 20:00') then
else if domoticz.time.matchesRule('at 19:05')
end
or

Code: Select all

if domoticz.time.hour == 20 and domoticz.time.minutes == 0 and domoticz.time.seconds == 0 then
or

Code: Select all

if domoticz.time.rawTime == '20:00:00'
It's all in the documentation.

Re: if os or domoticz time is....

Posted: Monday 07 May 2018 22:27
by poudenes
Thanks. Sometimes I don't see the rules how I need to use them. But thanks for explanation!
dannybloe wrote:

Code: Select all

if domoticz.time.matchesRule('at 20:00') then
else if domoticz.time.matchesRule('at 19:05')
end
or

Code: Select all

if domoticz.time.hour == 20 and domoticz.time.minutes == 0 and domoticz.time.seconds == 0 then
or

Code: Select all

if domoticz.time.rawTime == '20:00:00'
It's all in the documentation.


Verzonden vanaf mijn iPhone met Tapatalk Pro