evcc-io/templates/definition/meter/wattsonic.yaml

87 lines
2 KiB
YAML

template: wattsonic
products:
- brand: Wattsonic
- brand: Sunway
- brand: Solinteng
- brand: A-Tronix
- brand: St-ems
capabilities: ["battery-control"]
params:
- name: usage
choice: ["grid", "pv", "battery"]
- name: modbus
choice: ["rs485"]
port: 502
id: 247
delay: 100ms
- name: delay
deprecated: true
- preset: battery-params
render: |
type: custom
{{- if eq .usage "grid" }}
power: # power (W)
source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 11000 # Total Power on Meter
type: holding
decode: int32
scale: -1
powers:
- source: modbus
{{- include "modbus" . | indent 4 }}
register:
address: 10994 # Phase A Power on Meter
type: holding
decode: int32
scale: -1
- source: modbus
{{- include "modbus" . | indent 4 }}
register:
address: 10996 # Phase B Power on Meter
type: holding
decode: int32
scale: -1
- source: modbus
{{- include "modbus" . | indent 4 }}
register:
address: 10998 # Phase C Power on Meter
type: holding
decode: int32
scale: -1
{{- end }}
{{- if eq .usage "pv" }}
power: # power (W)
source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 11028 # PV Input Total Power
type: holding
decode: int32
{{- end }}
{{- if eq .usage "battery" }}
power: # power (W)
source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 40258 # Total_Backup_P
type: holding
decode: int32
soc:
source: modbus
{{- include "modbus" . | indent 2 }}
scale: 0.01
register:
address: 43000 # SOC
type: holding
decode: int16
limitsoc:
source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 52503 # min soc
type: writeholding
encoding: uint16
{{- include "battery-params" . }}
{{- end }}