Skip to content

SolarEdge inverter Modbus TCP timeouts and transaction mismatches #25424

Description

@thwien

Describe the bug

Daily EVCC loose connection to TCP modbus port maybe after running daily inverter isolation test. Increasing timeouts or intervals or using watchdog does not resolve the problem.

My SolarEdge configuration worked over one year without any problem. But after an inverter software update (4.24.9) the described problem begun. I talked to the technical support of our PV installation, but they could not find any reason or error event on the inverter hardware.

Maybe the inverter causes the problem, but maybe EVCC can handle this connection and mismatch errors in another way.

Thanks alot for this great open source project. Keep up your good work.

I would appreciate any suggestion to understand and solve this issue.

Steps to reproduce

Evcc is configured with SolarEdge inverter and connected successfully to communicate with Modbus via TCP on port 502. Everything works many hours and sometimes days as expected until in EVCC it shows errors like "connection refused", "connection timeout" and "response transaction id does not match request". Not always but mostly it is happens while or after daily automated isolation test of the inverter.

If connection is successful, "evcc detect" shows two entries:

sunspec  │ {"IP":"192.168.221.22","Port":502,"ModbusResult":{"SlaveID":1,"Model":1,"Point":"Mn","Value":"SolarEdge "}}

inverter │ {"IP":"192.168.221.22","Port":502,"ModbusResult":{"SlaveID":1,"Model":103,"Point":"W","Value":28945}} 

If connection fails, "evcc detect" shows just one entry:

sunspec │ {"IP":"192.168.221.22","Port":502,"ModbusResult":{"SlaveID":1,"Model":1,"Point":"Mn","Value":"SolarEdge "}

If connection fails, neither restart of EVCC or reboot solves the problem. I have to remove all SolarEdge configuration and wait multiple hours before reconfigure SolarEdge. After multiple hours it works again as expected.

I tested many different timeouts, intervals and watchdog but without any success.

Configuration details

meters:
- type: template
  template: solaredge-hybrid
  id: 1  
  host: 192.168.221.22  
  port: 502  
  usage: grid  
  modbus: tcpip  
  name: grid1
  watchdog: 60s
- type: template
  template: solaredge-hybrid
  id: 1  
  host: 192.168.221.22  
  port: 502  
  usage: pv  
  modbus: tcpip  
  name: pv2
  watchdog: 60s
- type: template
  template: solaredge-hybrid
  id: 1  
  host: 192.168.221.22  
  port: 502  
  usage: battery  
  modbus: tcpip  
  name: battery3
  capacity: 13.8
  watchdog: 60s

site:
  title: Home
  meters:
   grid: grid1
   pv:
   - pv2
   battery:
   - battery3

Log details

evcc[20901]: 2025-11-18 18:49:40.671937886 +0100 CET m=+124365.672457258 !!   2ms add[0]: model 103 block 0 point DCW: dial tcp 192.168.221.22:502: connect: connection refused

evcc[20901]: 2025-11-18 18:49:48.050008393 +0100 CET m=+124373.050527765 !! 3003ms add[0]: model 103 block 0 point DCW: dial tcp 192.168.221.22:502: i/o timeout

evcc[20901]: 2025-11-18 18:50:49.784421582 +0100 CET m=+124434.784940954 !! 1545ms read failed: modbus: response transaction id '56559' does not match request '56561'

What type of operating system or environment does evcc run on?

Linux

External automation

  • I have made sure that no external automation like HomeAssistant or Node-RED is active or accessing any of the mentioned devices when this issue occurs.

Nightly build

  • I have verified that the issue is reproducible with the latest nightly build

Version

evcc version 0.209.8

Metadata

Metadata

Assignees

No one assigned

    Labels

    devicesSpecific device supportstaleOutdated and ready to close

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions