Integration Solar inverter huawei 2000L

Run python in any other folder, now it imports the huawei_solar costum component instead of the pypi package. I probably should give them a different name so this can’t happen…

Thanks guys :partying_face:,
I have installed package via pip from https://pypi.org/project/huawei-solar/ everything went smoothly.
For now I’m preparing some integrations with other devices and software (like NodeJS).
What I have to say is that I was using all the time Smart Dongle from huawei. What was interesting - as a client in Access Point Smart Dongle got open port 502 - modbus (screen shot from port scan), I was sure that this will work…


Modbus TCP on smart dongle is :poop:, not working at all (at least for now).
Only direct connection to inverter gives modbus access.
Thanks once again, If I have any problems I will write on forum :slight_smile:
~Greetings

I don’t have a smart dongle so I can’t really experiment with what is possible with it :frowning:

I have a Huawei with Smart Dongle and can’t get Modbus to work with it.
Could it possibly be some other port? C701 protocol? The Smart Dongle is a proxy?

I mean, if it can’t be made working I need to connect a serial to rpi and use Modbus RTU.
Or create an extension of the built-in AP into my home.

Only build in AP has Modbus TCP. Co can connect rpi to Huawei using wifi adapter.

But if I connect the rpi to the inverters AP, how do I connect the rpi to my network?

Ethernet to home network and wifi adapter to Huawei.

Looking at your images from dd-wrt.
I think you could have routed 192.168.8.x/24 to 192.168.5.x/24 using the dd-wrt. Instead of creating a second virtual IP on you HA. But if it works it works. I think I have a Linksys WRT 1900AC somewhere that I could flash with dd-wrt.

How to set template sensor active_power ?

It doesn’t work that way:
pv_active_power:
friendly_name: “Produkcja AC”
entity_id: sensor.sun2000_8ktl_m0
unit_of_measurement: ‘W’
icon_template: mdi:solar-power
value_template: “{{ state_attr(‘sensor.sun2000_8ktl_m0’, ‘active_power’) }}”

You don’t need pv_active_power becouse it is the same as value from sensor.sun2000_8ktl_m0 entity.
From HA 0.115 you don’t add entity_id in template. This is example of template sensor:

- platform: template
  sensors:
    pv_01_voltage:
      friendly_name: "String 1 napięcie"
      unit_of_measurement: 'V'
      icon_template: mdi:flash-alert-outline
      value_template: "{{ state_attr('sensor.sun2000_8ktl_m0', 'pv_string_01_voltage') }}"

ok you are right i didn’t notice

Hi Rafał,
thanks for your work on this. Thanks to that, I’m successfully using now hass with sun2000-8ktl-m0.

My question is about the power metter - I got zeroes:
day_active_power_peak: 0
power_meter_active_power: 0

Is this some external meter needed that is compatible with Huawei? Or version of inverter that has it built-in? or am I missing sth? :slight_smile:

Potrzebujesz miernika dodatkowo zaraz za głównym licznikiem. Ja mam DTSU666-H bo taki jest podawany w katalogu. Podobno jest jakiś chiński zamiennik który również współpracuje z tym falownikiem (kiedyś widziałem na elektrodzie wpis o tym). Sam falownik żadnej firmy nie mam możliwości mierzenia energii przepływającej między domem a licznikiem, gdyż ta energia omija falownik. Jak się sprawuje instalacją? Mam do Jasła 60km prawie po sąsiedzku.

And I wanted to clarify one thing, because for some newbies (like me) it was not obvious.

There are four interfaces on Sun2000 when you have internet dongle plugged in (or just two without it):

  • built-in wifi access-point (internal) that exposes the data we need for HAss under the SSID SUN2000-HV… or when you use FusionSolar app when directly connected to wifi of Sun2000.
  • built-in serial interface you may use probably to get such info as well (the big plug below inverter).
  • dongle-ethernet and dongle-wifi - AFAIK those two are just to connect to internet using existing network connection. No simple way to get data from it. It’s used by inverter to send data to fusion-solar cloud, or any other configured provider for service/maintenance/data statistics. You get data about your PV from that cloud when you use fusionSolar app outside your home-network wifi.

Easiest option is to connect to the first one: built-in wifi AP as a client (with RaspberryPi or router like Rafał did) and use it to connect to Huawei Sun2000 device (usually its on IP: 192.168.8.1/24).

There is also another option - to grab those data from FusionSolar cloud using Kiosk option mentioned above. It has some drawbacks (like you expose your data a bit more while enabling Kiosk mode, you rely on internet connection and third party cloud services). For this option to work, you need to use web POST method to get data instead of modbus TCP (with resource: https://eu5.fusionsolar.huawei.com/kiosk/getRealTimeKpi) - See Frans’ post above for details.

Hope this is putting all methods in one post for clarification.

3 Likes

Ja jestem z Wro :slight_smile:
Ok dzięki za wyjaśnienie. Tutaj dokładnie opisane: https://www.youtube.com/watch?v=RmwZYNVjqHI

Pozdro

I’m afraid your model just doesn’t support that function. If you really want it you could recreate it within Home Assistant.

Do you know how to draw month with production per day?

1 Like

Hmm, based on the manual, it seems power meter should work with SUN2000-(8KTL, 10KTL, 12KTL, 15KTL, 17KTL, 20KTL).

Check this:

Power meter works with:

Sun2000-2~6KTL-L1;
SUN2000-3~10KTL-M0/M1;
SUN2000-8~20KTL-M0/M2;
SUN2000-50~60KTL-M0(tylkozSmartdongle-4G);
SUN2000-100KTL-M1(tylkozSmartdongle-4G)

I use mew-01 for this. It replaces a dedicated meter, easy to use and easy to integrate into the HA. It is also cheaper by half.