From b7cab2e65515d2c8ca21a5e2ff83d5f8b31617e1 Mon Sep 17 00:00:00 2001 From: unimatrix27 <> Date: Sun, 25 Mar 2012 09:48:21 +0000 Subject: [PATCH] removal of stupid timer bug in 59_Twilight.pm git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@1382 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- FHEM/59_Twilight.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/FHEM/59_Twilight.pm b/FHEM/59_Twilight.pm index 4b81261bc..9aed6b7c4 100644 --- a/FHEM/59_Twilight.pm +++ b/FHEM/59_Twilight.pm @@ -209,14 +209,14 @@ sub Twilight_GetUpdate($){ } readingsUpdate($hash,"nextEventTime",strftime("%H:%M:%S",localtime($nexttime))); if($i==5 || $i==6){ - $nexttime = ($nexttime-$now)/5; + $nexttime = ($nexttime-$now)/2; $nexttime=120 if($nexttime<120); $nexttime=900 if($nexttime>900); }else{ $nexttime = $nexttime+10; } if(!$hash->{LOCAL}) { - InternalTimer(sprintf("%.0f",$nexttime), "Twilight_GetUpdate", $hash, 0); + InternalTimer(sprintf("%.0f",$now+$nexttime), "Twilight_GetUpdate", $hash, 0); } $hash->{STATE}=$i; last;