Skip to content

Add support for SolarEdge ESS PV hybrid inverters#3571

Open
timo-schlegel wants to merge 16 commits intoOpenEMS:developfrom
timo-schlegel:feature/SolarEdgeEss
Open

Add support for SolarEdge ESS PV hybrid inverters#3571
timo-schlegel wants to merge 16 commits intoOpenEMS:developfrom
timo-schlegel:feature/SolarEdgeEss

Conversation

@timo-schlegel
Copy link
Contributor

Adds compatibility for SolarEdge ESS PV hybrid inverters (single-phase and three-phase models).
E.g. SolarEdge SE4000 with SESTI interface or SolarEdge SE10K-RWS.

…ase ignoreImpossibleMinPower limit to 50 watts
…while partially feeding the PV into the grid.

This takes into account the discharge efficiency factor for converting DC to AC and avoids or minimizes grid consumption.
If the ESS is operating in cluster mode and the battery is currently idle, the Smart Mode implementation has switched the inverter to Auto mode if the other ESS reaches exactly 0 grid power.
Sets the minimum charge power to minimum discharge, when force discharge is required
Consideration of the inverter AC limitation in the calculation
General code cleanup to make the difference between AC and battery charge/discharge power more transparent
Revert to the old logic and use an average calculation. Optimize the calculation using delayed values from DC power.
Reason: Because the inverter has an outdated value for battery power, the calculator incorrectly reports PV production when there is no PV production (when the battery power changes). This leads to incorrectly reported PV production at night. Using a 120-second average avoids this situation.
Use reverse calculation from PV production instead of dcBatteryActualPower as battery power values are outdated, because the inverter has to retrieve the value from the SESTI interface.
Decrease or increase battery charge by DISCHARGE_EFFICIENCY_FACTOR to Power which has to be DC-AC-Converted only (instead of using all DC power for calculation)
@codecov
Copy link

codecov bot commented Feb 18, 2026

Codecov Report

❌ Patch coverage is 55.68182% with 351 lines in your changes missing coverage. Please review.

❌ Your patch check has failed because the patch coverage (55.69%) is below the target coverage (75.00%). You can increase the patch coverage or adjust the target coverage.

Additional details and impacted files
@@              Coverage Diff              @@
##             develop    #3571      +/-   ##
=============================================
- Coverage      59.41%   58.54%   -0.86%     
+ Complexity       105      104       -1     
=============================================
  Files           3069     3112      +43     
  Lines         133076   134982    +1906     
  Branches        9815     9932     +117     
=============================================
- Hits           79049    79017      -32     
- Misses         51045    53022    +1977     
+ Partials        2982     2943      -39     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@timo-schlegel
Copy link
Contributor Author

@sfeilmeier, as requested at https://community.openems.io/t/asking-for-feedback-new-modbusworker-implementation/1747/6?u=mrt, please find my SolarEdge ESS implementation here.

The Checkstyle test fails due to incorrect naming in SolarEdgeSunSpecModel, which uses the same naming as DefaultSunSpecModel. The purpose of SolarEdgeSunSpecModel is to provide the DefaultSunSpecModel without events, as these cause warnings when using the SunSpec model with SolarEdge (either with my implementation or with the included SolarEdge PV inverter implementation). Would it make sense to remove the events from the DefaultSunSpecModel instead of defining a modified model?

@sfeilmeier
Copy link
Contributor

The Checkstyle test fails due to incorrect naming in SolarEdgeSunSpecModel, which uses the same naming as DefaultSunSpecModel. The purpose of SolarEdgeSunSpecModel is to provide the DefaultSunSpecModel without events, as these cause warnings when using the SunSpec model with SolarEdge (either with my implementation or with the included SolarEdge PV inverter implementation). Would it make sense to remove the events from the DefaultSunSpecModel instead of defining a modified model?

Thank you!

  1. We already have a bundle for SolarEdge - please move your code there: https://github.com/OpenEMS/openems/tree/develop/io.openems.edge.solaredge

  2. Yes, I see this also with SolarEdge PV inverters, that all Events are active. Can you find out if the Events are just inverted (i.e. set to 0 if Event is active) or are they just not supported by SolarEdge? I would definitely not just copy the file, but instead add a parameter that disables or inverts the Events.

Copy link
Contributor

@sfeilmeier sfeilmeier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See above

@timo-schlegel
Copy link
Contributor Author

@sfeilmeier
According to the SolarEdge SunSpec Technical Note:
https://knowledge-center.solaredge.com/sites/kc/files/sunspec-implementation-technical-note.pdf

Events are only supported for the meter models (e.g. SunSpec models 201–204).

For the Multiple MPPT Inverter Extension Model (160), events are explicitly marked as not supported.
For the standard inverter models (which we use for SolarEdge inverters — models 101, 102, 103), events are not listed at all in the Modbus register mapping.

Based on this documentation, I assume that events are simply not supported for the inverter models (101–103), rather than being inverted.

I agree that copying the file is not the best approach. Adding a parameter to disable event handling makes sense. However, I am currently not sure at which level this parameter should be introduced.

… and perform cleanup

- Introduced FilteredSunSpecModel
- Removed SolarEdgeSunSpecModel
- Updated SolarEdgePvInverter to filter unsupported events
- Reorganized packages
- Removed unused enums
@timo-schlegel
Copy link
Contributor Author

@sfeilmeier
I updated the implementation and pushed a new commit.

The code was moved to the existing SolarEdge bundle as suggested. Instead of copying or modifying DefaultSunSpecModel, I introduced a small wrapper (FilteredSunSpecModel) that allows excluding specific SunSpecPoints from an existing model. This way the generic DefaultSunSpecModel can still be reused unchanged, while the SolarEdge implementation can disable the unsupported event registers.

In the same change, I also fixed the existing SolarEdgePvInverter implementation to use the filtered model so that the unsupported event registers no longer cause warnings.

Could you please have another look and let me know if this approach fits better with the intended design?

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants