Probleme mit Einbindung SolarForecast

Begonnen von MarvinLu, 01 Juli 2025, 06:59:19

Vorheriges Thema - Nächstes Thema

DS_Starter

Du könntest ctrlDebug=collectData anschalten. Es werden allerdings sehr viele Daten ins Log geschrieben.
Es gibt einen Part wo die Anteile an Lieferung und Verbrauch sichtbar werden:

...
2025.07.14 20:29:35.555 1: SolCast DEBUG> EnergyConsumption input -> PV: 173, PP: 0, GridIn: 0, GridCon: 13, BatIn: 0, BatOut: 105
2025.07.14 20:29:35.556 1: SolCast DEBUG> EnergyConsumption result -> 291 Wh
...

Vllt. hilft dir das festzustellen ob möglicherweise ein Anteil fehlt oder nicht wie erwartet geliefert wird.

Grüße,
Heiko
Proxmox+Debian+MariaDB, PV: SMA, Victron MPII+Pylontech+CerboGX
Maintainer: SSCam, SSChatBot, SSCal, SSFile, DbLog/DbRep, Log2Syslog, SolarForecast,Watches, Dashboard, PylonLowVoltage
Kaffeekasse: https://www.paypal.me/HMaaz
Contrib: https://svn.fhem.de/trac/browser/trunk/fhem/contrib/DS_Starter

MarvinLu

#16
Hallo Heiko,

gesagt, getan.

Hier einmal der Auszug zum Zeitpunkt eines fehlerhaften Bereiches:

