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

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)

I use a Sunsynk inverter with 16kWH of storage and an AC coupled SMA sunnyboy inverter with a 3.6kW solar panel array

I have some simple python apps running separately to openHAB that get status and allow programming of the inverter, publishing the changes to openHAB using the Rest API.

The Sunsynk App uses the Sunsynk Connect API on the www.
The SMA App uses Bluetooth to connect locally to the Sunny boy

I also use the solcast API to predict my solar in advance allowing me to predict how high to charge my Sunsynk batteries during Economy 7 ( UK energy tariff) to keep my energy prices down.

I automate this with a schedule app that pulls data from Solcast and Sunsynk to programme my inverter during the early hours.

I also publish my solar stats to the PVoutput website.

I’m working on a binding for Sunsynk so I can do the automation inside OpenHAB. Don’t hold your brief on this being ready soon as I’m new to Java, Maven, Git and the openHAB development architecture.

28 April 2024 update Sun Synk Connect Binding released for test:

For Axpert inverter, to read data / send commands in/from OH4, is there any complete tutorial available? I found a full docker solution for HomeAssistant, but I don’t like the idea to migrate from OH since I’m using from years already… but I may be forced to do it, otherwise, since this integration is very important to my setup.

Thanks,
T.