Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/syssi/esphome-pipsolar
ESPHome component to monitor and control a pipsolar inverter via RS232
https://github.com/syssi/esphome-pipsolar
epshome esphome-component esphome-config hacktoberfest pipsolar qpigs
Last synced: 24 days ago
JSON representation
ESPHome component to monitor and control a pipsolar inverter via RS232
- Host: GitHub
- URL: https://github.com/syssi/esphome-pipsolar
- Owner: syssi
- License: apache-2.0
- Created: 2021-08-09T09:58:06.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-12-10T07:39:34.000Z (24 days ago)
- Last Synced: 2024-12-10T08:29:14.069Z (24 days ago)
- Topics: epshome, esphome-component, esphome-config, hacktoberfest, pipsolar, qpigs
- Homepage:
- Size: 3.87 MB
- Stars: 105
- Watchers: 11
- Forks: 43
- Open Issues: 52
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# esphome-pipsolar
![GitHub actions](https://github.com/syssi/esphome-pipsolar/actions/workflows/ci.yaml/badge.svg)
![GitHub stars](https://img.shields.io/github/stars/syssi/esphome-pipsolar)
![GitHub forks](https://img.shields.io/github/forks/syssi/esphome-pipsolar)
![GitHub watchers](https://img.shields.io/github/watchers/syssi/esphome-pipsolar)
[!["Buy Me A Coffee"](https://img.shields.io/badge/buy%20me%20a%20coffee-donate-yellow.svg)](https://www.buymeacoffee.com/syssi)ESPHome example configuration to monitor and control a pipsolar inverter via RS232
Kudos to [@andreashergert1984](https://github.com/andreashergert1984) for the great work!
## Supported devices
* PIP4048 compatible PV Inverter
## Requirements
* [ESPHome 2024.6.0 or higher](https://github.com/esphome/esphome/releases).
* One half of an ethernet cable with RJ45 connector
* RS232-to-TTL module (`MAX3232CSE` f.e.)
* Generic ESP32 or ESP8266 board## Schematics
```
RS232 UART-TTL
┌──────────┐ ┌──────────┐ ┌─────────┐
│ │ │ │<----- RX ----->│ │
│ │<---- TX ---->│ RS232 │<----- TX ----->│ ESP32/ │
│ PIP │<---- RX ---->│ to TTL │<----- GND ---->│ ESP8266 │
│ │<---- GND --->│ module │<-- 3.3V VCC -->│ │<--- VCC
│ │ │ │ │ │<--- GND
└──────────┘ └──────────┘ └─────────┘
```### RJ45 connector
| Pin | Purpose | MAX3232 pin | Color T-568B |
| :-----: | :----------- | :---------------- | :------------|
| 1 | TX | P13 (RIN1) | White-Orange |
| 2 | RX | P14 (DOUT1) | Orange |
| 3 | | | |
| 4 | VCC 12V | - | Blue |
| 5 | | | |
| 6 | | | |
| 7 | | | |
| 8 | GND | P15 (GND) | Brown |Please be aware of the different RJ45 pinout colors ([T-568A vs. T-568B](images/rj45-colors-t568a-vs-t568.png)).
The inverter provides +12V on pin 4 or 7 depending on the model. You can use a cheap DC-DC converter to power the ESP with 3.3V.
The [source for the pinout is here](docs/HS_MS_MSX%20RS232%20Protocol.pdf).
### MAX3232
| Pin | Label | ESPHome | ESP8266 example | ESP32 example |
| :----------- | :----------- | :---------- | :--------------- | :------------ |
| P11 (DIN1) | TXD | `tx_pin` | `GPIO4` | `GPIO16` |
| P12 (ROUT1) | RXD | `rx_pin` | `GPIO5` | `GPIO17` |
| P16 (VCC) | VCC | | | |
| P15 (GND) | GND | | | |## Installation
Use the `esp32-example.yaml` / `esp8266-example.yaml` as proof of concept:
```bash
# Install esphome
pip3 install esphome# Clone this external component
git clone https://github.com/syssi/esphome-pipsolar.git
cd esphome-pipsolar# Create a secret.yaml containing some setup specific secrets
cat > secrets.yaml <>>`) your inverter responds (`<<<`). `NAK` is a negative response f.e. if the command isn't supported. If you have trouble to interpret the log please create an issue and provide your ESPHome log.## References
* https://github.com/esphome/esphome/pull/1664
* https://github.com/esphome/esphome-docs/pull/1084/files
* https://github.com/andreashergert1984/esphome/tree/feature_pipsolar_anh
* https://github.com/jblance/mpp-solar/tree/master/docs/protocols