New Python plugin: Domoticz SolarEdge_ModbusTCP

Moderator: leecollings

AddieJanssen
Posts: 53
Joined: Sunday 27 September 2020 16:17
Target OS: -
Domoticz version:
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by AddieJanssen »

imautohuttraeger wrote: Saturday 10 October 2026 1:01 EDIT: Next morning, when the battery is charged again, it is back to normal again (both status devices show "charge").

Maybe this is a standard behaviour, but I thought it might not be harmful to notify this:

Today is the first day since March (Heavy rain and dark clouds all over the day) ,where my Battery was sucked empty.

Battery1 - State of Energy:
"0"

And I recognized the following findings:

Battery1 - Status:
"Key not found in lookup table: 10"
(normally it is Idle, Charge or Discharge)

Battery1 - Internal Status:
"Fault"
According to the SolarEdge documentation that I have, there's no such status as "10".
However, I looked at a Home Assistant plugin, they list this: 10: "B_STATUS_POWER_SAVING"
They have a whole bunch more information where it is unclear where they got it from, but interesting to have a peek at in the future.
hskip
Posts: 6
Joined: Monday 19 October 2015 21:28
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by hskip »

I ran the scanner again (with the 15-second setting) on ​​the SE3000, no battery.

python scanner.py 192.168.178.77 502
Connecting to server

Connected to server

Looking for SunSpec identifier at address [40000 (0x9c40)] for device [1]
The inverter is providing a SunSpec Map

Reading Block at address [40002 (0x9c42)] for device [1]
ERROR: request ask for transaction_id=2 but got id=1, Skipping.
Block id = [1]
Block length = [65]
=================================================================== DEVICE DETAILS ===================================================================
[id] [1]
[name] [common]
[label] [Common]
[description] [All SunSpec compliant devices must include this as the first model]
-------------------------------------------------------------------- MEASUREMENTS --------------------------------------------------------------------
[id] [Model identifier] [1]
[l] [Model length] [65]
[mn] [Well known value registered with SunSpec for compliance] [SolarEdge ]
[md] [Manufacturer specific value (32 chars)] [SE3000]
[opt] [Manufacturer specific value (16 chars)] []
[vr] [Manufacturer specific value (16 chars)] [0003.2537]
[sn] [Manufacturer specific value (32 chars)] [7F190BC7]
[da] [Modbus device address] [1]


Reading Block at address [40069 (0x9c85)] for device [1]
Block id = [101]
Block length = [50]
=================================================================== DEVICE DETAILS ===================================================================
[id] [101]
[name] [inverter_single_phase]
[label] [Inverter (Single Phase)]
[description] [Include this model for single phase inverter monitoring]
-------------------------------------------------------------------- MEASUREMENTS --------------------------------------------------------------------
[id] [Model identifier] [101]
[l] [Model length] [50]
[a] [AC Current] [0]
[apha] [Phase A Current] [0]
[aphb] [Phase B Current] [NOT_IMPLEMENTED]
[aphc] [Phase C Current] [NOT_IMPLEMENTED]
[a_sf] [] [0]
[ppvphab] [Phase Voltage AB] [230.70] = [2307 * (10**-1)] using scale factor [v_sf]
[ppvphbc] [Phase Voltage BC] [NOT_IMPLEMENTED]
[ppvphca] [Phase Voltage CA] [NOT_IMPLEMENTED]
[phvpha] [Phase Voltage AN] [NOT_IMPLEMENTED]
[phvphb] [Phase Voltage BN] [NOT_IMPLEMENTED]
[phvphc] [Phase Voltage CN] [NOT_IMPLEMENTED]
[v_sf] [] [-1]
[w] [AC Power] [0]
[w_sf] [] [0]
[hz] [Line Frequency] [50.01] = [50013 * (10**-3)] using scale factor [hz_sf]
[hz_sf] [] [-3]
[va] [AC Apparent Power] [0]
[va_sf] [] [0]
[var] [AC Reactive Power] [0]
[var_sf] [] [0]
[pf] [AC Power Factor] [100.00] = [10000 * (10**-2)] using scale factor [pf_sf]
[pf_sf] [] [-2]
[wh] [AC Energy] [41970476.00] = [41970476 * (10**0)] using scale factor [wh_sf]
[wh_sf] [] [0]
[dca] [DC Current] [0]
[dca_sf] [] [0]
[dcv] [DC Voltage] [1.20] = [12 * (10**-1)] using scale factor [dcv_sf]
[dcv_sf] [] [-1]
[dcw] [DC Power] [0]
[dcw_sf] [] [0]
[tmpcab] [Cabinet Temperature] [NOT_IMPLEMENTED]
[tmpsnk] [Heat Sink Temperature] [0]
[tmptrns] [Transformer Temperature] [NOT_IMPLEMENTED]
[tmpot] [Other Temperature] [NOT_IMPLEMENTED]
[tmp_sf] [] [-2]
[st] [Enumerated value. Operating state] [STARTING]
[stvnd] [Vendor specific operating state code] [0]
[evt1] [Bitmask value. Event fields] [NOT_IMPLEMENTED]
[evt2] [Reserved for future use] [NOT_IMPLEMENTED]
[evtvnd1] [Vendor defined events] [0]
[evtvnd2] [Vendor defined events] [NOT_IMPLEMENTED]
[evtvnd3] [Vendor defined events] [NOT_IMPLEMENTED]
[evtvnd4] [Vendor defined events] [0]


