evcc-io/templates/definition/meter/openems.yaml
Andreas Linde d408767b2d
Configure: fix handling of PV systems (#4806)
- The configure intents to present devices that implement multiple usages in a single device or have linked templates and provide an easier step by step configuration experience e.g. by not asking for the same data for different usages over and over again
- Commit 880557594f changes this behaviour and now presents all devices that have multiple usages, e.g. meters that could be used as battery or pv meter
- This change introduces a new property `allineone` that should be used with the `usage` `param` the identify a device that implements multiple usages in the same device
- The filter to present these devices is extended by checking for this property
2022-10-13 13:57:15 +02:00

39 lines
872 B
YAML

template: openems
products:
- brand: OpenEMS
- brand: FENECON
params:
- name: usage
choice: ["grid", "pv", "battery"]
allinone: true
- name: host
- name: password
mask: true
default: user
advanced: true
render: |
type: custom
power:
source: http
{{- if eq .usage "grid" }}
uri: http://{{ .host }}/rest/channel/_sum/GridActivePower
{{- end }}
{{- if eq .usage "pv" }}
uri: http://{{ .host }}/rest/channel/_sum/ProductionActivePower
{{- end }}
{{- if eq .usage "battery" }}
uri: http://{{ .host }}/rest/channel/_sum/EssDischargePower
{{- end }}
auth:
type: basic
user: x
password: {{ .password }}
jq: .value
soc:
source: http
uri: http://{{ .host }}/rest/channel/_sum/EssSoc
auth:
type: basic
user: x
password: {{ .password }}
jq: .value