Page 1 of 2

Huawei SUN2000 Inverters

Posted: Monday 25 April 2022 11:20
by sammyke007
Hi

Last week I've had solar panels installed with a Huawei SUN2000-4.6KTL-L1 inverter.
I have a (Belgium/Fluvius) smart meter installed so I can read everything with a Youless device from the P1 port of my smart meter.
There's one value however that I would like to see extra in my Domoticz: the actual provided output power from my PV (and maybe later the Yield Today en Yield Total).

Anyone that has this running already?

Data is provided in the cloud on https://eu5.fusionsolar.huawei.com/. This can be read from an app or using a web interface. There's also an API available.

I've found this: https://github.com/wlcrs/huawei_solar/tree/develop but I have no idea how to make this work with Domoticz.

Re: Huawei SUN2000 Inverters

Posted: Wednesday 25 May 2022 12:50
by JeroenG
Hi Sammy,

this _can_ be done, but requires some work:

1. Try to get yourself a developers account for the data which is collecting. This request MUST be submitted by the company who installed your converter.

Send an email to "eu_inverter_support<at>huawei.com" with the following:

I hereby request an openAPI user account to access the data from my inverter through the new #FusionSolar API:
System name: XXXXXXXXXXXXXXXXXX (serial no)
Username: [email protected]
Plant Name: City and adress
SN Inverter: XXXXXXXXXXXXXXXXXXXX (serial no)

You will receive an excel form to be filled and submitted by your installer (if not from them, it will be refused)

2. When te account is created you can use a (bash) script to retreive the "real-time", hourly, daily and yearly data from their website which 1 updated every 5 minutes.

Real-time is updated every 5 minutes, so it's more "almost real time"

I collect this data every 5 minutes and write it to Domoticz (real time data) en and to influx (hour, day and year) to produce nice graphs.

My scripts need some cleanup before I can share it, it's still some work in progress.
domoticz.png
domoticz.png (19.59 KiB) Viewed 9353 times
2022-05-25 12_44_11-Zonnepanelen actueel - Grafana.png
2022-05-25 12_44_11-Zonnepanelen actueel - Grafana.png (69.88 KiB) Viewed 9353 times
2022-05-25 12_44_21-Zonnepanelen jaaroverzicht - Grafana.png
2022-05-25 12_44_21-Zonnepanelen jaaroverzicht - Grafana.png (133.26 KiB) Viewed 9353 times

Re: Huawei SUN2000 Inverters

Posted: Sunday 05 June 2022 9:41
by sammyke007
Tnx Jeroen! I've started running HASS (Home Assistant) next to Domoticz because they have a custom integration for these inverters. It reports almost everything available. It gets its data live from the inverter itself (by connecting to the inverters AP) and it's working perfectly fine over here. I use automations in HASS to send this data over MQTT to Domoticz.
hass.jpg
hass.jpg (82.31 KiB) Viewed 9308 times
domo1.jpg
domo1.jpg (16.63 KiB) Viewed 9308 times
domo2.jpg
domo2.jpg (98.12 KiB) Viewed 9308 times

Re: Huawei SUN2000 Inverters

Posted: Saturday 02 July 2022 12:58
by MikeZ
Hi Jeroen

How does home assistant connect directly to the ap off the inverters ?
And were you able to push the data from HA to Domoticz?

Re: Huawei SUN2000 Inverters

Posted: Saturday 02 July 2022 13:07
by MikeZ
Hi Jeroen,

Would like to use your script
I had it all working with the API version from beginning 2021

Are you able to share some?

Re: Huawei SUN2000 Inverters

Posted: Saturday 02 July 2022 17:09
by JeroenG
sammyke007 wrote: Sunday 05 June 2022 9:41 Tnx Jeroen! I've started running HASS (Home Assistant) next to Domoticz because they have a custom integration for these inverters. It reports almost everything available. It gets its data live from the inverter itself (by connecting to the inverters AP) and it's working perfectly fine over here. I use automations in HASS to send this data over MQTT to Domoticz.
Sammy,

