Heya. @deece you mention a newer firmware. My portal reports Solax_SI_CH_2nd_20150211_DE01 and while I can connect to the inverter to set up WiFi etc I can’t get any response from the usual API routes. Most people I see having success are using a 2016 version on the firmware. Do you still have the update files?
Finally got around to installing. Just have a few questions.
Firstly, I have the script running on an emoncms PI and it is feeding the stats into emoncms so I know it’s communicating with both my inverters but that’s as far as I seem to be able to get it to do
Ultimately I want to control both inverter batteries so they charge and discharge at a similar rate so I can get the MAX 5000w from the combined batteries and not what they seem to do at the momemnt is have one charging from solar + the other battery seems to be discharging into the first battery
Each inverter will charge/discharge at 2500w
You mention some debug lines to see what the script is doing. Can you point me in the right direction please
Can you also advise what I should set the two inverters to in the config, I am on a single phase with both and getting the grid meter reading from the first inverter.
Do I set them both as “Phase 1” or should they be set as if they were separate phases?
If you’re on a single phase installation, both inverters should be on Phase 1. This is only really relevant in 3 phase installs with single phase inverters.
To have the batteries act in unison, you want the following:
Thanks for the reply, my config is as below. I have put in only what I have configured
I have two SK-SU5000E one with 14.4kww and the other with 10.5kww of batteries on a single-phase grid connection.
They are both reachable via DNS entry as “solax1” and “solax2” - Should I set them as the fqdn in the script or is it OK if the PI can just resolve the hostname to IP
Hi is anybody using this with hybrid x1 g4? Does it work as the g4 seems quite different to the previous versions.
They have removed the ethernet port so the only way to connect is WiFi which I think is read only. They have also stopped using a meter and use a CT clamp instead. There is a port they label as rs485 control but I can’t find any documentation for what it does.
I am definitely behind the curve here, finally rebuilt my Home Assistant, Firewall, and EmonCMS onto a ProxMox host and got it all up and running
First with the latest Ubuntu LXC template I was getting the following error:
No module named ‘pymodbus.client.asynchronous’
The following solved it:
sudo pip3 install pymodbus==2.2.0rc4
I am able to ping both the hostname and fqdn of my inverters as setup in DNS from my EmonCMS VM but when running the script I get the following and just repeats:
root@ubuntu:/opt/PowerScraper# ./power_scraper.py
Setting up EmonCMS
Setting up Solax-BatteryControl
Setting up Solax-Modbus
not connected
not connected
err [Failure instance: Traceback: <class 'KeyError'>: 'Total system power'
/usr/local/lib/python3.10/dist-packages/pymodbus/framer/socket_framer.py:181:_process
/usr/local/lib/python3.10/dist-packages/pymodbus/client/asynchronous/twisted/__init__.py:126:_handleResponse
/usr/local/lib/python3.10/dist-packages/twisted/internet/defer.py:696:callback
/usr/local/lib/python3.10/dist-packages/twisted/internet/defer.py:798:_startRunCallbacks
--- <exception caught here> ---
/usr/local/lib/python3.10/dist-packages/twisted/internet/defer.py:892:_runCallbacks
/opt/PowerScraper/Inputs/SolaxModbus.py:199:solaxRegisterCallback
/opt/PowerScraper/./power_scraper.py:61:outputActions
/opt/PowerScraper/Outputs/SolaxBatteryControl.py:102:send
/opt/PowerScraper/Outputs/SolaxBatteryControl.py:23:handleMeterPower
the script is updating into EmonCMS and I can see that the battery power input/output is as it should be but no control as I still have one importing whilst the other is exporting
Still getting the following error
Looks like it is trying to set the second inverter to 0w but never changes and it stays exporting
solax2 to discharge at 0.0W
err [Failure instance: Traceback: <class 'KeyError'>: 'Total system power'
/usr/local/lib/python3.10/dist-packages/pymodbus/framer/socket_framer.py:181:_process
/usr/local/lib/python3.10/dist-packages/pymodbus/client/asynchronous/twisted/__init__.py:126:_handleResponse
/usr/local/lib/python3.10/dist-packages/twisted/internet/defer.py:696:callback
/usr/local/lib/python3.10/dist-packages/twisted/internet/defer.py:798:_startRunCallbacks
--- <exception caught here> ---
/usr/local/lib/python3.10/dist-packages/twisted/internet/defer.py:892:_runCallbacks
/opt/PowerScraper/Inputs/SolaxModbus.py:199:solaxRegisterCallback
/opt/PowerScraper/./power_scraper.py:61:outputActions
/opt/PowerScraper/Outputs/SolaxBatteryControl.py:102:send
/opt/PowerScraper/Outputs/SolaxBatteryControl.py:23:handleMeterPower
]
[Solax-Modbus]
poll_period = 10 # seconds
timeout = 5 # seconds
power_budget_avg_samples = 30 # The maximum number of samples to average power budget over
installer_password = 1234 # The installer password for the inverter (same as used on the front panel), required if you want to use battery control
inverters = ['solax1', 'solax2']
[emoncms]
timeout = 5 # seconds
server = "http://emoncms"
api_key = "MY API KEY"
[Solax-BatteryControl]
source = "solax1"
linked-batteries = true
timezone = "AEDT-10"
[Solax-BatteryControl.Inverter.solax1]
phase = 1
single-phase-charge-limit = 2500
single-phase-discharge-limit = 2500
max-charge = 2500
max-discharge = 2500
max-power = 4600
#grace-capacity = 50
#grace-power-threshold = 3500
#grace-charge-power = 500
[Solax-BatteryControl.Inverter.solax2]
phase = 1
single-phase-charge-limit = 2500
single-phase-discharge-limit = 2500
max-charge = 2500
max-discharge = 2500
max-power = 4600
#grace-capacity = 70
#grace-power-threshold = 3500
#grace-charge-power = 500
# Define the time periods
# Suitable for ActewAGL Time of Use plans in Canberra, Australia
# Peak times are widened in case the time on the meter drifts
[Solax-BatteryControl.Period.MorningPeak]
start = "4:30:00"
end = "00:30:00"
min-charge = 20
grid-charge = false
#force-discharge = 2500
[Solax-BatteryControl.Period.Offpeak]
start = "00:30:00"
end = "4:30:00"
min-charge = 70
grid-charge = true
#grace = false
Ultimately, I just want between the time of 04:30:00 and 00:30:00 to be able to stop the batteries from charging each other and balance themselves to either charge/discharge
The time period 00:30 - 04:30 is when my off peak/cheap rate and already force charge the batteries via Home Assistant and manage the charge capacity via an automation as I have two different size battery stacks
At all other times between 04:300 and 00:30 I just want to stop the two inverters from fighting with each other and the batteries from swapping charge from one to another and balance out
I only have on “source” setup under battery control and this is the inverter with the main CT clapm, should I put both in there? - will test so long
I am new here to learn how to get data from my Solax Su-5000 via modbus. This works, however, the connection is very unstable and I was thinking about a firmware update. Unfortunately I do not find a version to download.
Can you share Solax_SI_CH_2nd_20160912_DE02 with me?