Skip to main content

solaredge_setapp

solaredge_setapp is a python library that parses inverter and power optimizer data from a compatible SolarEdge PV inverter. Only those models which support SetApp commissioning are supported.

This project is built on the efforts of others: for Home Assistant users, see drobtravels' solaredge_local, and jbuehl's solaredge for all non-SetApp power inverters. Developed and tested on a European SE3500H-RW000BNN4 SolarEdge single-phase inverter. If you instead want to monitor the official SolarEdge Modbus API, you could try solaredge_modbus.

Current WSA target: 1.6.9 (firmware 4.10.25)

Release 0.0.7 and earlier are compatible with WSA <= 1.3.9.

Reduced access to the SetApp API (2020-04-23)

The SetApp commissioning API with which this software communicates is used primarily by the SetApp utility on smartphones. For many users the commissioning API was also available through the ethernet and WiFi interfaces due to their inverter being in debug mode. As of 2020-03 SolarEdge has been systematically turning off debug mode on inverters.

Access to the commissioning API remains possible, however: by connecting to the inverter on the temporary WiFi access point created for the SetApp commissioning utility. This network can be activated by switching the 0/1/P button to P for one second. The WiFi network, whose name is displayed in the SetApp utility, and the password to which is printed on the label on the side of the inverter, still provides access to the SetApp API on port 80 as before. Once connected to this network it can be kept active by regularly requesting any API endpoint. Lack of activity causes this network to disconnect.

Those users with inverters still in debug mode might consider disconnecting their inverter — or otherwise firewall outbound connections — in order to prevent remote updates from disabling debug mode.

Installation

To install, either clone this project and install using setuptools:

python3 setup.py install

or install the package from PyPi:

pip3 install solaredge_setapp

Usage

See example.py how to fetch, parse, and display the SetApp protobuf files exposed by the SetApp API.

python3 example.py your-inverter-ip

For a complete JSON dump of all parsed values from all endpoints, try dump_all.py:

python3 dump_all.py your-inverter-ip

Basic usage of the status API endpoint:

import solaredge_setapp
import requests

inverter_ip = "10.0.0.1"

status_request = requests.get(f"http://{inverter_ip}/web/v1/status").content
status = solaredge_setapp.status.Status(status_request)

print(f"Inverter {status['serial']} is {status['status']} at {status['power_ac']:.2f}W")

See the relevant .proto file in solaredge_setapp/messages/, and solaredge_setapp/%endpoint%.py for all fields that are parsed for that particular endpoint.

The following API endpoints contain most of the useful information, and are therefore the primary focus:

  • information - web/v1/information - CPU and DSP versions, error logging
  • maintenance - web/v1/maintenance - power optimizer telemetry
  • status - web/v1/status - inverter and energy statistics

The remaining endpoints mostly concern functionality of the commissioning interface itself, and are therefore not implemented:

  • app_configs - web/v1/app_configs - language and functionality
  • communication - web/v1/communication - ethernet, wifi and RS485 settings
  • grid_protection - web/v1/grid_protection - grid protection settings
  • power_control - web/v1/power_control - grid power settings
  • region - web/v1/region - language and country settings

Working on protobuf messages

In order to use compile_proto.sh to (re)compile the protocol buffer .proto message definitions you will need protoc, which is provided, for example, by Ubuntu's protobuf-compiler package. (Re-)compiling the protobuf messages is only necessary if you have made local changes to them.

You can test changes to .proto files directly by passing raw protobuf to protoc:

curl -s http://your-inverter-ip/web/v1/status | protoc --decode Status messages/status.proto

Limitations

The SetApp API does not (yet) provide real-time power optimizer data. Initial results suggest the data is 5-15 minutes old. Inverter production and voltage information is near real-time, however. Basically, the entire information set visible on the inverter's SetApp web interface is available through this library, in addition to per optimizer voltages and temperatures. Power optimizer voltages and current are expressed as integers, and are therefore not entirely accurate.

Rate limiting will kick in if you have the SetApp web interface open while using this library.

The SetApp API is new, and therefore likely to change. Variable naming, distribution, and parsing is likely to change.

Contributing

Contributions are more than welcome, especially to the protocol buffer message definitions.

Metadata

Release files for solaredge-setapp 0.1.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for solaredge-setapp 0.1.5
File Size Uploaded
solaredge_setapp-0.1.5.tar.gz 72.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for solaredge-setapp 0.1.5
File Interpreter ABI Platform
solaredge_setapp-0.1.5-py3-none-any.whl Python 3 none any Details

Total release size: 117.9 kB

Release files / solaredge_setapp-0.1.5.tar.gz

Download URL solaredge_setapp-0.1.5.tar.gz
Size 72.0 kB
Tags Source
SHA-256 checksum
How to use checksums
e352fa217049a4f1a2715e66494aae1154b6a6b555e8316bc0e5ac4ffd7ba1c4
BLAKE2b-256 checksum
How to use checksums
1e65141e009bc04393b63965120f2b823b873e376687aabf9bd4acd16c78c7d7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.9.1

Release files / solaredge_setapp-0.1.5-py3-none-any.whl

Download URL solaredge_setapp-0.1.5-py3-none-any.whl
Size 45.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
410b2477f5f529a62e79d7f4af3e6cba48a71bbbedd004d67feaf613356cc5a0
BLAKE2b-256 checksum
How to use checksums
0fde08058c33669141716aca0a5060c1edba1b76fcefaaefb493060b9908b9c5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.9.1

Release history Release notifications | RSS feed

This release

0.1.5 This release

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.7

2 release files

0.0.6

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page