helgeerbe / OpenDTU-OnBattery

Software for ESP32 to talk to Hoymiles Inverters and Victrons MPPT battery chargers (Ve.Direct)
GNU General Public License v2.0
290 stars 62 forks source link

[Request] Reset Victron (MPPT) Values to 0 at night if Victron is off #188

Open Adminius opened 1 year ago

Adminius commented 1 year ago

Is your feature request related to a problem? Please describe.

since yesterday Victron was off because of no solar and empty battery (bms turned off) whole night, MQTT had (retained) H20=1,2 kWh ("kWh today" from yesterday). Since this morging around 6:00 Victron is up and running an produced 20+ Wh Telegraf saved this from MQTT to InfluxDB and Grafana shows 1,2 kWh today (max()). last() has some troubles on last days that's why I'm using max(). Nevertheless, 1.2 kWh should be reseted an 0:00 if Victron is not available, so that values does make sense again.

Describe the solution you'd like

H20 (or better all) should be reseted an 0:00 if Victron is not avaliable (e.g. last seen more then 10(?) minutes), so that values does make sense again. 0 Values an 0:00 make more sense than "old" values from the day before.

Describe alternatives you've considered

No response

Additional context

No response

Squint5471 commented 1 week ago

Can this also be the reason for this problem in energy dashboard of Home Assistant that shows Victron MPPT data?

grafik
chrisBer31 commented 1 week ago

Victron mppt reset itself the value of H20 between midnight and 3 am it is variable. We need to reset by sending a command to the mppt via ve direct protocol.

schlimmchen commented 1 week ago

This about values retained in OpenDTU-OnBattery internally, even though the charge controller is not sending data for hours. It makes sense that we need to reset them in those cases.