From 2ecb4df4521744435ed599d4602cd06b5499771a Mon Sep 17 00:00:00 2001 From: premultiply <4681172+premultiply@users.noreply.github.com> Date: Mon, 8 Jan 2024 22:19:51 +0100 Subject: [PATCH] sma-hybrid: fix pv power --- templates/definition/meter/sma-hybrid.yaml | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/templates/definition/meter/sma-hybrid.yaml b/templates/definition/meter/sma-hybrid.yaml index 8311d35bd..be7bb9f8d 100644 --- a/templates/definition/meter/sma-hybrid.yaml +++ b/templates/definition/meter/sma-hybrid.yaml @@ -26,12 +26,20 @@ render: | type: custom {{- if eq .usage "pv" }} power: - source: modbus - {{- include "modbus" . | indent 2 }} - register: - address: 30773 # SMA Modbus Profile: DcMs.Watt - type: input - decode: int32nan + source: calc + add: + - source: modbus + {{- include "modbus" . | indent 6 }} + register: # manual non-sunspec register configuration + address: 30773 # SMA Modbus Profile: DC power input [1] + type: holding + decode: int32nan + - source: modbus + {{- include "modbus" . | indent 6 }} + register: # manual non-sunspec register configuration + address: 30961 # SMA Modbus Profile: DC power input [2] + type: holding + decode: int32nan energy: source: modbus {{- include "modbus" . | indent 2 }}