2025.07.15 18:45:01 1: SolarForecast DEBUG> collect Inverter 01 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:01 1: SolarForecast DEBUG> pvOut: 3089 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 4712000 Wh
2025.07.15 18:45:01 1: SolarForecast DEBUG> collect Inverter 02 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:01 1: SolarForecast DEBUG> pvOut: 3396 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 1245000 Wh
2025.07.15 18:45:01 1: SolarForecast DEBUG> collect Inverter 03 data - device: NR_PV_Anlage, source: bat, delivery: default =>
2025.07.15 18:45:01 1: SolarForecast DEBUG> pvOut: 0 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 153 W, etotal: 0 Wh
2025.07.15 18:45:01 1: SolarForecast DEBUG> summary data of all Inverters - pv: 6485 W, this hour Generation: 4000 Wh
2025.07.15 18:45:01 1: SolarForecast DEBUG> State of Plant derating: 0, info: reductionState not set
2025.07.15 18:45:01 1: SolarForecast DEBUG> currently saved 'pvrlvd' value: 1
2025.07.15 18:45:01 1: SolarForecast DEBUG> current percentage pvrl/pvapifc deviation of hod 19: 108.4 % -> pvrlvd: 1
2025.07.15 18:45:01 1: SolarForecast DEBUG> collect Meter data - device: NR_PV_Anlage =>
2025.07.15 18:45:01 1: SolarForecast DEBUG> gcon: 0 W, gfeedin: 5436 W, contotal: 1852000 Wh, feedtotal: 4182000 Wh
2025.07.15 18:45:01 1: SolarForecast DEBUG> collect Battery Readings data: device=NR_PV_Anlage =>
2025.07.15 18:45:01 1: SolarForecast DEBUG> pin: 0 W, pout: 153 W, totalin: 131000 Wh, totalout: 108000 Wh, soc: 98
2025.07.15 18:45:01 1: SolarForecast DEBUG> EnergyConsumption input -> PV: 4000, PP: 0, GridIn: 4000, GridCon: 0, BatIn: 0, BatOut: 0
2025.07.15 18:45:01 1: SolarForecast DEBUG> EnergyConsumption result -> 0 Wh
2025.07.15 18:45:06 1: SolarForecast DEBUG> collect Inverter 01 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:06 1: SolarForecast DEBUG> pvOut: 3029 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 4712000 Wh
2025.07.15 18:45:06 1: SolarForecast DEBUG> collect Inverter 02 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:06 1: SolarForecast DEBUG> pvOut: 3255 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 1245000 Wh
2025.07.15 18:45:06 1: SolarForecast DEBUG> collect Inverter 03 data - device: NR_PV_Anlage, source: bat, delivery: default =>
2025.07.15 18:45:06 1: SolarForecast DEBUG> pvOut: 0 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 98 W, etotal: 0 Wh
2025.07.15 18:45:06 1: SolarForecast DEBUG> summary data of all Inverters - pv: 6284 W, this hour Generation: 4000 Wh
2025.07.15 18:45:06 1: SolarForecast DEBUG> State of Plant derating: 0, info: reductionState not set
2025.07.15 18:45:06 1: SolarForecast DEBUG> currently saved 'pvrlvd' value: 1
2025.07.15 18:45:06 1: SolarForecast DEBUG> current percentage pvrl/pvapifc deviation of hod 19: 108.4 % -> pvrlvd: 1
2025.07.15 18:45:06 1: SolarForecast DEBUG> collect Meter data - device: NR_PV_Anlage =>
2025.07.15 18:45:06 1: SolarForecast DEBUG> gcon: 0 W, gfeedin: 5365 W, contotal: 1852000 Wh, feedtotal: 4182000 Wh
2025.07.15 18:45:06 1: SolarForecast DEBUG> collect Battery Readings data: device=NR_PV_Anlage =>
2025.07.15 18:45:06 1: SolarForecast DEBUG> pin: 0 W, pout: 98 W, totalin: 131000 Wh, totalout: 108000 Wh, soc: 98
2025.07.15 18:45:06 1: SolarForecast DEBUG> EnergyConsumption input -> PV: 4000, PP: 0, GridIn: 4000, GridCon: 0, BatIn: 0, BatOut: 0
2025.07.15 18:45:06 1: SolarForecast DEBUG> EnergyConsumption result -> 0 Wh
2025.07.15 18:45:11 1: SolarForecast DEBUG> collect Inverter 01 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:11 1: SolarForecast DEBUG> pvOut: 2795 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 4712000 Wh
2025.07.15 18:45:11 1: SolarForecast DEBUG> collect Inverter 02 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:11 1: SolarForecast DEBUG> pvOut: 3157 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 1245000 Wh
2025.07.15 18:45:11 1: SolarForecast DEBUG> collect Inverter 03 data - device: NR_PV_Anlage, source: bat, delivery: default =>
2025.07.15 18:45:11 1: SolarForecast DEBUG> pvOut: 0 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 93 W, etotal: 0 Wh
2025.07.15 18:45:11 1: SolarForecast DEBUG> summary data of all Inverters - pv: 5952 W, this hour Generation: 4000 Wh
2025.07.15 18:45:11 1: SolarForecast DEBUG> State of Plant derating: 0, info: reductionState not set
2025.07.15 18:45:11 1: SolarForecast DEBUG> currently saved 'pvrlvd' value: 1
2025.07.15 18:45:11 1: SolarForecast DEBUG> current percentage pvrl/pvapifc deviation of hod 19: 108.4 % -> pvrlvd: 1
2025.07.15 18:45:11 1: SolarForecast DEBUG> collect Meter data - device: NR_PV_Anlage =>
2025.07.15 18:45:11 1: SolarForecast DEBUG> gcon: 0 W, gfeedin: 5684 W, contotal: 1852000 Wh, feedtotal: 4182000 Wh
2025.07.15 18:45:11 1: SolarForecast DEBUG> collect Battery Readings data: device=NR_PV_Anlage =>
2025.07.15 18:45:11 1: SolarForecast DEBUG> pin: 0 W, pout: 93 W, totalin: 131000 Wh, totalout: 108000 Wh, soc: 98
2025.07.15 18:45:11 1: SolarForecast DEBUG> EnergyConsumption input -> PV: 4000, PP: 0, GridIn: 4000, GridCon: 0, BatIn: 0, BatOut: 0
2025.07.15 18:45:11 1: SolarForecast DEBUG> EnergyConsumption result -> 0 Wh
2025.07.15 18:45:16 1: SolarForecast DEBUG> collect Inverter 01 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:16 1: SolarForecast DEBUG> pvOut: 2780 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 4712000 Wh
2025.07.15 18:45:16 1: SolarForecast DEBUG> collect Inverter 02 data - device: NR_PV_Anlage, source: pv, delivery: default =>
2025.07.15 18:45:16 1: SolarForecast DEBUG> pvOut: 3150 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 0 W, etotal: 1245000 Wh
2025.07.15 18:45:16 1: SolarForecast DEBUG> collect Inverter 03 data - device: NR_PV_Anlage, source: bat, delivery: default =>
2025.07.15 18:45:16 1: SolarForecast DEBUG> pvOut: 0 W, pvIn: 0 W, AC->DC: 0 W, DC->AC: 373 W, etotal: 0 Wh
2025.07.15 18:45:16 1: SolarForecast DEBUG> summary data of all Inverters - pv: 5930 W, this hour Generation: 4000 Wh
2025.07.15 18:45:16 1: SolarForecast DEBUG> State of Plant derating: 0, info: reductionState not set
2025.07.15 18:45:16 1: SolarForecast DEBUG> currently saved 'pvrlvd' value: 1
2025.07.15 18:45:16 1: SolarForecast DEBUG> current percentage pvrl/pvapifc deviation of hod 19: 108.4 % -> pvrlvd: 1
2025.07.15 18:45:16 1: SolarForecast DEBUG> collect Meter data - device: NR_PV_Anlage =>
2025.07.15 18:45:16 1: SolarForecast DEBUG> gcon: 0 W, gfeedin: 5113 W, contotal: 1852000 Wh, feedtotal: 4182000 Wh
2025.07.15 18:45:16 1: SolarForecast DEBUG> collect Battery Readings data: device=NR_PV_Anlage =>
2025.07.15 18:45:16 1: SolarForecast DEBUG> pin: 0 W, pout: 373 W, totalin: 131000 Wh, totalout: 108000 Wh, soc: 98
2025.07.15 18:45:16 1: SolarForecast DEBUG> EnergyConsumption input -> PV: 4000, PP: 0, GridIn: 4000, GridCon: 0, BatIn: 0, BatOut: 0
2025.07.15 18:45:16 1: SolarForecast DEBUG> EnergyConsumption result -> 0 Wh

