Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/syssi/esphome-pace-bms

ESPHome component to monitor and control a PACE Battery Management System (PACE-BMS) via RS485 (Modbus)
https://github.com/syssi/esphome-pace-bms

esphome esphome-component hacktoberfest modbus uart

Last synced: 15 days ago
JSON representation

ESPHome component to monitor and control a PACE Battery Management System (PACE-BMS) via RS485 (Modbus)

Awesome Lists containing this project

README

        

# esphome-pace-bms

![GitHub actions](https://github.com/syssi/esphome-pace-bms/actions/workflows/ci.yaml/badge.svg)
![GitHub stars](https://img.shields.io/github/stars/syssi/esphome-pace-bms)
![GitHub forks](https://img.shields.io/github/forks/syssi/esphome-pace-bms)
![GitHub watchers](https://img.shields.io/github/watchers/syssi/esphome-pace-bms)
[!["Buy Me A Coffee"](https://img.shields.io/badge/buy%20me%20a%20coffee-donate-yellow.svg)](https://www.buymeacoffee.com/syssi)

ESPHome configuration to monitor and control a PACE Battery Management System (PACE-BMS) via RS485 (Modbus)

This project implements the `PACE_MODBUS` protocol. Please use the RS485 port next to the CAN bus port and enable the protocol using the `PbmsTools.exe` (System Config -> Inverter protocol -> RS485 Protocol).

## Supported devices

* Katbatt 6.4kWh LiFePO4 Stackable Battery, PACE BMS P16S200A (`P16S200A-21473-1.03A310771030800025A`), using RS485 protocol `PACE_MODBUS`
* PACE BMS P16S200A with firmware version 3 (`P16S200A-21382-3.00T213822131800670H`), using RS485 protocol `PACE_MODBUS` ([#20](https://github.com/syssi/esphome-pace-bms/issues/20))
* Gobel Power GP-SR1-LF280-RN150 51.2V 280Ah, PACE BMS S16A150 (`JLD-BMS-S16A150`), using RS485 protocol `ModbusC1636`
* Joyvoit Suns Energy Battery JVBW5KW, PACE BMS P16S100A (`P16S100A-21468-1.00`), using RS485 protocol `PACE_MODBUS` ([#19](https://github.com/syssi/esphome-pace-bms/issues/19))
* Orient Power Wall Mounted Battery 48V100AH, PACE BMS P16S100A-21236-2.01 ([#31](https://github.com/syssi/esphome-pace-bms/discussions/31))
* SOK 100Ah 48V Server Rack Berry, PACE BMS P16S100A (`P16S100A-1B470-4.07`), using RS485 protocol `PACE_MODBUS` ([#35](https://github.com/syssi/esphome-pace-bms/issues/35))
* SOK 100Ah 48V Server Rack Berry, PACE BMS P16S100A (`P16S100A-1B470-4.00`), using RS485 protocol `PACE_MODBUS` ([#38](https://github.com/syssi/esphome-pace-bms/discussions/38))
* MeritSun / i-finity LFP 200 - 48V (Modbus must be enabled by pbmstool.exe) ([#29](https://github.com/syssi/esphome-pace-bms/issues/29))
* Revov R100 51.2V 100Ah, PACE BMS P16S100A (`P16S100A-12720-4.05G`), using RS485 protocol `SRNE` ([#39](https://github.com/syssi/esphome-pace-bms/issues/39))
* NPP 51.2v 280AH FLCD-30048 NSFG280F10/DS, PACE BMS P16S200A (`P16S200A-21452-2.02`) using RS485 protocol `PACE_MODBUS` ([#60](https://github.com/syssi/esphome-pace-bms/discussions/60))

## Untested devices

* Jakiper/BSLBATT 100Ah, PACE BMS P16S100A
* LIONTRON LiFePO4 LX48-100, 48V 100Ah
* Shenzen Delong 24V 100Ah, PACE BMS P16S200A-PC1547
* Hubble Lithium (AM2, AM4)
* Revov R9
* Greenrich U-P5000

## Schematics

```
RS485 UART
┌────────────┐ ┌──────────┐ ┌─────────┐
│ │ │ │<----- RX ----->│ │
│ PACE │<-----B- ---->│ RS485 │<----- TX ----->│ ESP32/ │
│ BMS │<---- A+ ---->│ to TTL │<----- GND ---->│ ESP8266 │
│ │<--- GND ---->│ module │<----- 3.3V --->│ │<-- VCC
│ │ │ │ │ │<-- GND
└────────────┘ └──────────┘ └─────────┘

```

Please make sure to power the RS485 module with 3.3V because it affects the TTL (transistor-transistor logic) voltage between RS485 module and ESP.

### RJ45 jack

| Pin | Purpose | RS485-to-TTL pin | Color T-568B |
|:-----:|:--------|:-----------------|--------------|
| **1** | **B-** | **B-** | Orange-White |
| **2** | **A+** | **A+** | Orange |
| **3** | **GND** | **GND** | Green-White |
| 4 | NC | | |
| 5 | NC | | |
| 6 | GND | | |
| 7 | A+ | | |
| 8 | B- | | |

Please be aware of the different RJ45 pinout colors ([T-568A vs. T-568B](images/rj45-colors-t568a-vs-t568.png)).

### BMS address

| Module address | BMS Module ID | Dip1 | Dip2 | Dip3 | Dip4 |
|:---------------|:--------------|-----:|-----:|-----:|-----:|
| `0x00` | 0 | off | off | off | off |
| `0x01` | 1 | on | off | off | off |
| `0x02` | 2 | off | on | off | off |
| `0x03` | 3 | on | on | off | off |
| `0x04` | 4 | off | off | on | off |
| `0x05` | 5 | on | off | on | off |
| `0x06` | 6 | off | on | on | off |
| `0x07` | 7 | on | on | on | off |
| `0x08` | 8 | off | off | off | on |
| `0x09` | 9 | on | off | off | on |
| `0x0A` | 10 | off | on | off | on |
| `0x0B` | 11 | on | on | off | on |
| `0x0C` | 12 | off | off | on | on |
| `0x0D` | 13 | on | off | on | on |
| `0x0E` | 14 | off | on | on | on |
| `0x0F` | 15 | on | on | on | on |

## Requirements

* [ESPHome 2024.6.0 or higher](https://github.com/esphome/esphome/releases).
* Generic ESP32 or ESP8266 board

## Installation

Use the `esp32-example.yaml` as proof of concept:

```bash
# Install esphome
pip3 install esphome

# Clone this project
git clone https://github.com/syssi/esphome-pace-bms.git
cd esphome-pace-bms

# Create a secrets.yaml containing some setup specific secrets
cat > secrets.yaml <