how do you call the API from the inverter? I'm very interested in that :-). Can you share any documentation and or links?

Thanks a lot,
Jeroen

Re: Huawei SUN2000 Inverters

Posted: Saturday 02 July 2022 17:13
by JeroenG
MikeZ wrote: Saturday 02 July 2022 13:07 Hi Jeroen,

Would like to use your script
I had it all working with the API version from beginning 2021

Are you able to share some?
Hi Mike,

I will try to document my script the coming days and see if I can publish it somewhere (Github or so).

Jeroen

Re: Huawei SUN2000 Inverters

Posted: Saturday 02 July 2022 21:01
by sammyke007
JeroenG wrote: Saturday 02 July 2022 17:09
sammyke007 wrote: Sunday 05 June 2022 9:41 Tnx Jeroen! I've started running HASS (Home Assistant) next to Domoticz because they have a custom integration for these inverters. It reports almost everything available. It gets its data live from the inverter itself (by connecting to the inverters AP) and it's working perfectly fine over here. I use automations in HASS to send this data over MQTT to Domoticz.
Sammy,

how do you call the API from the inverter? I'm very interested in that :-). Can you share any documentation and or links?

Thanks a lot,
Jeroen
It's this Home Assistant integration that I'm running:
https://github.com/wlcrs/huawei_solar

Re: Huawei SUN2000 Inverters

Posted: Monday 04 July 2022 18:53
by MikeZ
Hi Sammy

Looks great!
Stupid question though: if HA is connected via WiFi, how do you enter the UI from HA ? Or do you use wired connection also to connect to your network and the internet?

Many thanks

Re: Huawei SUN2000 Inverters

Posted: Friday 08 July 2022 17:43
by sammyke007
My Home Assistant is connected thru LAN (ethernet) and my connection to the Huawei AP (192.168.200.1) is done via wifi. You can use a Pi or a homeserver with a wifi USB stick.

It is explained over here:
https://github.com/wlcrs/huawei_solar/w ... nverter-ap

Re: Huawei SUN2000 Inverters

Posted: Sunday 10 July 2022 15:45
by JeroenG
I just released my first version of the script to read the production details from the huawei website. It is required to have your inverter communication with Huawei of course :-)

https://github.com/GoumJer/Huawei_Sun2000

Re: Huawei SUN2000 Inverters

Posted: Wednesday 13 July 2022 17:23
by kurb77
JeroenG wrote: Sunday 10 July 2022 15:45 I just released my first version of the script to read the production details from the huawei website. It is required to have your inverter communication with Huawei of course :-)

https://github.com/GoumJer/Huawei_Sun2000
hello, i looked your code, can you explain the config file, i don't understand all params, can you comment them?

thank you

Re: Huawei SUN2000 Inverters

Posted: Wednesday 13 July 2022 23:07
by JeroenG
Hi,

Just uploaded a more detail readme and added some more info in the .env file.

More improvements to come :-)

Re: Huawei SUN2000 Inverters

Posted: Saturday 12 October 2024 21:16
by ssk17051980
is anyone willing to integrate a huawei 2000 inverter in domoticz?
I don't have the necessary skills. I can pay for this service

Re: Huawei SUN2000 Inverters

Posted: Saturday 12 October 2024 23:21
by waltervl
Everything you need to know is here: https://github.com/GoumJer/Huawei_Sun2000

Re: Huawei SUN2000 Inverters

Posted: Tuesday 15 October 2024 22:17
by ssk17051980
i made the admin user.
but if i try to login whit that new user, is not working.

in that link that i receive in the mail, from the foto atached, i can't login whit the main user and pass.

Re: Huawei SUN2000 Inverters

Posted: Tuesday 15 October 2024 23:13
by ssk17051980
what is that " domain name of the management " ?

Re: Huawei SUN2000 Inverters