Ich hoffe sehr, dass das ggf. hilft, das Problem zu finden....

EDIT:
Wenn ich dazu einfach mal ChatGPT befrage und versuche mit möglichst detallierten Informationen zu füttern schlägt er mir im wesentlichen diese Dinge zur Lösung vor:

1. Überprüfe die Zuordnung in SolarForecast
Stelle sicher, dass:
das Device (NR_PV_Anlage) einen Meter-Abschnitt mit Grid Consumption korrekt liefert,
oder, falls dein Setup keinen Grid-Verbrauchssensor hat (sondern nur Einspeisung), dass der Verbrauch korrekt aus pv + gfeedin – batout etc. errechnet wird.

2. Option EnergySourceFallback aktivieren
Falls deine Anlage keinen echten Verbrauchszähler hat (z. B. wie bei Victron, wo gcon oft 0 ist), kannst du in der Konfiguration folgendes setzen:

attr <DeinSolarForecastDevice> EnergySourceFallback yes

Das zwingt das Modul dazu, den Verbrauch zu berechnen, auch wenn GridCon = 0 ist.

3. Custom-Mapping überprüfen
Wenn du eigene Datenquellen per ReadingMap einbindest, prüfe, ob z. B. GridCon falsch zugeordnet ist oder leer bleibt.

Viele Grüße,
Marvin

DS_Starter

Hallo Marvin,

