statistics: attr durationPeriodHour 1 | 0
git-svn-id: https://svn.fhem.de/fhem/trunk@11309 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
@@ -131,6 +131,7 @@ sub statistics_Initialize($)
|
|||||||
."dayChangeTime "
|
."dayChangeTime "
|
||||||
."deltaReadings "
|
."deltaReadings "
|
||||||
."durationReadings "
|
."durationReadings "
|
||||||
|
."durationPeriodHour:0,1 "
|
||||||
."excludedReadings "
|
."excludedReadings "
|
||||||
."ignoreDefaultAssignments:0,1 "
|
."ignoreDefaultAssignments:0,1 "
|
||||||
."minAvgMaxReadings "
|
."minAvgMaxReadings "
|
||||||
@@ -928,6 +929,10 @@ sub statistics_doStatisticDuration ($$$$)
|
|||||||
$state = "(null)" if $state eq "";
|
$state = "(null)" if $state eq "";
|
||||||
|
|
||||||
statistics_Log $hash, 4, "Calculating duration statistics for '".$dev->{NAME}.":$readingName = $state'";
|
statistics_Log $hash, 4, "Calculating duration statistics for '".$dev->{NAME}.":$readingName = $state'";
|
||||||
|
|
||||||
|
# Daily Statistic
|
||||||
|
statistics_doStatisticDurationSingle $hash, $dev, $readingName, "Hour", $state, ($periodSwitch !=0)
|
||||||
|
if AttrVal($name, "durationPeriodHour", 0) == 1;
|
||||||
# Daily Statistic
|
# Daily Statistic
|
||||||
statistics_doStatisticDurationSingle $hash, $dev, $readingName, "Day", $state, ($periodSwitch >= 2 || $periodSwitch <= -2);
|
statistics_doStatisticDurationSingle $hash, $dev, $readingName, "Day", $state, ($periodSwitch >= 2 || $periodSwitch <= -2);
|
||||||
# Monthly Statistic
|
# Monthly Statistic
|
||||||
@@ -1223,6 +1228,10 @@ sub statistics_UpdateDevReading($$$$)
|
|||||||
<br>
|
<br>
|
||||||
Comma separated list of reading names for which a delta statistic shall be calculated.
|
Comma separated list of reading names for which a delta statistic shall be calculated.
|
||||||
</li><br>
|
</li><br>
|
||||||
|
<li><code>durationPeriodHour < 1 | 0 ></code>
|
||||||
|
<br>
|
||||||
|
If set to 1, then duration readings will get hourly statistics too.
|
||||||
|
</li><br>
|
||||||
<li><code>durationReadings <readings></code>
|
<li><code>durationReadings <readings></code>
|
||||||
<br>
|
<br>
|
||||||
Comma separated list of reading names for which a duration statistic shall be calculated.
|
Comma separated list of reading names for which a duration statistic shall be calculated.
|
||||||
@@ -1387,6 +1396,10 @@ sub statistics_UpdateDevReading($$$$)
|
|||||||
<br>
|
<br>
|
||||||
Durch Kommas getrennte Liste von weiteren Gerätewerten, für welche die Differenz zwischen den Werten am Anfang und Ende einer Periode (Stunde/Tag/Monat/Jahr) bestimmt wird.
|
Durch Kommas getrennte Liste von weiteren Gerätewerten, für welche die Differenz zwischen den Werten am Anfang und Ende einer Periode (Stunde/Tag/Monat/Jahr) bestimmt wird.
|
||||||
</li><br>
|
</li><br>
|
||||||
|
<li><code>durationPeriodHour < 1 | 0 ></code>
|
||||||
|
<br>
|
||||||
|
Wenn auf 1 gesetzt, dann werden für "durationReadings" auch stündliche Statistiken gebildet.
|
||||||
|
</li><br>
|
||||||
<li><code>durationReadings <Gerätewerte></code>
|
<li><code>durationReadings <Gerätewerte></code>
|
||||||
<br>
|
<br>
|
||||||
Durch Kommas getrennte Liste von weiteren Gerätewerten, für welche die Dauer einzelner Gerätewerte innerhalb bestimmte Zeiträume (Stunde/Tag/Monat/Jahr) erfasst wird.
|
Durch Kommas getrennte Liste von weiteren Gerätewerten, für welche die Dauer einzelner Gerätewerte innerhalb bestimmte Zeiträume (Stunde/Tag/Monat/Jahr) erfasst wird.
|
||||||
|
|||||||
Reference in New Issue
Block a user