Skip to content

Commit

Permalink
Revert "EM24: add pv usage & fix energy (evcc-io#17173)"
Browse files Browse the repository at this point in the history
This reverts commit 964adbe.
  • Loading branch information
andig committed Nov 16, 2024
1 parent a9d9565 commit 5419b52
Showing 1 changed file with 20 additions and 82 deletions.
102 changes: 20 additions & 82 deletions templates/definition/meter/cg-em24.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,90 +8,28 @@ products:
generic: EM24
params:
- name: usage
choice: ["grid", "charge", "pv"]
choice: ["grid", "charge"]
- name: modbus
choice: ["rs485", "tcpip"]
render: |
type: custom
power:
source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x28
type: input
decode: int32
scale: {{ if eq .usage "pv" }}-{{ end }}0.1
energy:
source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: {{ if eq .usage "pv" }}0x5c{{ else }}0x3e{{ end }}
type: input
decode: int32
scale: 0.1
type: mbmd
{{- include "modbus" . }}
model: cgem24
power: Power
energy: Import
currents:
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x0c
type: input
decode: uint32
scale: 0.001
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x0e
type: input
decode: uint32
scale: 0.001
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x10
type: input
decode: uint32
scale: 0.001
voltages:
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x0
type: input
decode: uint32
scale: 0.1
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x2
type: input
decode: uint32
scale: 0.1
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x4
type: input
decode: uint32
scale: 0.1
- CurrentL1
- CurrentL2
- CurrentL3
{{- if eq .usage "grid" }}
powers:
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x12
type: input
decode: int32
scale: {{ if eq .usage "pv" }}-{{ end }}0.1
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x14
type: input
decode: int32
scale: {{ if eq .usage "pv" }}-{{ end }}0.1
- source: modbus
{{- include "modbus" . | indent 2 }}
register:
address: 0x16
type: input
decode: int32
scale: {{ if eq .usage "pv" }}-{{ end }}0.1
- PowerL1
- PowerL2
- PowerL3
{{- end }}
{{- if eq .usage "charge" }}
voltages:
- VoltageL1
- VoltageL2
- VoltageL3
{{- end }}

0 comments on commit 5419b52

Please sign in to comment.