mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-04 22:19:38 +00:00
git-svn-id: https://svn.fhem.de/fhem/trunk@2455 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
68afbe4306
commit
1378d7da9e
@ -434,7 +434,7 @@ sub OWCOUNT_FormatValues($) {
|
|||||||
}
|
}
|
||||||
#-- rate
|
#-- rate
|
||||||
if( ($delt > 0.0) && $present ){
|
if( ($delt > 0.0) && $present ){
|
||||||
$vrate = int( ($vval-$oldval)/$delt*1000)/1000;
|
$vrate = ($vval-$oldval)/$delt;
|
||||||
} else {
|
} else {
|
||||||
$vrate = 0.0;
|
$vrate = 0.0;
|
||||||
}
|
}
|
||||||
@ -443,7 +443,8 @@ sub OWCOUNT_FormatValues($) {
|
|||||||
$vrate*=3600;
|
$vrate*=3600;
|
||||||
}elsif( $period eq "minute" ){
|
}elsif( $period eq "minute" ){
|
||||||
$vrate*=60;
|
$vrate*=60;
|
||||||
}
|
}
|
||||||
|
$vrate = int($vrate * 1000)/1000;
|
||||||
|
|
||||||
if( !defined($runit) ){
|
if( !defined($runit) ){
|
||||||
Log 1,"OWCOUNT: Error in rate unit definition. i=$i, owg_rate[i]=".$owg_rate[$i];
|
Log 1,"OWCOUNT: Error in rate unit definition. i=$i, owg_rate[i]=".$owg_rate[$i];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user