mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-10 09:16:53 +00:00
73_GasCalculator: bugfix - SiPowerPrefix was 1000 too small
git-svn-id: https://svn.fhem.de/fhem/trunk@26667 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
0eb3cb11e7
commit
3c6a9e9b53
@ -1076,8 +1076,8 @@ sub GasCalculator_Notify($$)
|
||||
readingsSingleUpdate($GasCalcReadingDestinationDevice, "." . $GasCalcReadingPrefix . "_LastUpdateTimestampUnix", $GasCountReadingTimestampCurrentRelative, 0);
|
||||
}
|
||||
|
||||
### Calculate Current Power P = DV/Dt[cubic/s] * GaszValue * GasNominalHeatingValue[kWh/cubic] * 3600[s/h] / SiPrefixPowerFactor
|
||||
my $GasCalcPowerCurrent = ($GasCountReadingValueDelta / $GasCountReadingTimestampDelta) * $attr{$GasCalcName}{GaszValue} * $attr{$GasCalcName}{GasNominalHeatingValue} * 3600 / $GasCalcDev->{system}{SiPrefixPowerFactor};
|
||||
### Calculate Current Power P = DV/Dt[cubic/s] * GaszValue * GasNominalHeatingValue[kWh/cubic] * 3600[s/h] * 1000[1/k]/ SiPrefixPowerFactor
|
||||
my $GasCalcPowerCurrent = ($GasCountReadingValueDelta / $GasCountReadingTimestampDelta) * $attr{$GasCalcName}{GaszValue} * $attr{$GasCalcName}{GasNominalHeatingValue} * 3600 * 1000 / $GasCalcDev->{system}{SiPrefixPowerFactor};
|
||||
|
||||
### Calculate daily sum of power measurements "SP" and measurement counts "n" and then calculate average Power "Paverage = SP/n"
|
||||
my $GasCalcPowerDaySum = ReadingsVal($GasCalcReadingDestinationDeviceName, "." . $GasCalcReadingPrefix . "_PowerDaySum", "0") + $GasCalcPowerCurrent;
|
||||
|
Loading…
x
Reference in New Issue
Block a user