Growatt pico reader
Micropython library for reading data from Growatt inverter using RS485 port. Library is build for Raspberry pi pico / pico w and RS485 to TTL module.
Installation
1. Using PyPi package (recommended)
In Thonny IDE go to Tools -> Manage Packages and search for growatt_pico_reader
2. Copy python file
Copy growatt_pico_reader/growatt_pico_reader_py file to your root directory on pi pico.
Usage
Import package
from growatt_pico_reader import *
Initial setup (not required)
set_tx_pin(pin_number) # change TX port (default is 0)
set_rx_pin(pin_number) # change RX port (default is 1)
set_ctrl_pin(pin_number) # change RS485 transceiver control pin (default is 1)
set_slave_address(address) # change growatt address (default is 1) (address can be set on inverter LCD display)
Read data
Read All Data:
all_data = await get_all()
print(all_data)
Read specific data:
grid_frequency = await get_Fac()
print(grid_frequency)
All available data to read:
| Register Address | Variable Short | Description | Unit | Function Call | Note |
|---|---|---|---|---|---|
| 0 | Inverter Status | Inverter run state | - | get_inverter_status() | 0:waiting, 1:normal, 3:fault |
| 1-2 | Ppv | Input power | W | get_Ppv() | |
| 3 | Vpv1 | PV1 voltage | V | get_Vpv1() | |
| 4 | PV1Curr | PV1 input current | A | get_PV1Curr() | |
| 5-6 | Ppv1 | PV1 input power | W | get_Ppv1() | |
| 35-36 | Pac | Output power | W | get_Pac() | |
| 37 | Fac | Grid frequency | Hz | get_Fac() | |
| 38 | Vac1 | Three/single phase grid voltage | V | get_Vac1() | |
| 39 | Iac1 | Three/single phase grid output current | A | get_Iac1() | |
| 40-41 | Pac1 | Three/single phase grid output watt VA | VA | get_Pac1() | |
| 42 | Vac2 | Three phase grid voltage | V | get_Vac2() | |
| 43 | Iac2 | Three phase grid output current | A | get_Iac2() | |
| 44-45 | Pac2 | Three phase grid output power | VA | get_Pac2() | |
| 46 | Vac3 | Three phase grid voltage | V | get_Vac3() | |
| 47 | Iac3 | Three phase grid output current | A | get_Iac3() | |
| 48-49 | Pac3 | Three phase grid output power | VA | get_Pac3() | |
| 50 | Vac_RS | Three phase grid voltage | V | get_Vac_RS() | |
| 51 | Vac_ST | Three phase grid voltage | V | get_Vac_ST() | |
| 52 | Vac_TR | Three phase grid voltage | V | get_Vac_TR() | |
| 53-54 | Eac_today | Today generate energy | kWh | get_Eac_today() | |
| 55-56 | Eac_total | Total generate energy | kWh | get_Eac_total() | |
| 57-58 | Time_total | Work time total | s | get_Time_total() | |
| 59-60 | Epv1_today | PV1Energy today | kWh | get_Epv1_today() | |
| 61-62 | Epv1_total | PV1Energy total | kWh | get_Epv1_total() | |
| 91-92 | Epv_total | PV Energy total | kWh | get_Epv_total() | |
| 93 | Temp1 | Inverter temperature | °C | get_Temp1() | |
| 101 | RealOPPercent | Real Output power Percent | % | get_RealOPPercent() | |
| 105 | FaultMaincode | Inverter fault maincode | - | get_FaultMaincode() | |
| 1009-1010 | Pdischarge1 | Discharge power | W | get_Pdischarge1() | |
| 1011-1012 | Pcharge1 | Charge power | W | get_Pcharge1() | |
| 1013 | Vbat | Battery voltage | V | get_Vbat() | |
| 1014 | SOC | State of charge Capacity | % | get_SOC() | |
| 1015-1016 | Pac_to_user | AC power to user | W | get_Pac_to_user_Total() | |
| 1021-1022 | Pac_to_user_Total | AC power to user total | W | get_Pac_to_user_Total() | |
| 1023-1024 | Pac_to_grid | AC power to grid | W | get_Pac_to_grid() | |
| 1029-1030 | Pac_to_grid_total | AC power to grid total | W | get_Pac_to_grid_total() | |
| 1031-1032 | PLocalLoad | INV power to local load | W | get_PLocalLoad() | |
| 1037-1038 | PLocalLoad_total | INV power to local load total | W | get_PLocalLoad_total() | |
| 1040 | Battery Temperature | Battery Temperature | °C | get_BatteryTemperature() | |
| 1044-1045 | Etouser_today | Energy to user today | kWh | get_Etouser_today() | |
| 1046-1047 | Etouser_total | Energy to user total | kWh | get_Etouser_total() | |
| 1048-1049 | Etogrid_today | Energy to grid today | kWh | get_Etogrid_today() | |
| 1050-1051 | Etogrid_total | Energy to grid total | kWh | get_Etogrid_total() | |
| 1052-1053 | Edischarge1_today | Discharge energy1 today | kWh | get_Edischarge1_today() | |
| 1054-1055 | Edischarge1_total | Total discharge energy1 | kWh | get_Edischarge1_total() | |
| 1056-1057 | Echarge1_today | Charge1 energy today | kWh | get_Echarge1_today() | |
| 1058-1059 | Echarge1_total | Charge1 energy total | kWh | get_Echarge1_total() | |
| 1060-1061 | ELocalLoad_Today | Local load energy today | kWh | get_ELocalLoad_Today() | |
| 1062-1063 | ELocalLoad_Total | Local load energy total | kWh | get_ELocalLoad_Total() | |
| 1124-1125 | ACCharge_Today | AC Charge Energy today | kWh | get_ACCharge_today() | |
| 1128-1129 | ACChargePower | AC Charge Power | W | get_ACChargePower() | |
| 1137-1138 | Esystem_today | System electric energy today | kWh | get_Esystem_today() | |
| 1139-1140 | Esystem_total | System electric energy total | kWh | get_Esystem_total() | |
| 1141-1142 | Eself_today | self electric energy today | kWh | get_Eself_today() | |
| 1143-1144 | Eself_total | self electric energy total | kWh | get_Eself_total() | |
| 1145-1146 | PSystem | System power | W | get_PSystem() | |
| 1147-1148 | PSelf | self power | W | get_PSelf() |
Example Hardware Setup
On growatt inverter on LCD display set RS485 mode to VPP. Pins 5 (modbus A) and 4 (modbus B) are used on RJ45 connector.
Used resources:
- For parsing data was used this document: Growatt-Inverter-Modbus-RTU-Protocol-II-V1-24-English-new.pdf
- Base functionality was inspired from TheTrueRandom/growatt-modbus
License and contributing
Project is licensed under MIT license. Feel free to open a PR for new features (e.g. more parsed data)
Metadata
Release files for growatt-pico-reader 0.1.3
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 |
|---|---|---|---|---|
| growatt_pico_reader-0.1.3.tar.gz | 5.2 MB | Without provenance | Details for growatt_pico_reader-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| growatt_pico_reader-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for growatt_pico_reader-0.1.3-py3-none-any.whl |
Total release size: 5.2 MB
Release files / growatt_pico_reader-0.1.3.tar.gz
| Download URL | growatt_pico_reader-0.1.3.tar.gz |
|---|---|
| Size | 5.2 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f4709a6ffc30194766f1f4778a82beec818d99379e76d2e8d025d2b005fa77ab
|
|
BLAKE2b-256 checksum How to use checksums |
a134f2152df50a23915521056cf97b2a01166d452b89dd20efa2d61476c9fcc3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Release files / growatt_pico_reader-0.1.3-py3-none-any.whl
| Download URL | growatt_pico_reader-0.1.3-py3-none-any.whl |
|---|---|
| Size | 8.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dfb5260532b3950736293d690c49739064cd4942f344e6fd20cc3e9e0ba3c00f
|
|
BLAKE2b-256 checksum How to use checksums |
311de08f845ca8acc88834eaa3ad3c62384748da5660d1e9d54612f45387cbe7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Security for growatt-pico-reader 0.1.3
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.