Reading Block at address [40121 (0x9cb9)] for device [1]
Block id = [65535]
Block length = [0]
Block type = [The End of the block list has been reached]

End of SunSpec MAP

Looking for Battery at address [57600 (0xe100)] for device [1]
No battery found at this address

Looking for Battery at address [57856 (0xe200)] for device [1]
No battery found at this address

Disconnected from server
User avatar
imautohuttraeger
Posts: 432
Joined: Saturday 14 March 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest
Location: Germany
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by imautohuttraeger »

hskip wrote: Sunday 11 October 2026 22:39 [...] (with the 15-second setting) [...]
Seems I have missed something. What is the "15-second setting"? Shall we other testers run it with this option, too?
Stop, look and listen.
hskip
Posts: 6
Joined: Monday 19 October 2015 21:28
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by hskip »

AddieJanssen wrote: Thursday 08 October 2026 10:24 Are these results from the scanner with the increased timeout?
Please check line 168 of the scanner. It should read:

Code: Select all

line 168: client = ModbusTcpClient(host=args.host, port=args.port, timeout=15)
eddieb
Posts: 431
Joined: Wednesday 04 July 2018 7:48
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Netherlands
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by eddieb »

The github version is correct ...
RPI4 Beta / Tasmota / ZigBee2MQTT / P1meter / Haier AC MQTTmapper / SolarEdge SE3500H modbus_tcp / IndeVolt SF3000 / Opentherm gateway / Plugwise Anna/Smile / ObserverIP weatherstation thru WuDirect
Feeding ADSB https://adsb.im/home
hjzwiers
Posts: 327
Joined: Friday 12 January 2018 8:26
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by hjzwiers »

Have you gotten stuck or something, you started so hopefull?

I looked into the diffences between jvdz's version and yours and why your reaction was so odd, it's this difference:

Code: Select all

  # Set Selector switch level to 0;10;20;30 ....
                        if (unit[Column.ID] == inverters.InverterUnit.STORAGECONTROL ) \
                        or (unit[Column.ID] == inverters.InverterUnit.RCCMDMODE ) \
                        or (unit[Column.ID] == inverters.InverterUnit.STORAGE_AC_CHARGE_POLICY ):
                            sValue = unit[Column.FORMAT].format(value*10)
                            if value > 0:
                                nValue = 2
                            # EXTRATEST = True

i couldnt find these in your version 2.07
AddieJanssen
Posts: 53
Joined: Sunday 27 September 2020 16:17
Target OS: -
Domoticz version:
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by AddieJanssen »

No worries - working on it and so far there are no showstoppers - just running out of time on a daily basis :) We had a heat pump installed and that consumed a lot of time. And every now and then, I need to work as well....
Drilling.jpg
Drilling.jpg (98.77 KiB) Viewed 607 times
Before.jpg
Before.jpg (61.9 KiB) Viewed 607 times
After.jpg
After.jpg (68.21 KiB) Viewed 607 times
User avatar
imautohuttraeger
Posts: 432
Joined: Saturday 14 March 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest
Location: Germany
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by imautohuttraeger »

AddieJanssen wrote: Sunday 25 October 2026 17:37 [...]We had a heat pump installed [...]
Very good decision. I envy you for using energy from the soil. I only a have mine working with the energy of the air. However, even this saved me about 600 € per year compared to the old gas heating. And about 400 € on top that came from the solar panels. So summing up about 1000 €.
Stop, look and listen.
AddieJanssen
Posts: 53
Joined: Sunday 27 September 2020 16:17
Target OS: -
Domoticz version:
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by AddieJanssen »

A quick update on where we are:

I have a first 2.1.x version of the plugin working that does not depend on the solaredge_modbus library of nmakel anymore and allows us to update pymodbus to the latest version.

The updated plugin uses the scan functionality as introduced with the scanner tool that we used here over the last month.
I deployed the new plugin to my test setup just now and will let it run for a few days to see if the results make sense and if it does not crash.
Unless my test shows tons of issues, I am planning to release this version later this week.

This is a major rewrite of the plugin, so for sure not a candidate that you want to copy over your current running plugin.
But more on that later.
User avatar
imautohuttraeger
Posts: 432
Joined: Saturday 14 March 2020 13:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest
Location: Germany
Contact:

Re: New Python plugin: Domoticz SolarEdge_ModbusTCP

Post by imautohuttraeger »

Great news. I think it is about time for me to finally establish a second system for testing apart from the RasPi ;-)

Maybe an old outdated laptop could do this job.
Stop, look and listen.
Post Reply