2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-03-10 09:16:53 +00:00

74_XiaomiFlowerSens: fix disableForInterval Bug

git-svn-id: https://svn.fhem.de/fhem/trunk@13062 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
LeonGaultier 2017-01-14 13:58:02 +00:00
parent 6639b892d2
commit e72d4e055e
2 changed files with 5 additions and 6 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it.
- bugfix: 74_XiaomiFlowerSens: fix disableForInterval Bug
- bugfix: 88_HMCCU.pm: fixed attribute substexcl
- update: 88_HMCCU.pm: new version 3.7
- bugfix: contrib/Widgets/DateTimePicker/fhemweb_datetime.js:

View File

@ -2,7 +2,7 @@
#
# Developed with Kate
#
# (c) 2016 Copyright: Marko Oldenburg (leongaultier at gmail dot com)
# (c) 2016-2017 Copyright: Marko Oldenburg (leongaultier at gmail dot com)
# All rights reserved
#
# This script is free software; you can redistribute it and/or modify
@ -35,7 +35,7 @@ use POSIX;
use JSON;
use Blocking;
my $version = "0.2.10";
my $version = "0.2.11";
@ -129,7 +129,6 @@ sub XiaomiFlowerSens_Attr(@) {
elsif( $cmd eq "del" ) {
readingsSingleUpdate ( $hash, "state", "active", 1 );
InternalTimer( gettimeofday()+int(rand(30)), "XiaomiFlowerSens_stateRequestTimer", $hash, 1 );
Log3 $name, 3, "Sub XiaomiFlowerSens ($name) - enabled";
}
}
@ -142,7 +141,6 @@ sub XiaomiFlowerSens_Attr(@) {
elsif( $cmd eq "del" ) {
readingsSingleUpdate ( $hash, "state", "active", 1 );
InternalTimer( gettimeofday()+int(rand(30)), "XiaomiFlowerSens_stateRequestTimer", $hash, 1 );
Log3 $name, 3, "Sub XiaomiFlowerSens ($name) - enabled";
}
}
@ -200,12 +198,12 @@ sub XiaomiFlowerSens_stateRequestTimer($) {
XiaomiFlowerSens($hash);
InternalTimer( gettimeofday()+$hash->{INTERVAL}+int(rand(300)), "XiaomiFlowerSens_stateRequestTimer", $hash, 1 );
} else {
readingsSingleUpdate ( $hash, "state", "disabled", 1 );
}
InternalTimer( gettimeofday()+$hash->{INTERVAL}+int(rand(300)), "XiaomiFlowerSens_stateRequestTimer", $hash, 1 );
Log3 $name, 5, "Sub XiaomiFlowerSens ($name) - Request Timer wird aufgerufen";
}