Sungrow Binding

Hey @Holger_FFM & @soenke - I’ve just started using the Sungrow binding a couple of weeks back (working well btw), with a Sungrow SH6.0RS.

Slightly long post, but my experiences with similar below.

I also looked at Max SOC to limit charging, but with a focus to optimize export. It didn’t work the way you might expect it to - at least based on my experience, and appears to be an internal limiter.
If you set Max_SOC to 90% - once it reaches that internal 90% limit - the iSolarCloud & App will show it as 100% charged. Set it back to 100%, and the inverter than shows it as being only at 90% charged. It’s not the behavior I expected either..

I’m in the final stages of finishing what I wanted to do but your use case isn’t all too different.
For me - my focus is on not charging the battery to 100%, and instead exporting on sunny days, but if you’re monitoring spot dynamic rates from supplier, you should be able to adapt my implementation to do what you want.

Below is a little write up of how I’ve done it, but I am considering doing a more in depth write up as it’s own post for anyone else trying to do the same.

Intended Goal

  • Based in New Zealand, and now entering summer whether. My power plan includes 3hrs TOU free power from 9pm → midnight.
  • Instead of fully charging the battery, I only want to charge it to 50 or 60% depending on the whether - then focus on exporting so I can maximize export.
  • After sundown, switch back to battery until 9pm when I can charge it again for free.

Implementation

  • SolarForeCast binding
    • Solcast & ForeCastSolar channels linked
    • Grouped with Aggregate Average to estimate daily generation.
  • Sungrow binding & following channels
    • Battery Level
    • Load Power
    • Total DC Power
  • ModBus Poller Thing Created
    • 60,000ms poll interval
    • Start 13049 (zero indexed 13050 for EMS mode)
    • Length 1
    • Type: Holding Register
  • ModBus Data Thing Created
    • Read Address: 13049
    • Write Address: 13049
    • Write Type: holding register
    • Read/Write MAP transform for 0 = ON, 2 = OFF
    • Channel Linked - Value as Switch - Labelled ‘Solar Self Consumption Mode’
    • The above basically gives you a switch which can turn Self Consumption mode ON or OFF via OH.
  • OH/Blockly Rule Built to:
    • Once PV generation > 0 - trigger rule (noting PV value update set for 60seconds above)
    • First - calculate Target_SOC by comparing forecast generation against an arbitrary list.
      • I have 6 settings, ranging from 100% SOC, down to 50% SOC
        • 11kwh or less - 100% target, then steps the target down 10% for every extra in 2kw generation until 21kwh+ is only 50% target charge.
    • Second - Check if the conditions are met:
      • Battery_SOC is >= Target_SOC
      • AND
      • Load <= PV (to make sure we’re covering at least our present consumption - otherwise it’ll start drawing from the grid)
    • Third - action results of above:
      • if the conditions are met - check Self Consumption switch state <> OFF first, then Command it to OFF.
      • If the conditions are not met - same again - check state first, and then turn self consumption ON (normal operation/draw from battery).

Result

  • Sunny days - once target SOC is hit - unit switches to export
    • Bonus side effect - as the unit is DC Coupled - if the generation exceeds the max export + household load - the unit will automatically divert the surplus to the DC coupled battery
    • So where previously production would have been clipped at maximum AC capacity, it’s now consumed by the DC battery instead = more usable generation
  • General Use - if load exceeds generation - self-consumption mode is turned back on within 60 seconds - so if any high draw items are turned on - ie: oven, dryer, etc - resume normal operation and draw from the battery.
  • Rainy days (less than 11kwh forecast) - SOC target is 100% - it stays in self consumption mode.

Footnotes
The methodology isn’t entirely unique, and I’m 99% sure I have seen others mentioning switching to forced mode - but perhaps I missed or didn’t I didn’t understand was that you can also set the forced mode to be either charge, or discharge, as well as the charge/discharge power level.
So for my set up:
Modbus 13051 (/13050) = 0xBB Hex - Discharge Mode

  • apparently 0xCC is Stop which is default? Might have changed this one by accident during testing, and am now resetting this back to 0xCC to see if it makes any difference.

Modbus 13052 (/13051) = 0 - charge/charge rate = zero

So basically - in forced mode at 0 power rate - it’s not going to draw from the battery once it’s reached the intended SOC target, and similarly not going to export back to the grid. Then once 9pm hits - the forced charge mode that’s set in the inverter kicks in, and it charges it up to 100% before midnight.


Meanwhile whilst I’ve been writing this up - the day started out with Battery_SOC at 53% - so once the sun came up with a forecast for ~40kwh generation - it switched over to forced mode and began exporting. It exported 33.5kwh before we started loosing sun - at which point the battery was up to 65% (surplus charging due to 5kwh export limit), and has automatically switched back to self-consumption mode. :slight_smile:

Edit - just did a write up tutorial including the blockly rules at Sungrow Hybrid Inverter - Target Battery SOC & Optimized Exporting using Modbus

Thx
Jp.