leider sieht man nur die Energien.
Wir brauchen aber die Leistungsanteile. Deswegen habe ich eine neue Version eingecheckt, die diese Infos im Debug mit liefert. Im Log sieht man dann:

...
2025.07.18 21:51:09.804 1: SolCast DEBUG> current Power values -> PV2Node: 0 W, PV2Grid: 0, Other: 0 W, GridIn: 0 W, GridCon: 33 W, BatIn: 0 W, BatOut: 642 W
2025.07.18 21:51:09.804 1: SolCast DEBUG> current Consumption result -> 675 W

Es sind die aktuellen Leistungsanteile aufgeführt aus denen sich der aktuelle Verbrauch berechnet.

Die Version ist morgen früh im Regelupdate und auch in meinem contrib enthalten.

LG,
Heiko
Proxmox+Debian+MariaDB, PV: SMA, Victron MPII+Pylontech+CerboGX
Maintainer: SSCam, SSChatBot, SSCal, SSFile, DbLog/DbRep, Log2Syslog, SolarForecast,Watches, Dashboard, PylonLowVoltage
Kaffeekasse: https://www.paypal.me/HMaaz
Contrib: https://svn.fhem.de/trac/browser/trunk/fhem/contrib/DS_Starter

MarvinLu

Guten Morgen Heiko,
Update ist drauf, debug läuft.
Melde mich.
Vielen Dank für deinen Support!!
VG Marvin

MarvinLu

Guten Morgen,

hier dann mal ein Auszug aus dem Log zu den von dir genannten Dingen.

2025.07.19 09:32:21 1: SolarForecast DEBUG> current Power values -> PV2Node: 5282 W, PV2Grid: 0, Other: 0 W, GridIn: 1366 W, GridCon: 0 W, BatIn: 3420 W, BatOut: 0 W
2025.07.19 09:32:21 1: SolarForecast DEBUG> current Consumption result -> 496 W
2025.07.19 09:32:26 1: SolarForecast DEBUG> current Power values -> PV2Node: 5115 W, PV2Grid: 0, Other: 0 W, GridIn: 1635 W, GridCon: 0 W, BatIn: 3378 W, BatOut: 0 W
2025.07.19 09:32:26 1: SolarForecast DEBUG> current Consumption result -> 102 W
2025.07.19 09:32:31 1: SolarForecast DEBUG> current Power values -> PV2Node: 5461 W, PV2Grid: 0, Other: 0 W, GridIn: 2272 W, GridCon: 0 W, BatIn: 3296 W, BatOut: 0 W
2025.07.19 09:32:31 1: SolarForecast DEBUG> current Consumption result -> -107 W
2025.07.19 09:32:36 1: SolarForecast DEBUG> current Power values -> PV2Node: 5524 W, PV2Grid: 0, Other: 0 W, GridIn: 2678 W, GridCon: 0 W, BatIn: 2938 W, BatOut: 0 W
2025.07.19 09:32:36 1: SolarForecast DEBUG> current Consumption result -> -92 W
2025.07.19 09:32:41 1: SolarForecast DEBUG> current Power values -> PV2Node: 5593 W, PV2Grid: 0, Other: 0 W, GridIn: 2883 W, GridCon: 0 W, BatIn: 2473 W, BatOut: 0 W
2025.07.19 09:32:41 1: SolarForecast DEBUG> current Consumption result -> 237 W
2025.07.19 09:32:43 1: SolarForecast DEBUG> current Power values -> PV2Node: 5613 W, PV2Grid: 0, Other: 0 W, GridIn: 2883 W, GridCon: 0 W, BatIn: 2251 W, BatOut: 0 W
2025.07.19 09:32:43 1: SolarForecast DEBUG> current Consumption result -> 479 W
2025.07.19 09:32:46 1: SolarForecast DEBUG> current Power values -> PV2Node: 5613 W, PV2Grid: 0, Other: 0 W, GridIn: 2962 W, GridCon: 0 W, BatIn: 2251 W, BatOut: 0 W
2025.07.19 09:32:46 1: SolarForecast DEBUG> current Consumption result -> 400 W
2025.07.19 09:32:51 1: SolarForecast DEBUG> current Power values -> PV2Node: 5601 W, PV2Grid: 0, Other: 0 W, GridIn: 2954 W, GridCon: 0 W, BatIn: 2063 W, BatOut: 0 W
2025.07.19 09:32:51 1: SolarForecast DEBUG> current Consumption result -> 584 W
2025.07.19 09:32:56 1: SolarForecast DEBUG> current Power values -> PV2Node: 5583 W, PV2Grid: 0, Other: 0 W, GridIn: 2920 W, GridCon: 0 W, BatIn: 2029 W, BatOut: 0 W
2025.07.19 09:32:56 1: SolarForecast DEBUG> current Consumption result -> 634 W
2025.07.19 09:33:01 1: SolarForecast DEBUG> current Power values -> PV2Node: 5535 W, PV2Grid: 0, Other: 0 W, GridIn: 2953 W, GridCon: 0 W, BatIn: 1963 W, BatOut: 0 W
2025.07.19 09:33:01 1: SolarForecast DEBUG> current Consumption result -> 619 W
2025.07.19 09:33:06 1: SolarForecast DEBUG> current Power values -> PV2Node: 5553 W, PV2Grid: 0, Other: 0 W, GridIn: 2985 W, GridCon: 0 W, BatIn: 1984 W, BatOut: 0 W

