helgeerbe / OpenDTU-OnBattery

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

[Request] Add support for intermediate meter to measure the outputpower of the inverter #899

Open greymda opened 4 months ago

greymda commented 4 months ago

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

No response

Describe the solution you'd like

Basically the idea comes from the python script https://github.com/reserve85/HoymilesZeroExport (in detail about this option https://github.com/reserve85/HoymilesZeroExport/blob/5b226225a6799eab91857a2c18d21d854c568726/HoymilesZeroExport_Config.ini#L133) and consists on having the (optional) support for an intermediate meter that measures the outputpower of the inverter as it is faster than the DTU current_power value (and possibly more reliable?).

In my particular care I have a Shelly EM with 2 clamps and one monitors the Grid input and the second is measuring the Solar input. I would like to have an option to use the values from the second clamp for Dynamic Power Limit functionality.

Screenshot 2024-04-20 at 21 21 09

Thoughts?

Describe alternatives you've considered

No response

Additional context

No response

schlimmchen commented 4 months ago

We were obviously triggered by different things, but I had this exact idea just moments ago, because it would also appease the 24V battery users.

I would say let's just copy the PowerMeter, name it something else, and if enabled and working, use that value to know the inverter(s) output. Do not wait for new statistics in that case. One can lower the poll frequency and gain more airtime to transmit new limits.

I think this is an awesome idea :+1:

Guess I will add a power meter of some sort when upgrading my setup anyways next week :wink:

Please note, however, that when I write "just copy the PowerMeter", I mean "do the urgently needed refactor of the PowerMeter code base first, have this new feature in mind while doing so, then try to implement this new feature". There will be hiccups, I guess.

greymda commented 4 months ago

looking forward!

greymda commented 4 months ago

@schlimmchen but you got my interest about the 24v battery users. can you elaborate a bit when have some spare time?

schlimmchen commented 4 months ago

spare time

Spare what? :wink:

Start here: https://github.com/helgeerbe/OpenDTU-OnBattery/wiki/24V-Battery-issues-with-Hoymiles

SW-Niko commented 4 months ago

Hello @greymda, I am one of the poor 24VDC battery users 😢 and I really like your idea to use an external power meter to measure the inverter output power. 👍 I see 2 major advantages: