mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-10 03:06:37 +00:00
10_ZWave.pm: move timeToAck to the readings.
git-svn-id: https://svn.fhem.de/fhem/trunk@11760 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
56265292f9
commit
d724c43b70
@ -3610,7 +3610,8 @@ ZWave_processSendStack($$;$)
|
||||
my ($hash,$ackType, $omsg) = @_;
|
||||
my $ss = $hash->{SendStack};
|
||||
if(!$ss) {
|
||||
$hash->{timeToAck} = sprintf("%0.3f", gettimeofday()-$hash->{lastMsgSent})
|
||||
readingsSingleUpdate($hash, "timeToAck",
|
||||
sprintf("%0.3f", gettimeofday()-$hash->{lastMsgSent}), 0)
|
||||
if($ackType eq "ack" && $hash->{lastMsgSent});
|
||||
return;
|
||||
}
|
||||
@ -3630,8 +3631,9 @@ ZWave_processSendStack($$;$)
|
||||
Log 4, "ZWave: wrong callbackid $omsg received, expecting $cbid";
|
||||
return;
|
||||
}
|
||||
$hash->{timeToAck} = sprintf("%0.3f", $now-$hash->{lastMsgSent})
|
||||
if($hash->{lastMsgSent});
|
||||
readingsSingleUpdate($hash, "timeToAck",
|
||||
sprintf("%0.3f", $now-$hash->{lastMsgSent}), 0)
|
||||
if($hash->{lastMsgSent});
|
||||
if($stype eq "get") {
|
||||
$ss->[0] = "sentackget:$smsg$cbid";
|
||||
return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user