Posted: Thursday 13 February 2025 21:59
by csuti
Hi everyone!

After a year of operation, I have finally integrated my Huawei SUN2000 inverter :)
I found some Domoticz Python plugins, so I decided to develop the plugin created by JWGracht (thanks) a bit further. I implemented connection error handling and a polling time that can be adjusted from the plugin parameters. I tried to collect all the parameters I thought were useful via Modbus. The updated plugin also handles voltage, current, power, energy, status, error codes, alarms, and temperature data.
Although it is not new, I thought I would share it here as well, in case it is valuable to someone.
domoticz_huaweisolar.png
domoticz_huaweisolar.png (240.13 KiB) Viewed 2131 times
domoticz_huaweisolar2.png
domoticz_huaweisolar2.png (69.96 KiB) Viewed 2131 times
Code on github:
https://github.com/csutihu/Domoticz-plu ... 0-Inverter

Re: Huawei SUN2000 Inverters

Posted: Thursday 06 March 2025 6:53
by dankogabor
Csuti, can u help me, what the problem with your plugin?
I installed it
pip3 install huawei-solar
cd ~/domoticz/plugins
git clone https://github.com/csutihu/Domoticz-plu ... verter.git
sudo systemctl restart domoticz

After that I create Hardware in Domoticz and in log i can see this:

2025-03-04 23:28:34.434 Status: Huawei Inverter Plugin: Entering work loop.
2025-03-04 23:28:34.434 Status: Huawei Inverter Plugin: Started.
2025-03-04 23:28:34.735 Error: Huawei Inverter Plugin: (Domoticz-Huawei-Inverter) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Domoticz-plugin-for-Huawei-SUN2000-Inverter/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3.7/dist-packages'.
2025-03-04 23:28:34.735 Error: Huawei Inverter Plugin: Traceback (most recent call last):
2025-03-04 23:28:34.735 Error: Huawei Inverter Plugin: File "/home/pi/domoticz/plugins/Domoticz-plugin-for-Huawei-SUN2000-Inverter/plugin.py", line 26, in <module>
2025-03-04 23:28:34.735 Error: Huawei Inverter Plugin: from huawei_solar import HuaweiSolarBridge
2025-03-04 23:28:34.735 Error: Huawei Inverter Plugin: ImportError: cannot import name 'HuaweiSolarBridge' from 'huawei_solar' (/usr/local/lib/python3.7/dist-packages/huawei_solar/__init__.py)
2025-03-04 23:28:42.153 RPI-sensors: General/Percentage (CPU_Usage)
2025-03-04 23:29:02.158 RPI-sensors: General/Percentage (Memory Usage)
2025-03-04 23:29:02.164 RPI-sensors: General/Custom Sensor (Process Usage)
2025-03-04 23:29:12.160 RPI-sensors: General/Percentage (CPU_Usage)
2025-03-04 23:29:22.188 RPI-sensors: General/Percentage (HDD /boot)
2025-03-04 23:29:22.192 RPI-sensors: General/Percentage (HDD /)
2025-03-04 23:29:32.221 RPI-sensors: Temp (RPI-Temp)
2025-03-04 23:29:42.223 RPI-sensors: General/Percentage (CPU_Usage)
2025-03-04 23:29:42.357 Error: Huawei Inverter Plugin hardware (6) thread seems to have ended unexpectedly
2025-03-04 23:29:56.360 Error: Huawei Inverter Plugin hardware (6) thread seems to have ended unexpectedly
2025-03-04 23:30:10.419 Error: Huawei Inverter Plugin hardware (6) thread seems to have ended unexpectedly

Raspbian GNU/Linux 10 (buster) | Raspberry Pi 4 Model B Rev 1.1 | Domoticz v2024.4

Re: Huawei SUN2000 Inverters

Posted: Thursday 06 March 2025 7:58
by waltervl
Perhaps run
sudo pip3 install huawei-solar