diff --git a/fhem/CHANGED b/fhem/CHANGED index 0a691f747..095b2564e 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -329,3 +329,4 @@ - feature: modify command added - feature: The "-" in the name is not allowed any more - bugfix: disabled notify causes "uninitialized value" (STefan, 1.5) + - bugfix: deleted FS20 items are still logging (zombie) (Gerhard, 16.5) diff --git a/fhem/FHEM/10_FS20.pm b/fhem/FHEM/10_FS20.pm index 416ac3bc7..d52580eb9 100755 --- a/fhem/FHEM/10_FS20.pm +++ b/fhem/FHEM/10_FS20.pm @@ -290,13 +290,14 @@ FS20_Undef($$) { my ($hash, $name) = @_; foreach my $c (keys %{ $hash->{CODE} } ) { - delete($defptr{$c}{$name}); + $c = $hash->{CODE}{$c}; + delete($defptr{$c}{$name}) if($defptr{$c}); } return undef; } sub -FS20_Parse($) +FS20_Parse($$) { my ($hash, $msg) = @_; diff --git a/fhem/FHEM/13_KS300.pm b/fhem/FHEM/13_KS300.pm index 6383f4ffd..d2d19fbf7 100755 --- a/fhem/FHEM/13_KS300.pm +++ b/fhem/FHEM/13_KS300.pm @@ -63,7 +63,7 @@ KS300_Undef($$) ##################################### sub -KS300_Parse($) +KS300_Parse($$) { my ($hash,$msg) = @_; diff --git a/fhem/FHEM/50_WS300.pm b/fhem/FHEM/50_WS300.pm index cfd54bcfc..b43b32922 100644 --- a/fhem/FHEM/50_WS300.pm +++ b/fhem/FHEM/50_WS300.pm @@ -176,9 +176,9 @@ WS300_Undef($$) ##################################### sub -WS300_Parse($) +WS300_Parse($$) { - my $msg = shift; + my ($hash, $msg) = @_; my $ll = GetLogLevel("WS300Device"); $ll = 5 if($ll == 2); @@ -639,7 +639,7 @@ NEXTPOLL: { if($rcount == 42) { - WS300_Parse($inbuf); + WS300_Parse($hash, $inbuf); goto NEXTPOLL; } else @@ -650,7 +650,7 @@ NEXTPOLL: } if($ic == 0x33) { - WS300_Parse($inbuf) if($rcount == 39); + WS300_Parse($hash, $inbuf) if($rcount == 39); $cmd=0x32; } $polling=0; diff --git a/fhem/FHEM/92_FileLog.pm b/fhem/FHEM/92_FileLog.pm index bdc774de2..5f606b847 100755 --- a/fhem/FHEM/92_FileLog.pm +++ b/fhem/FHEM/92_FileLog.pm @@ -15,7 +15,7 @@ FileLog_Initialize($) $hash->{UndefFn} = "FileLog_Undef"; $hash->{NotifyFn} = "FileLog_Log"; $hash->{AttrFn} = "FileLog_Attr"; - $hash->{AttrList} = "disable:0,1 logtype"; + $hash->{AttrList} = "disable:0,1 logtype nrarchive archivedir"; } @@ -55,6 +55,13 @@ FileLog_Undef($$) return undef; } +sub +HandleArchiving($) +{ + my ($log) = @_; + if(! + +} ##################################### sub @@ -83,6 +90,7 @@ FileLog_Log($$) my $cn = ResolveDateWildcards($log->{FILENAME}, @t); if($cn ne $log->{CURRENT}) { # New logfile + HandleArchiving($log); $fh->close(); $fh = new IO::File ">>$cn"; if(!defined($fh)) { diff --git a/fhem/docs/raw-codes b/fhem/docs/raw-codes index 5fb12fadb..ae160117a 100644 --- a/fhem/docs/raw-codes +++ b/fhem/docs/raw-codes @@ -13,7 +13,7 @@ where is one of: 810e04d70213a001b16d000003000000 RM100-2 smoke on 810e04d70213a001b16d000000000000 RM100-2 smoke off -81xx04xx0101a00180c2030011 FS20 dev: 1234 button: 03 on (11) +81xx04xx0101a0011234030011 FS20 dev: 1234 button: 03 on (11) To send it: -set FHZ raw 04 0101a00180c2030011 +set FHZ raw 04 0101a0011234030011 diff --git a/fhem/fhem.pl b/fhem/fhem.pl index a2ebeae90..43098a539 100755 --- a/fhem/fhem.pl +++ b/fhem/fhem.pl @@ -1581,6 +1581,7 @@ DoTrigger($$) # Log/notify modules my $ret = ""; foreach my $n (sort keys %defs) { + Log 5, "$dev trigger: Checking $n for notify"; $ret .= CallFn($n, "NotifyFn", $defs{$n}, $defs{$dev}); } diff --git a/fhem/test/fhem.save b/fhem/test/fhem.save index b99166713..3081d36de 100644 --- a/fhem/test/fhem.save +++ b/fhem/test/fhem.save @@ -1,4 +1,4 @@ -#Tue May 1 08:43:03 2007 +#Tue May 1 17:03:03 2007 setstate FHZ fhtbuf: 1c setstate FHZ 2006-02-12 14:03:39 fhtbuf 23 setstate FHZ 2006-03-26 08:47:36 init2 deadbeefdeadbe