Skip to content

Add Solinteg Modbus TCP meter template#29543

Merged
andig merged 1 commit intoevcc-io:masterfrom
vargai:fix-solinteg-wattsonic-battery-modbus
May 2, 2026
Merged

Add Solinteg Modbus TCP meter template#29543
andig merged 1 commit intoevcc-io:masterfrom
vargai:fix-solinteg-wattsonic-battery-modbus

Conversation

@vargai
Copy link
Copy Markdown
Contributor

@vargai vargai commented May 1, 2026

Adds a dedicated Solinteg Modbus TCP meter template.

Solinteg inverters are currently grouped under the existing Wattsonic template, but that template is configured for RS485-style defaults. In my setup, Solinteg over Modbus TCP requires Modbus ID 255, and the battery registers differ from the existing Wattsonic template.

This PR adds a separate solinteg template so the TCP configuration can work without changing the existing Wattsonic/RS485 behavior.

Tested locally

Tested with evcc 0.306.0 using Modbus TCP against a Solinteg inverter at port 502.

Working registers:

  • Grid power: 11000, holding, int32, scale -1
  • PV power: 11028, holding, uint32
  • Battery power: 30258, holding, int32
  • Battery SoC: 33000, holding, uint16, scale 0.01
  • Battery minimum SoC: 52503, holding write, uint16, scale 10

Notes

The existing Wattsonic template is left unchanged to avoid affecting RS485 users.

Copy link
Copy Markdown
Contributor

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • Consider making the Modbus id and port configurable parameters (with sensible defaults of 255 and 502) instead of hardcoding them in the modbus preset, to accommodate installations that use different TCP settings.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Consider making the Modbus `id` and `port` configurable parameters (with sensible defaults of 255 and 502) instead of hardcoding them in the `modbus` preset, to accommodate installations that use different TCP settings.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@vargai
Copy link
Copy Markdown
Contributor Author

vargai commented May 1, 2026

These values are already configurable through evcc's Modbus template parameter expansion. The id: 255 and port: 502 entries here only define device-specific defaults for the generated id and port parameters.

Users can still override them, for example:

meters:
  - name: battery
    type: template
    template: solinteg
    usage: battery
    modbus: tcpip
    host: 192.168.1.129
    port: 1502
    id: 1

@premultiply premultiply self-assigned this May 1, 2026
@premultiply premultiply added the devices Specific device support label May 1, 2026
@andig
Copy link
Copy Markdown
Member

andig commented May 1, 2026

Is the delay really needed?

@vargai vargai force-pushed the fix-solinteg-wattsonic-battery-modbus branch from 496682f to c3c3caf Compare May 1, 2026 18:07
@vargai
Copy link
Copy Markdown
Contributor Author

vargai commented May 1, 2026

Good point. The 'delay' parameter was inherited from the Wattsonic template, but it is not needed for Solinteg TCP template.
I removed the 'delay' parameter

@andig andig merged commit 7611aa9 into evcc-io:master May 2, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

devices Specific device support

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants