renogymodbus
This package is intended to help you communicate with a Renogy charge controller. It has been tested with a Renogy Rover Elite but should work with other Renogy devices.
Features
- Read real time data
- Automatic retries
Connecting to the charge controller
Please check whether your charge controller has a rs232 or rs485 port.
rs485
Voucher code for 7% off Renogy: https://go.referralcandy.com/share/672HVC9
- rs485 to USB serial cable (UK) https://uk.renogy.com/rs485-to-usb-serial-cable/
- rs485 to USB serial cable (US) https://renogy.com/rs485-to-usb-serial-cable/
rs232
Unfortunately the rs232 to USB serial cable has been discontinued by Renogy. It is possible to make your own.
Installing the package
To install the package run
pip install renogymodbus
This package requires Python 3, depending on your setup you might have to instead run:
pip3 install renogymodbus
Command line utility
To run the command line utility and see the debug output run the following on the command line:
renogymodbus --portname /dev/ttyUSB0 --slaveaddress 1
usage: renogymodbus [-h] [--portname PORTNAME] [--slaveaddress SLAVEADDRESS]
[--device {charge_controller,smart_battery}]
[--find-slave-address]
optional arguments:
-h, --help show this help message and exit
--portname PORTNAME Port name for example /dev/ttyUSB0
--slaveaddress SLAVEADDRESS
Slave address 1-247
--device {charge_controller,smart_battery}
Device to read data from. Either charge_controller or
smart_battery
--find-slave-address Find slave address of modbus device
Example output for charge controller
Real Time Charge Controller Data
Solar voltage: 43.1V
Solar current: 0.09A
Solar power: 4W
Load voltage: 0.0V
Load current: 0.0A
Load power: 0W
Battery voltage: 13.9V
Battery state of charge: 100%
Battery temperature: -37°C
Controller temperature: 48°C
Maximum solar power today: 51W
Minimum solar power today: 0W
Maximum battery voltage today: 14.0V
Minimum battery voltage today: 13.1V
Example output for smart battery
Real Time Smart Battery Data
Cell voltages: [3.3, 3.3, 3.3, 3.3, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]V
Cell temperatures: [24.0, 24.0, 24.0, 24.0, 1835.2, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]°C
BMS temperature: 0.0°C
Environment temperatures: [25.0, 25.0]°C
Heater temperatures: [25.0, 25.0]°C
Current: -0.2A
Voltage: 13.3V
Remaining capacity: 98.966Ah
Total capacity: 100.0Ah
State of charge: 98.966%
Cycle number: 0
Charge voltage limit: 14.8V
Discharge voltage limit: 10.0V
Charge current limit: 50.0A
Discharge current limit: -100.0A
Python usage
To use the library within your Python code
Charge Controller
from renogymodbus import RenogyChargeController
controller = RenogyChargeController("/dev/ttyUSB0", 1)
controller.get_solar_voltage()
See https://github.com/rosswarren/renogymodbus/blob/main/renogymodbus/charge_controller.py for all available methods
Smart Battery
from renogymodbus import RenogySmartBattery
battery = RenogySmartBattery("/dev/ttyUSB0", 48)
battery.get_voltage()
See https://github.com/rosswarren/renogymodbus/blob/main/renogymodbus/smart_battery.py for all available methods
Metadata
Release files for renogymodbus 0.0.23
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| renogymodbus-0.0.23.tar.gz | 7.3 kB | Without provenance | Details for renogymodbus-0.0.23.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| renogymodbus-0.0.23-py3-none-any.whl | Python 3 | none | any | Details for renogymodbus-0.0.23-py3-none-any.whl |
Total release size: 15.2 kB
Release files / renogymodbus-0.0.23.tar.gz
| Download URL | renogymodbus-0.0.23.tar.gz |
|---|---|
| Size | 7.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ca0a9681dc3e55f82b8c8fbd166c660fb0307c2b5650710300d1f4e1a9e8b649
|
|
BLAKE2b-256 checksum How to use checksums |
df482ae3d14e3a645da0c3ed19e3fd99c31c6ee3b1068f776783cbf8879345e5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.4
|
Release files / renogymodbus-0.0.23-py3-none-any.whl
| Download URL | renogymodbus-0.0.23-py3-none-any.whl |
|---|---|
| Size | 8.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
021e3672dcf6a060da42447add71206072de8a283695f350ca1ee5f0df517e46
|
|
BLAKE2b-256 checksum How to use checksums |
dd4e77b90cafa8797cd0bac2f0e5e53163be6b1ca0b5d2ab1f29db0722c1f55c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.4
|
Security for renogymodbus 0.0.23
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.