What solar PV inverter(s) do you have *working* with openHAB, and how?

oh, that’s what you mean. I will certainly try this, never thought about it.
I asume I need these 2 things:

Hi
Just though I would cross link this thread to my new post, in case anybody finds this thread first and what I have done is of any use to them.

I’ve installed 1x Huawei SUN2000-2KTL-L1 inverter. With the latest firmware level it is possible to use modbus tcp without the sdongle (using port 6607 instead of 502). To open this port it is necessary to execute the following procedure (in a mobile phone with fusion app): Go to device commissioning, connect to your inverter (needs installer password), then go to Settings → Communication configuration → Router connection settings. Then, select your local wifi access point, enter your password and check the option “Local O&M”, then click Connect. It will reconnect to your access point, but this time port 6607 is open on local lan.

I’m using OH 4.0.0.M2

1 Like

Now that I’ve finally got a solar PV system installed, and I do indeed have it working beautifully with openHAB, I suppose I should reply to my own post to say that I have Enphase IQ7A microinverters and the associated Enphase Envoy, along with the just-updated version of the Enphase binding from @hilbrand (see post in Enphase binding thread). I used a combination of webgui configuration for the Envoy bridge, along with a .things file for the inverters, and then a whole lot of items and persistence rules, but there is now a huge amount of data in near-real-time coming from the Envoy and every attached microinverter.

The Enphase solution is probably overengineered for anyone who doesn’t have such problems with shading on their available roof area (at this time of year, production on the west side of our roof goes up on a cloudy day), but at least one up-side of spending all that money on a system which handles the shading well is some really comprehensive data.

Solis 3P-10k-4G via MODBUS/RS485

I use SBFspot to fetch the inverter data from a SMA Sunny Boy 4000TL-21 inverter. The data points are stored in a SQLite database which I query by means of a Python script, and then I post the relevant parameters to openHAB over the REST API.

Details: Example on how to access data of a Sunny Boy SMA solar inverter - #69 by shutterfreak

I have a Fronius and use the Fronius binding. It does what i want without having to go to the vendors cloud based database.

Using Panels with Enphase microinverters with the envoy monitor. This has a local API (with some “secret” services). They return a json message that I read using the http binding and split into the seperate values using a json transform. Using two services I get the total and each seperate panel.

GivEnergy Inverters have a good cloud API available. I understand you can also get local data without going to the cloud using GitHub - britkat1980/giv_tcp: TCP connection (from inverter) and MQTT implementation (I’ve not tried it myself as the cloud API works fine for what I need)

Hi I’m also considering Huawei SUN2000 inverter and LUNA2000 battery. I read somewhere that I need to buy the Huawei Smart Dongle-WLAN-FE for ModBus TCP to work. Are you saying it’s no longer necessary? And can you have ModBus running in parallel with Fusion (ready somewhere only one can work at a time). Thank you!

Yes

Yes

Thanks! Looks like the model our supplier quote is: SUN2000-8KTL-M1
Do you know the differences between M1 and L1? There are also M2 and M3 very confusing…
Thanks

L1’s are single phase, M1’s are 3-phase. Unless you have devices that require 3-phase I would suggest to convert your home to single phase. In my Country it’s cheaper, and also more imune to current peaks that can action circuit breakers.

Edit: I remember the installer saying that the dongle was included by default in M1’s but I don’t know if this is still the case

1 Like

Thanks! I think I need 3 phase for car charger. Will check with the installer, have a great day!

1 Like

I’ve a RCT Power converter and battery. I use the command line tool rctclient to read the values from the inverter. It’s called via bash script by a cron job and submits the data to openHAB by mqtt.

A native RCT binding would be welcome :wink: .

1 Like

I wrote a binding for Growatt inverters. The PR (below) was work-in-progress for quite some time during the summer holiday, but I have had it live on my own system for a couple of days, so the PR is now ready for review.

2 Likes

Hi JGluch,

I am also an owner of a RCT power inverter and battery.
So I’m also interested in an easy binding for OpenHab.

I tried to implement the rctclient. But I was not successful.

Was it easy to manage? Is there a step by step guidelines to implement it with scripts an anything?

Best regards Julian

Hi Julian, it’s quite easy and runs very robust on my xubuntu based machine.
I’ve an pv.items file that contains all related items like:

Number:Power PV_Input_A_Watt "solar power [%.1f W]" (gWatt, gWattChart, gPV) { channel="mqtt:topic:solar:PV_Input_A_Watt", unit="W"}

and the MQTT things are defined like (some with tranformations to get the desired format/scale):

Thing mqtt:topic:solar "Solaranlage" (mqtt:broker:mqttBroker) {
    Channels:
        // Monitoring/PV/Current
        Type number : PV_Input_A_Volt "Input A in Volt" [ stateTopic="solar/B55BA2CE" ]
        Type number : PV_Input_A_Watt "Input A in Watt" [ stateTopic="solar/DB11855B", transformationPattern="JS:| parseFloat(input) * 1" ]

and the MQTT messages come from the following script:

#!/bin/bash
RctId="959930BF B55BA2CE DB11855B DB2D69AE A7FA5C5D 8B9FF008 959930BF 400F015B 4BC0F974 902AFAFB 1AC87AA0 91617C58 2AE703F2 3C87C4F5 867DEF7D 2F3C1D7D 81AE960B 65B624AB 126ABC86 F0BE6429"
RctIP="192.168.1.XX"
# Iterate the string variable using for loop
for val in $RctId; do
 RctVal=$(/home/XXX/.venvs/MyEnv/bin/rctclient read-value --host $RctIP --id 0x$val)
 # RctVal=$(rctclient read-value --host $RctIP --id 0x$val)
 mosquitto_pub -h "192.168.1.YY" -u "mqtt" -P "myMQTTpassword" -t "solar/$val" -m "$RctVal"
done

which runs every minute by a cron job:

sudo crontab -e
* * * * * openhab /pathtothescript/pv2mqtt.sh

The script calls the rctclient script, that I managed to install with these commands:

mkdir -p $HOME/.venvs
python3 -m venv ~/.venvs/MyEnv
cd ~/.venvs/MyEnv/
~/.venvs/MyEnv/bin/python  --version
~/.venvs/MyEnv/bin/python -m pip install ~/Downloads/python-rctclient-0.0.4.tar.gz 
~/.venvs/MyEnv/bin/python -m pip install ~/Downloads/click-8.1.7.tar.gz

After install, you can check if it works by calling it on the command line to get the battery state of charge

~/.venvs/MyEnv/bin/rctclient rctclient read-value --host 192.168.1.XX --id 0x959930BF

The content of the different hex values is documented in the file that you have linked before.

Hi,
I’m owning an Ampere.Storage Battery Inverter which seems to be in fact a SAJ HS2 rebrand. It#s connected by Modbus TCP. Currently I have no Register description of this inverter. I found some of the interesting values by comparing the readings against the App, but found not all I want to fetch.
At least I was able to build a rule which puts some of the overproduction in my water heating system based on forecast and current usage/production/battery filling.
Is anyone using such a inverter and know the relevant register locations?
Regards Chris

Sofar solar through this binding LswLogger Binding [Sofar/Omnik/IE wifi/eth stick for SolarmanPV] (I am author of this binding)