mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-28 17:12:32 +00:00
at/watchdog bugfix
git-svn-id: https://svn.fhem.de/fhem/trunk@295 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
286a9f3ac6
commit
a6e9f36d4d
@ -463,3 +463,4 @@
|
|||||||
- feature: contrib/fhem2speech from Martin
|
- feature: contrib/fhem2speech from Martin
|
||||||
- bugfix: attributes of at devices disappear
|
- bugfix: attributes of at devices disappear
|
||||||
- feature: attribute rainadjustment for KS300 (Boris 2008-12-17)
|
- feature: attribute rainadjustment for KS300 (Boris 2008-12-17)
|
||||||
|
- bugfix: deleting at / watchdog while active creates an empty device
|
||||||
|
@ -12,6 +12,7 @@ at_Initialize($)
|
|||||||
my ($hash) = @_;
|
my ($hash) = @_;
|
||||||
|
|
||||||
$hash->{DefFn} = "at_Define";
|
$hash->{DefFn} = "at_Define";
|
||||||
|
$hash->{UndefFn} = "at_Undef";
|
||||||
$hash->{AttrFn} = "at_Attr";
|
$hash->{AttrFn} = "at_Attr";
|
||||||
$hash->{AttrList} = "disable:0,1 skip_next:0,1";
|
$hash->{AttrList} = "disable:0,1 skip_next:0,1";
|
||||||
}
|
}
|
||||||
@ -75,6 +76,14 @@ at_Define($$)
|
|||||||
return undef;
|
return undef;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub
|
||||||
|
at_Undef($$)
|
||||||
|
{
|
||||||
|
my ($hash, $name) = @_;
|
||||||
|
RemoveInternalTimer($name);
|
||||||
|
return undef;
|
||||||
|
}
|
||||||
|
|
||||||
sub
|
sub
|
||||||
at_Exec($)
|
at_Exec($)
|
||||||
{
|
{
|
||||||
|
@ -12,6 +12,7 @@ watchdog_Initialize($)
|
|||||||
my ($hash) = @_;
|
my ($hash) = @_;
|
||||||
|
|
||||||
$hash->{DefFn} = "watchdog_Define";
|
$hash->{DefFn} = "watchdog_Define";
|
||||||
|
$hash->{UndefFn} = "watchdog_Undef";
|
||||||
$hash->{NotifyFn} = "watchdog_Notify";
|
$hash->{NotifyFn} = "watchdog_Notify";
|
||||||
$hash->{AttrList} = "disable:0,1";
|
$hash->{AttrList} = "disable:0,1";
|
||||||
}
|
}
|
||||||
@ -108,5 +109,13 @@ watchdog_Activate($)
|
|||||||
InternalTimer($nt, "watchdog_Trigger", $ntfy, 0)
|
InternalTimer($nt, "watchdog_Trigger", $ntfy, 0)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub
|
||||||
|
watchdog_Undef($$)
|
||||||
|
{
|
||||||
|
my ($hash, $name) = @_;
|
||||||
|
RemoveInternalTimer($hash);
|
||||||
|
return undef;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
1;
|
1;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user