Page 1 of 1

Light switch does switch off, but then on again, and off, .... please help

Posted: Monday 05 February 2018 9:28
by AllesVanZelf
Hello all,
I have a problem with my Blockly script on Synology.
I try to switch on a lightswitch.
In the morning from 6:55 (if it's dark) till sunrise.
Image

And in the afternoon/evening: from 16:30 (or after sunset) till 23:30/11:30pm.
Image

This works all well except at the time of 23:30. Then the light switschen on and off repeatedly. Till I pull out the plug.

Sunset and sunrise are set by an "It is dark switch"/"Donker schakelaar".

Do you see why this script does not work well at 23:30?

Domoticz: Version: 3.8875
Build Hash: 3674fa5-modified
Compile Date: 2018-02-02 16:03:49 by Jadahl
dzVents Version: 2.4.1
On: Synology Nas 111

Re: Light switch does switch off, but then on again, and off, .... please help

Posted: Wednesday 07 February 2018 15:19
by AllesVanZelf
I just found out that the cause off this problem was based in the morning script. Then I realized that the OR between the 6:55-10 and 8-10 probably should be AND. Tonight we shall see if this indeed was the problem.

Re: Light switch does switch off, but then on again, and off, .... please help

Posted: Friday 09 February 2018 8:55
by AllesVanZelf
I still not happy with the result. The morning script starts at 6 o'clock now instead of 6:55 as expected.
Image
Why is this light switch trickered at 6?
This light switch is a 433 rfx switch.
Doordeweeksedag is a virtualswitch to indicate that it is mon-fri. and not a weekend.
Donkerschakkelaar is a virtual switch that is timed at sunset-sunrise.
Anyone a suggestion?

Re: Light switch does switch off, but then on again, and off, .... please help

Posted: Sunday 11 February 2018 11:22
by mrf68
Is the current system time correct?

Re: Light switch does switch off, but then on again, and off, .... please help

Posted: Sunday 11 February 2018 22:07
by AllesVanZelf
Thank you mrf68 for answering.
Yes, system time is correct. Do you have other suggestions?

Re: Light switch does switch off, but then on again, and off, .... please help

Posted: Monday 12 February 2018 17:10
by mrf68
Sorry, I don’t. 06:00 is not mentioned in the script, so it should not fire at that time. You could check the log if it really is this script that is triggered at 6. It also shows which part of the script did the trick. Maybe it’s an idea to split the blockly in 3 seperate blockly events, but it doesn’t explain why something happens at 6.