mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-04 22:19:38 +00:00
10_FBDECT.pm: remove double temperature events (Forum #57644)
git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@12167 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
423a13b2d2
commit
aafc9a15e3
@ -221,7 +221,7 @@ my %fbhttp_readings = (
|
|||||||
present => '"present:".($val?"yes":"no")',
|
present => '"present:".($val?"yes":"no")',
|
||||||
productname => '"FBTYPE:$val"',
|
productname => '"FBTYPE:$val"',
|
||||||
state => '"state:".($val?"on":"off")',
|
state => '"state:".($val?"on":"off")',
|
||||||
tist => 'sprintf("temperature:%.1f C (measured)", $val/2)',
|
# tist => 'sprintf("temperature:%.1f C (measured)", $val/2)', # Forum #57644
|
||||||
tsoll => 'sprintf("desired-temp:%s", $val)',
|
tsoll => 'sprintf("desired-temp:%s", $val)',
|
||||||
members => '"members:$val"',
|
members => '"members:$val"',
|
||||||
);
|
);
|
||||||
@ -270,9 +270,11 @@ FBDECT_ParseHttp($$$)
|
|||||||
if($n eq "tsoll");
|
if($n eq "tsoll");
|
||||||
$val = $type if($n eq "productname" && $val eq "");
|
$val = $type if($n eq "productname" && $val eq "");
|
||||||
my ($ptyp,$pyld) = split(":", eval $fbhttp_readings{$n}, 2);
|
my ($ptyp,$pyld) = split(":", eval $fbhttp_readings{$n}, 2);
|
||||||
readingsBulkUpdate($hash, $ptyp, $pyld);
|
if($n eq "tsoll") {
|
||||||
readingsBulkUpdate($hash, "state", "$ptyp: $pyld")
|
readingsBulkUpdate($hash, "state", "$ptyp: $pyld")
|
||||||
if($n eq "tsoll"); # Exception
|
} else {
|
||||||
|
readingsBulkUpdate($hash, $ptyp, $pyld);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
readingsEndUpdate($hash, 1);
|
readingsEndUpdate($hash, 1);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user