Ich vermute mal, dass die hier negativen Werte die Probleme bereiten?
Rein rechnerisch fehlen die 107 bzw. 92 Watt wenn ich das richtig verstehe?

Viele Grüße,
Marvin

DS_Starter

Hallo Marvin,

ZitatIch vermute mal, dass die hier negativen Werte die Probleme bereiten?

Ja, genau.

Sehen wir uns mal nur dieses Beispiel an:


2025.07.19 09:32:31 1: SolarForecast DEBUG> current Power values -> PV2Node: 5461 W, PV2Grid: 0, Other: 0 W, GridIn: 2272 W, GridCon: 0 W, BatIn: 3296 W, BatOut: 0 W
2025.07.19 09:32:31 1: SolarForecast DEBUG> current Consumption result -> -107 W

Der Inverter erzeugt 5461 W -> zum Knoten, von dort aus aus wird verteilt.
Es werden 2272 W ins Netz eingespeist (GridIn). Das sollte gesetzt sein weil es ein Meßwert des Meters ist (sollte es sein). Bezogen wird nichts.

Nun wird aber auch noch 3296 W in die Batterie hineingeladen. Allein schon schon die Summe aus Netzeinspeisung 2272 W und Batterieladung 3296 W ist mit 5568 W größer als die erzeugte Energie von 5461 W.
Das macht sich dann als negativer Verbrauch bemerkbar, d.h. das Haus "erzeugt" 107 W was natürlich nicht zutrifft. (siehe auch Wiki)

Für mich sieht es weiterhin nach einer Asynchronität aus. Z.B. vllt. ist die Batterieladeleistung nicht mehr so hoch, nur das Batteriedevice hat den geringeren Wert noch nicht geliefert. Oder der Meter liefert noch einen alten (zu hohen) Netzeinspeisewert.
Das ist nun die Kunst herauszufinden und ggf. Gegenmaßnahmen zu ergreifen falls möglich.
Das Modul kann es nicht tun und ist auf den Input angewiesen.

LG,
Heiko

 
 
Proxmox+Debian+MariaDB, PV: SMA, Victron MPII+Pylontech+CerboGX
Maintainer: SSCam, SSChatBot, SSCal, SSFile, DbLog/DbRep, Log2Syslog, SolarForecast,Watches, Dashboard, PylonLowVoltage
Kaffeekasse: https://www.paypal.me/HMaaz
Contrib: https://svn.fhem.de/trac/browser/trunk/fhem/contrib/DS_Starter