Custom Component: SolarEdge Modbus TCP

502 is in the inverter
connection wired

connected with anything else to the modbus interface of the inverter?
The SolarEdge does only allow one client connection being active on that interface.

1 Like

No other connectionsā€¦

In the full log I found:

2023-01-10 22:54:26.088 WARNING (SyncWorker_2) [homeassistant.loader] We found a custom integration solaredge_modbus which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant

wow, if you need more than one Modbus TCP connection, you should use this addon:

Modbus Proxy

thatā€™s why I asked if there is anything else that connects to your inverter :slight_smile:
But since you mentioned, that there are no other connections, I did not recommend the Modbus Proxyā€¦
(which can be run as HA Addon - or standalone)ā€¦

1 Like

Hi, does anyone knows how often solaredge updates its meter values? Iā€™m polling every second and I see changes in values only every 5 seconds. Is this limitation on the solaredge side?

I poll /3 sec with the integration and it updates that often. Looking at the SolarEdge app it is faster than 5 seconds even on that.

yes, inverter values are updating frequently, but the meter (external meter connected to inverter via modbus) values under m1_* are updated only every 5 sec.

is it a solar edge meter?
It might be, that the meeter does have a different update intervallā€¦

I have Inepro pro380 modbus meter. The meter probably has high enough sampling rate, but the Solaredge registers get updated less frequently. Donā€™t know, just guessing.

https://ineprometering.com/wp-content/uploads/2019/04/PRO380-user-manual-V2.18v6.pdf#PRO380%20user%20manual%20V2.18.indd%3A.24565%3A1660

I donā€™t know this device, but thereā€™s a section on how to change the S0 Output rateā€¦

7.10 S0 output rate
The energy meter is equipped with two pulse outputs (forward and reverse) which are optically isolated from the
inside circuit. It generates pulses in proportion to the measured consumption for purpose of remote reading or accuracy
testing. The pulse output is a polarity dependent, open-collector transistor output requiring an external voltage source
for correct operation. For this external voltage source, the voltage (Ui) should be lower than 27V DC. The maximum
switching current (Imax) is 100mA. To connect the impulse output, connect 5-27V DC to connector 18/20 (collector),
and the signal wire (S) to connector 19/21 (emitter). PRO380-CT only: the S0 pulses are always based on CT ratio 5/5.

7.10.1 How to change the S0 output rate
ā€¢ Scroll with the buttons to Program mode 3.
ā€¢ Hold the right button for 3 seconds to enter the menu.
ā€¢ Enter the 4 digit password: scroll with the buttons and select each digit 0-9, hold the right button for 3 seconds
to confirm each digit.
ā€¢ Scroll to LCD page S0 output (S0 xxxxxx).
ā€¢ Hold the right button for 5 seconds to enter program mode.
ā€¢ The value starts blinking: select 10.000/2.000/1.000/100/10/1/0,1/0,01.
ā€¢ Confirm the new setting by holding both buttons for 3 seconds.
ā€¢ The LCD will show SET OK when the setting is confirmed.

thanks for investigating, but the pulse output is I think some different, similar to a blinking led which indicates consumption. Iā€™m reading data from Solaredge Modbus over TCP

Sorry - I wasnā€™t checking what exactly the S0 ā€œoutputā€ is related to.
It was the only area where I could find something about changing the output rate.

Iā€™m aware that you are reading the data from the SolarEdge Inverter - the question here is: does the inverter limit the update frequency, does the inverter get the updates every x seconds from the meter - is there (maybe) a difference between solaredge meters and third party devices - or can this be changed by settings?

Honestly speaking: I donā€™t really care about update frequencies in that small time frameā€¦
Iā€™ve configured the update frequency round about once every 30 secondsā€¦ thatā€™s enough to provide a pretty good monitoringā€¦
Also, I only have solaredge metersā€¦

I have EV charger whose load balancing isnā€™t working ok, so I was trying to use meter values to limit EV chargerā€™s current if goes over my power limit.

hmā€¦ but do you really require to change the load balancing of your EV charger in a second interval?

For example:
My EV charger can switch between Solar Produced Energy - and Net Import.
In case that the Energy from Solar isnā€™t enough - or drop below a specific threshold, the Charger will stop charging.

But:
You should also consider that the Solar could just drop for a few Seconds or minutes due to clouds - in which case, I donā€™t want to do a ā€œstop / start / stop / startā€ pattern.

So I would consider a 5second update Interval should still be pretty straight for such devices.

Solar has no role here, I just want to limit power usage of the whole house (charger), to prevent the breaker to flip off. For this, I would need even higher than a second refresh rate. Hopefully, the charger manufacturer will fix this soon, so I wonā€™t have to.

@squidnuts couple years late to the convo - but did you get an answer to this or figure it out? iā€™ve got the same inverter (2 of them) and Iā€™m not finding any great solutions to getting the data that i know is available on the solaredge monitoring website.

Good morning,

I installed ā€œSolarEdge modbusā€ but I have some problems to receive information from my installation. I have a se5000h inverter without battery, I was able to connect via wifi (http://172.16.0.1) and I enabled the modbus TCP. I found the ip address and added the element in home assistant but all the sensors go back ā€œunknowā€:


I tried the ā€œmodbus adressā€ 1 and 2 and with the ā€œRead meter 1 data (only for meter models)ā€ checked or not. But with no result

After update to HA core 2023.9.1


Logger: homeassistant.loader
Source: custom_components/solaredge_modbus/__init__.py:12
Integration: solaredge_modbus (documentation)
First occurred: 19:27:18 (1 occurrences)
Last logged: 19:27:18

Unexpected exception importing component custom_components.solaredge_modbus
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/loader.py", line 818, in get_component
    ComponentProtocol, importlib.import_module(self.pkg_path)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/config/custom_components/solaredge_modbus/__init__.py", line 12, in <module>
    from pymodbus.payload import BinaryPayloadDecoder
  File "/usr/local/lib/python3.11/site-packages/pymodbus/payload.py", line 28, in <module>
    class BinaryPayloadBuilder:
  File "/usr/local/lib/python3.11/site-packages/pymodbus/payload.py", line 42, in BinaryPayloadBuilder
    self, payload=None, byteorder=Endian.Little, wordorder=Endian.Big, repack=False
                                  ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/enum.py", line 784, in __getattr__
    raise AttributeError(name) from None
AttributeError: Little

I canā€™t seem to connect to the inverter. I tried connecting to the WiFi hotspot, but then I get a message that the password is invalid.

And when I try it via the QR code it does not recognize it.

Then I tried putting in the information myself, but then I get a message that it is unable to join the network.

What should I do at this point?