FoxESS: split H1/H3 devices (#7376)

Co-authored-by: premultiply <4681172+premultiply@users.noreply.github.com>
This commit is contained in:
andig 2023-06-05 22:37:01 +02:00 • committed by GitHub
parent 1b11a6a3d1
commit bfd52c2ef7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 81 additions and 5 deletions

View file

@ -1,8 +1,9 @@
template: fox-ess-ethernet
template: fox-ess-h1
covers: ["fox-ess-ethernet"]
products:
- brand: FoxESS
description:
generic: FoxESS via Ethernet
generic: H1 via Ethernet
params:
- name: usage
choice: ["pv", "battery"]

View file

@ -0,0 +1,49 @@
template: fox-ess-h3
products:
- brand: FoxESS
description:
generic: H3 via Ethernet
params:
- name: usage
choice: ["pv", "battery"]
- name: modbus
choice: ["tcpip"]
render: |
type: custom
{{- if eq .usage "pv" }}
power:
source: calc
add:
- source: modbus
{{- include "modbus" . | indent 4 }}
# register details
register:
address: 31002 # PV1
type: holding
decode: int16
- source: modbus
{{- include "modbus" . | indent 4 }}
# register details
register:
address: 31005 # PV2
type: holding
decode: int16
{{- end }}
{{- if eq .usage "battery" }}
power:
source: modbus
{{- include "modbus" . | indent 2 }}
# register details
register:
address: 31036 # Battery Charge/Discharge
type: holding
decode: int16
soc:
source: modbus
{{- include "modbus" . | indent 2 }}
# register details
register:
address: 31038 # Soc
type: holding
decode: int16
{{- end }}

View file

@ -1,11 +1,11 @@
product:
brand: FoxESS
description: FoxESS via Ethernet
description: H1 via Ethernet
render:
- usage: pv
default: |
type: template
template: fox-ess-ethernet
template: fox-ess-h1
usage: pv
# Modbus TCP
@ -16,7 +16,7 @@ render:
- usage: battery
default: |
type: template
template: fox-ess-ethernet
template: fox-ess-h1
usage: battery
# Modbus TCP

View file

@ -0,0 +1,26 @@
product:
brand: FoxESS
description: H3 via Ethernet
render:
- usage: pv
default: |
type: template
template: fox-ess-h3
usage: pv
# Modbus TCP
modbus: tcpip
id: 1
host: 192.0.2.2 # Hostname
port: 502 # Port
- usage: battery
default: |
type: template
template: fox-ess-h3
usage: battery
# Modbus TCP
modbus: tcpip
id: 1
host: 192.0.2.2 # Hostname
port: 502 # Port