I spent more time that I would have liked to playing with the various options and search the web for answers and for this particular inverter it wasn’t exactly clear how to integrate and get the features.
Options:
winet extractor -
This was the simpliest and most robust in my mind, hacs installs an addon and it passes the data via MQTT into home assistant. Disavantages is that you get no control of the inverter and while it “self heals” on firmware changes the variables can change names like they did with the last firmware update where daily became today in the Winet page descriptions.
Modbus -
This one was tricky, its more a configuration with questionable sources for what registers hold what values, upside is this does provide you control of your inverter. I have mine configured via the same Winet wifi port as my winet extractor, the tricky part was that I required a modbus proxy configuration for this to work. Note that the SH10RS has 3 ethernet ports, but only the Winet one (ethernet or wifi) will work, this is different to the other sungrow inverters.
My solution:
I like the Winet extractor its robust and simple to use so i have kept this going for all my read data from the inverter, and I use the modbus proxy for values that don’t appear and control of the inverter, via modbus I can force charge and control the speed of which I charge the battery.
Control:
I haven’t spent along time playing with the controls on the inverter but the main thing I wanted to control is the ability to maximise my solar yield. I have:
12.4kwh of battery capacity
14kw panels
10kw AC + 10kw DC inverter limit
5kw export (single phase) limit
variable loads for HVAC and pool heating (already integrated)
The aim was to increase export while extending the battery charge over a longer period as this is DC coupled it can go above the 10kw inverter limit. This was relatively easy to control using the “Battery max charge power”, I currently have this set to 2kw during the morning so basically the priority is: Load > battery up to 2kw > grid export up to 5kw > battery up to 3kw. (conveniently my inverter for what ever reason will increase the battery charge rate when the export limit is reached it only seems to increase to 1kw higher than the set limit)
Hi,
Would love to know more on your set up for integrating the Sungrow SH10RS. WiNet Extraction works fine but like you id like to control the inverter. The modbus integration worked fine with previous inverter (SH8.0RS) but not this one.
Cheers,
Nick
I had to set up the addon modbus-proxy (you’ll enter the inverter IP for the winet extractor into the proxy)
then you need to make or find a modbus config file (Mkaiser describes this best)
I only really use one function on the modbus which is the rate of charge limit, I did play with the SOC limits of the battery but found the rate of charge to be superior.
This is the only register you need but you can find others if you need (I found them on a facebook post)
- name: SG Battery max charge power Modbus
unique_id: sg_battery_max_charge_power
device_address: !secret sungrow_modbus_slave
address: 33046 # reg 33047
input_type: holding
data_type: uint16
precision: 0
unit_of_measurement: W
device_class: power
state_class: measurement
scale: 10
scan_interval: 10
You could technically just write to this modbus register directly but I followed the approach I found others to use which is to have an input number and two automations:
to write to the register when the input number changes
to write to the input number if the register value changes (basically to keep them both in sync.
I also change my input number to be in kW as that’s the units I use for all power in my HA instance, the raw register is still in W but for sensors you can change them to kW and it will do the conversion for you.
You can see we don’t really hit too much curtailment now as the battery isn’t full until later in the afternoon, we’ve gone from exporting an additional 10-12kWh / day
I’m trying to understand how the connection to the modbus works.
I have the WiNet dongle plugged into the inverter, and I’m currently using NickStallman’s WiNet Extractor to get all the stats.
What is the modbus-proxy addon that you have?
Is the WiNet dongle connecting to this proxy, or the proxy to it?
Do you need to put a switch between the WiNet at the inverter to get at that ethernet connection?
The winet has both thr webpage and modbus via tcp/ip. So the same dongle can work for both.
The modbus-proxy is a ha addon that buffers the data between the inverter and home assistant internal modbus connector.
By configuring the modbus/registers to look at the proxy, the proxy is configured to look at the inverter (winet ip). Then the data should flow back from the inverter to the proxy to the modbus integration.
The winet extractor can continue to operate as it did even while the proxy polls the modbus registers you have configured.
I’ve been using the modbus integration for my SG5.0RS (obviously a different inverter so different registers), but it’s been bulletproof since I’ve set it up (and yes, took a bit of time to read the modbus documentation to get to this point)
Thanks for the cleaned up yaml. Just curious if your winet s hangs after certain days of running these ha integrations? Mine stopes working every few days and need to reset the winet s.
Over wifi I did have some issues initially, so now it’s got ethernet to it. I still experienced the occasional data hang in earlier Home Assistant versions, which required rebooting to resolve, but I hacked around that with this automation:
that would be wildly dependant on what you want to achieve.
I use a template for target charge based off the forecasted remaining for the day (mine has some fudge factors that delay the target charge if the forecast is say higher than 52kwh:
then an automation runs the following SOC > target + 5% : Battery Charge rate = 0.5kw (I could probably drop this to 0.1kw or 100W) SOC < target + 5% : Battery Charge rate = 1.8kw (this was calculated to keep the battery charging at the same rate of climb of my solar forecast declining at my inverter limit (it will be different for different systems eg battery capacity and solar panel limits) SOC < target : Battery Charge rate = 5kw (means if the previous step didn’t keep up then its cloudy and i need to increase the rate) SOC < target - 5% : Battery Charge rate = 8kw (this is the max for my system)