chore: put grid first (#15990)
This commit is contained in:
parent
2d60e6797a
commit
9010545249
2 changed files with 65 additions and 65 deletions
|
|
@ -17,6 +17,32 @@ params:
|
|||
advanced: true
|
||||
render: |
|
||||
type: custom
|
||||
{{- if eq .usage "grid" }}
|
||||
power:
|
||||
source: modbus
|
||||
{{- include "modbus" . | indent 2 }}
|
||||
register:
|
||||
address: 169 # "Total grid power"
|
||||
type: holding
|
||||
decode: int16
|
||||
energy:
|
||||
source: calc
|
||||
add:
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 78 # "Total_GridBuy_PowerWh_low"
|
||||
type: holding
|
||||
decode: uint16
|
||||
scale: 0.1
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 80 # "Total_GridBuy_PowerWh"
|
||||
type: holding
|
||||
decode: uint16
|
||||
scale: 6553.6
|
||||
{{- end }}
|
||||
{{- if eq .usage "pv" }}
|
||||
power:
|
||||
source: calc
|
||||
|
|
@ -79,29 +105,3 @@ render: |
|
|||
decode: uint16
|
||||
capacity: {{ .capacity }} # kWh
|
||||
{{- end }}
|
||||
{{- if eq .usage "grid" }}
|
||||
power:
|
||||
source: modbus
|
||||
{{- include "modbus" . | indent 2 }}
|
||||
register:
|
||||
address: 169 # "Total grid power"
|
||||
type: holding
|
||||
decode: int16
|
||||
energy:
|
||||
source: calc
|
||||
add:
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 78 # "Total_GridBuy_PowerWh_low"
|
||||
type: holding
|
||||
decode: uint16
|
||||
scale: 0.1
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 80 # "Total_GridBuy_PowerWh"
|
||||
type: holding
|
||||
decode: uint16
|
||||
scale: 6553.6
|
||||
{{- end }}
|
||||
|
|
|
|||
|
|
@ -24,6 +24,45 @@ params:
|
|||
advanced: true
|
||||
render: |
|
||||
type: custom
|
||||
{{- if eq .usage "grid" }}
|
||||
power:
|
||||
source: modbus
|
||||
{{- include "modbus" . | indent 2 }}
|
||||
register:
|
||||
address: 30865 # SMA Modbus Profile: Metering.GridMs.TotWIn
|
||||
type: input
|
||||
decode: int32nan
|
||||
energy:
|
||||
source: modbus
|
||||
{{- include "modbus" . | indent 2 }}
|
||||
register:
|
||||
address: 30581 # SMA Modbus Profile: Metering.GridMs.TotWhIn
|
||||
type: holding
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
currents:
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 31435 # SMA Modbus Profile: Metering.GridMs.A.phsA
|
||||
type: input
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 31437 # SMA Modbus Profile: Metering.GridMs.A.phsB
|
||||
type: input
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 31439 # SMA Modbus Profile: Metering.GridMs.A.phsC
|
||||
type: input
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
{{- end }}
|
||||
{{- if eq .usage "pv" }}
|
||||
power:
|
||||
source: calc
|
||||
|
|
@ -145,42 +184,3 @@ render: |
|
|||
decode: uint32
|
||||
capacity: {{ .capacity }} # kWh
|
||||
{{- end }}
|
||||
{{- if eq .usage "grid" }}
|
||||
power:
|
||||
source: modbus
|
||||
{{- include "modbus" . | indent 2 }}
|
||||
register:
|
||||
address: 30865 # SMA Modbus Profile: Metering.GridMs.TotWIn
|
||||
type: input
|
||||
decode: int32nan
|
||||
energy:
|
||||
source: modbus
|
||||
{{- include "modbus" . | indent 2 }}
|
||||
register:
|
||||
address: 30581 # SMA Modbus Profile: Metering.GridMs.TotWhIn
|
||||
type: holding
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
currents:
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 31435 # SMA Modbus Profile: Metering.GridMs.A.phsA
|
||||
type: input
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 31437 # SMA Modbus Profile: Metering.GridMs.A.phsB
|
||||
type: input
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
- source: modbus
|
||||
{{- include "modbus" . | indent 4 }}
|
||||
register:
|
||||
address: 31439 # SMA Modbus Profile: Metering.GridMs.A.phsC
|
||||
type: input
|
||||
decode: int32nan
|
||||
scale: 0.001
|
||||
{{- end }}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue