So far, it's easy to do so by rules. Relay is defined as switch input device, but I'm controlling it directly via GPIO (GPIO13 in this case):
Code: Select all
On Clock#Time=All,09:00 do
Gpio,13,1
Endon
On Clock#Time=All,15:30 do
Gpio,13,0
Endon
I found this solution, that could handle this reboot, but it's not ideal. It 'takes' one of system timers and could cause very short on/off switch of relay, that is not 'healthy' for connected AC device ..
Code: Select all
On System#Boot do
TimerSet,6,1 // timer for relay02
Endon
On Clock#Time=All,09:00 do
Gpio,13,1
Endon
On Clock#Time=All,15:30 do
Gpio,13,0
Endon
On Rules#Timer=6 do
If %systime% < 09:00:00
Gpio,13,0
Else
Gpio,13,1
Endif
If %systime% > 15:30:00
Gpio,13,0
Endif
Endon
Thanks for help! :]