Hallo
ich möchte meinen Gas- und Stromverbrauch im 3 bzw-Stunden Rythmus darstellen. Dazu ist, wenn ich das richtig verstehe, "singularReadings" geeignet. Leider bekomme ich nicht diese Readings.
singularReadings Verbrauch_Gas:total:Delta:(3h|6h)|Verbrauch_Strom:total:Delta:(3h|6h)
Internals:
CFGFN
DEF Verbrauch_Gas|Verbrauch_Strom
DEV_REGEXP Verbrauch_Gas|Verbrauch_Strom
NAME st_Verbrauch
NR 3904
NTFY_ORDER 10-st_Verbrauch
PREFIX stat
STATE Updated stats for: Verbrauch_Gas
TYPE statistics
CHANGETIME:
Helper:
Dblog:
Statistic value(s) reset:
Mydblog:
TIME 1447589173.31476
VALUE all
Updated stats for:
Mydblog:
TIME 1447760714.09657
VALUE Verbrauch_Gas
Monitoreddevicescul_em:
Mydblog:
TIME 1447545056.6879
VALUE Verbrauch_Gas,Verbrauch_Strom
Readings:
2015-11-15 00:50:56 monitoredDevicesCUL_EM Verbrauch_Gas,Verbrauch_Strom
2015-11-17 11:59:55 nextPeriodChangeCalc 2015-11-17 12:59:55
2015-11-17 12:45:14 state Updated stats for: Verbrauch_Gas
Fhem:
modulVersion $Date: 2015-08-30 13:51:26 +0200 (Sun, 30 Aug 2015) $
Attributes:
excludedReadings Verbrauch_Gas:current|Verbrauch_Strom:current
room 02 Devices,Energie
singularReadings Verbrauch_Gas:total:Delta:(3h|6h)|Verbrauch_Strom:total:Delta:(3h|6h)
Für Gas sieht das dann so aus:
Internals:
BasicFeePerMonth 12
CODE 9
CUL_0_MSGCNT 1504
CUL_0_RAWMSG E0309949E1901009E19
CUL_0_RSSI -75.5
CUL_0_TIME 2015-11-17 12:45:14
CostPerUnit 0.052
DEF 9 0.01 0.12 0.052 12
IODev CUL_0
LASTInputDev CUL_0
MSGCNT 1504
NAME Verbrauch_Gas
NR 214
STATE CNT: 148 CUM: 786.960 5MIN: 0.010 TOP: 0.005
TYPE CUL_EM
corr1 0.01
corr2 0.12
CHANGETIME:
Helper:
Dblog:
Raw:
Mydblog:
TIME 1447760714.10893
VALUE CNT: 148 CUM: 6558 5MIN: 1 TOP: 6558
Cum_day:
Mydblog:
TIME 1447715206.59396
VALUE CUM_DAY: 59.640 CUM: 751.320 COST: 3.10
Current:
Mydblog:
TIME 1447760714.10893
VALUE 0.01
Current_cnt:
Mydblog:
TIME 1447760714.10893
VALUE 1
Stattotal:
Mydblog:
TIME 1447760714.10893
VALUE Hour: 2.64 Day: 35.64 Month: 95.28 Year: 95.28 (since: 2015-11-16 )
Stattotallast:
Mydblog:
TIME 1447757995.06558
VALUE Hour: 3.84 Day: 59.64 Month: - Year: -
Total:
Mydblog:
TIME 1447760714.10893
VALUE 786.96
Total_cnt:
Mydblog:
TIME 1447760714.10893
VALUE 6558
Ur_verbrauch:
Mydblog:
TIME 1447546435.57361
VALUE 0
Ur_verbrauch_sek:
Mydblog:
TIME 1447546435.57361
VALUE 0
Readings:
2015-11-17 12:45:14 RAW CNT: 148 CUM: 6558 5MIN: 1 TOP: 6558
2015-11-17 00:06:46 cum_day CUM_DAY: 59.640 CUM: 751.320 COST: 3.10
2015-11-17 12:45:14 current 0.01
2015-11-17 12:45:14 current_cnt 1
2015-11-17 12:45:14 peak 0.00457456541628545
2015-11-17 12:45:14 peak_cnt 6558
2015-11-17 12:45:14 seqno 148
2015-11-15 13:02:10 statCurrentDay Min: 0.00 Avg: 0.02 Max: 0.17 (since: 2015-11-15_00:50:56 )
2015-11-15 13:02:10 statCurrentMonth Min: 0.00 Avg: 0.02 Max: 0.17 (since: 2015-11-15_00:50:56 )
2015-11-15 13:02:10 statCurrentYear Min: 0.00 Avg: 0.02 Max: 0.17 (since: 2015-11-15_00:50:56 )
2015-11-17 12:45:14 statTotal Hour: 2.64 Day: 35.64 Month: 95.28 Year: 95.28 (since: 2015-11-16 )
2015-11-17 11:59:55 statTotalLast Hour: 3.84 Day: 59.64 Month: - Year: -
2015-11-17 12:45:14 state CNT: 148 CUM: 786.960 5MIN: 0.010 TOP: 0.005
2015-11-17 12:45:14 total 786.96
2015-11-17 12:45:14 total_cnt 6558
2015-11-17 12:45:14 tsecs 1447760714
Helper:
_98_statistics st_Verbrauch
Ein "statTotal" bekomme ich, aber eben nicht die Delta für 3 und 6 Stunden. Kann mir einer bitte auf die Sprünge helfen!
Zusatzfrage: "current" wollte ich ausschließen, muss ich jetzt noch die readings deleten ?
danke
Jürgen
ich vermute, dass die zeitangaben 1h,2h,3h,6h nur für tendency readings gültig sind. schau mal in der commandref unter der beschreibung der 4 statistic-gruppen.
vermutlich funktioniert für Delta nur Hour, Day, Month und Year.
Hallo Frank
vielen Dank für deine Antwort. In der coomand-ref steht jedoch explitit
ZitatZeitraum: Hour|Day|Month|Year|1h|2h|3h|6h
. In anderen Forenbeiträgen habe ich diese Einstellung auch gefunden. Meistens aber auch unbeantwortet.
Ich habe im Laufe des Tages das folgende Attribut zusätzlich definiert
ZitattendencyReadings total
und siehe da, ich bekomme neue readings
ZitatstatTotalTendency 1h: +2.28 2h: +3.72 3h: +6.00 6h: -
.
Dann habe ich jetzt einmal den Statistiktyp "Delta" durch "Tendency" ersetzt (die beiden sind ja in der command_ref "blau" markiert. Mal sehen was passiert. Ich werde berichten.
nun bin ich eine kleinen Schritt schlauer, Einzelwerte werden jetzt gespeichert s.u.
Das heißt für mich:
- zusätzliche Zeitintervalle (alle) werden in einem zusätzlichen Reading durch das Attribut tendencyReadings geschrieben
- eine Auswahl dieser Werte kann dann als jeweils 1 zusätzliches Reading durch das Attribut singularReadings geschrieben werden. Dafür ist der Statistiktyp Tendency erforderlich