hoylabs / OpenDTU-OnBattery

Software for ESP32 to talk to Hoymiles/TSUN/Solenso Inverters, VE.Direct devices, battery management systems, and related peripherals
GNU General Public License v2.0
312 stars 66 forks source link

[Request] make DPL adjustment possible with MQTT #1386

Open ThomasCr opened 1 day ago

ThomasCr commented 1 day ago

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

No response

Describe the solution you'd like

It would be nice to make the DPL settings adjustable from Mqtt and so also by Home Assistant. So we can create automations for eg set a lower Minimum Power Limit or a other Maximum Power Limit when you want it.

Describe alternatives you've considered

No response

Additional context

No response

spcqike commented 1 day ago

is this really needed? you allready can set it with http requests, check out the web-api

and keep in mind, that changing the DPL settings will write to flash, as these are persistent settings. so its not helpful to change it several times per day.

anyway, could you describe a usecase, where you need to change the settings every now and then?

ThomasCr commented 1 day ago

As an example, If weather Forcast tells me, we don't get so much sun, I would change the max/min Power Limit, so that the battery can last longer.

But it is good to know, that changes are written to the flash. Maybe implement them as temporary changes on top the permanent ones?

To use the web api we need again to set up a other access method, that's not so nice.

spcqike commented 15 hours ago

well, i think i kind of understand why you would like to change the max setting, but i dont get why you want to change min, too.

on the other hand, seen from energy point of view, it doesn't matter anyway. if you produce like 200W for 4h or 100W for 8h, its still 800Wh.

what do you think would be the benefit of having a ..... say "second and soft max limit" (which could be retrieved by mqtt and is non persistant, so not in eeprom)?

as a workaround, you could "fake" your powermeter reading. if you send this via mqtt and have an automation system like node red or HA (which you need for your forcast related calculation, i guess), you can change the reading to your wishes.

schlimmchen commented 1 hour ago

@ThomasCr What topics/settings are you missing? See the docs.