Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Home Assistant Modbus Integration for Fox ESS H3 Inverters

Notifications You must be signed in to change notification settings

BluetriX/HA-FoxESS-H3-Modbus

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

FoxESS and Home Assistant integration via Modbus RS485


A community maintained Home Assistant integration using local native polling of Modbus data using RS485 to enable near realtime data access, with no reliance on the FoxESS cloud portal

image


Connecting your H3 inverter can be acheived by:

  • Connecting to the (RasPi's) COM port using a RS485 to USB (Approved)

  • Connecting to the home WiFi using a RS485 to WiFi dongle like the 'Elfin EW11A RS485 to WIFI converter' (Connects the RS485 pins on your inverter. This does not use the inverter's build-in WiFi or Ethernet connection.)

  • ⚠️ Using the inverter's Ethernet LAN port or dongle to connect to your router/switch via Ethernet does not work for H3 inverters, yet. Port 502 is not open. This solution might be fixed with future firmware. It is not possible with firmware version Master 1.25-1.57, Slave 1.02, Manager 1.29 ⚠️


Supported Hardware

This fork adds support for the
Hybrid Series H3
Tested with
✅ H3-5.0-E
✅ H3-8.0-E
✅ H3-10.0-E
✅ H3-12.0-E

The origin project supports 1-phase Inverters Hybrid Series
✅ H1-3.0-E
✅ H1-3.7-E
✅ H1-4.6-E
✅ H1-5.0-E
✅ H1-6.0-E
AC Series
✅ AC-3.0-E
✅ AC-3.7-E
✅ AC-4.6-E
✅ AC-5.0-E
✅ AC-6.0-E
AIO Series
✅ AIO-H1-3.0
✅ AIO-H1-3.7
✅ AIO-H1-4.6
✅ AIO-H1-5.0
✅ AIO-H1-6.0

For T Series - See this alternative project by assembly12


The aim of this project is to enable the full use of the Energy dashboard in Home Assistant and is a fully functional replacement of the FoxESS App for reporting needs.

⚠️ Installation via HACS does not work for this fork due to naming convention

Manual Specific installation

  • Create the directory structure /config/custom_components/HA-FoxESS-Modbus/ (use the "file editor" addon of HA)
  • Copy the required modbus file to /config/custom_components/HA-FoxESS-Modbus/
    • if you go with serial cable to USB connection use /config/custom_components/HA-FoxESS-Modbus/modbusH3USB.yaml
    • if you go with wifi to RS485 dongle use /config/custom_components/HA-FoxESS-Modbus/modbusLAN-H3.yaml

Then, Common Installation Steps

  • Create a full backup of your HA instance including the configuration.yaml file
  • Copy the required modbus line (USB or Wifi) and following contents of the configuration.yaml file to your config file
  • Check your config is valid, then Restart HA
  • Map energy dashboard as per below example and enjoy configuring dashboards using near realtime data.

Step by step walkthrough of the setup (for the H1 inverter fork) image

Engergy Dashboard Configuration

image

Energy Dashboard Values

Grid Consumption

  • meter_consumption_energy_daily (only when SmartMeter is connected to inverter)
  • inv_load_energy_daily (inverter's output. use for island system)

Return to Grid

  • meter_feed_in_energy_daily (only when SmartMeter is connected to inverter)

Solar Panels

  • pv1_daily

  • pv2_daily

    As an alternative:

  • pv_energy_daily (direct cumulative PV1+PV2 from inverter)

Home Batteries

  • battery_charge_energy_daily
  • battery_discharge_energy_daily

Provided Entities

Registers The H3 registers wiki has references for the 3-phase registers.

The H1 registers wiki shows the 1-phase registers.




Please read and understand before using this plugin:

This plugin has been developed as a personal project, with no connection to the official brand of FoxESS, use of this plugin is intended for use by the community without fee but has no warrenty or liability should any damage, harm or undesired results happen as a result of using this plugin. We strongly recommend that only competently trained individuals attempt to wire the additional connections required for this plugin to function. There is a risk of personal or device damage/harm. You have been warned! This modbus integration is read-only. You cannot change the behaviour of your inverter or set any values.


Troubleshooting

If you encounter modbus reading errors:

  • Disable unneeded sensors by commenting all lines, or delete the entries. It was found that battery_voltage and battery_current are two sensors that do not respond to status requests correctly.

    Comment out in the modbusH3USB.yaml file

    #  - name: "Battery Voltage"
    #    unique_id: foxess_inv1_battery_voltage
    #    scan_interval: 30
    #    address: 31034
    #    state_class: measurement
    #    unit_of_measurement: "V"
    #    data_type: int16
    #    scale: 0.1
    #    precision: 1
    #    device_class: voltage
    #    input_type: holding
    #  - name: "Battery Current"
    #    unique_id: foxess_inv1_battery_current
    #    scan_interval: 30
    #    address: 31035
    #    state_class: measurement
    #    unit_of_measurement: "A"
    #    data_type: int16
    #    scale: 0.1
    #    precision: 1
    #    input_type: holding      
    #    device_class: current
    

  • Increase the scan_interval for sensors that are not needed. The HA modbus integration requests every sensor register with a single call. If you have a large number of sensors here, the calls might interfere with each other.

About

Home Assistant Modbus Integration for Fox ESS H3 Inverters

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published