Integration Solar inverter huawei 2000L

Please be more specific when reporting issues. What version have you tried using? When did the error occur? During initial setup? Does the integration crash a few minutes after setup?
How does your solar setup look like? What is your type of inverter, batter, power meter, … ? Are you connecting to the Modbus-interface available on your local network, on the WiFi of the inverter, on the WiFi of an SDongle?

I’m using master version. I trying connect to SDongle available on my local network. telnet on port 192.168.8.122:502 is working
Inverter: **Huawei, SUN2000-6KTL-M1 without battery
On fusionSonar app, I can see all data.

How I can connect to mobus?

The integration works super for me and its simple to set up, excellent work! Is it possible to add more write options, like set operation mode and TOU parameters. And is it a more simple way och add your login-and write branch? I am not that great on ssh and coding :slight_smile:

All writeable fields can be added in theory. However, I want to avoid adding settings which are “dangerous”, like setting the minimum SoC of the battery. That’s something that you don’t need to be able to set outside of the admin interface of FusionSolar

TOU can be set, but it’s hard to put into a nice format for a service call. A lot of validation is needed to make sure there is no overlap between time ranges, etc. Not high on my priority list to be honest, but contributions are welcome of course.

Please add the following to your configuration.yaml:

logger:
  default: info
  logs:
    pymodbus: debug
    huawei_solar: debug
    custom_components.huawei_solar: debug

After restarting HA, try to initialize the integration again. Post all relevant log lines here, or create an issue on GitHub.

Did anyone manage how to count selfusage/autoconsumption or whatever it is officialy called from data provided by this integrtion? I have power meter. On speed I think it should be current production substracted by export to grid, but I am not sure if this formula is perfect for any scenario.

Can the login-and-write branch also be installed by just copying the files from the login-and-write branch on github into the custom_components/huawei_solar folder in my HA installation and then restarting HA + reinstalling the integration?

Yes. It doesn’t matter how you get the correct files in the correct place. But I don’t think GitHub let’s you download a whole branch easily. I just offered the easiest way.

1 Like

I readed MODBUS TCP Guide - Huawei Enterprise Support Community
and updated sdongle to: V100R001C00SPC124 and inverter V100R001C00SPC140. After that I turned on mbus tcp. Error:
2022-01-31 22:11:39 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Connecting to 192.168.8.122:502.

2022-01-31 22:11:39 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Connecting.

2022-01-31 22:11:39 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Client connected to modbus server

2022-01-31 22:11:39 INFO (MainThread) [pymodbus.client.asynchronous.async_io] Protocol made connection.

2022-01-31 22:11:39 INFO (MainThread) [pymodbus.client.asynchronous.async_io] Connected to 192.168.8.122:502.

2022-01-31 22:11:40 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 43006

2022-01-31 22:11:40 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x1 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1

2022-01-31 22:11:40 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 1

2022-01-31 22:11:43 INFO (MainThread) [backoff] Backing off _do_read(…) for 2.0s (asyncio.exceptions.TimeoutError)

2022-01-31 22:11:43 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 1 tries

2022-01-31 22:11:45 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x2 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1

2022-01-31 22:11:45 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 2

2022-01-31 22:11:48 INFO (MainThread) [backoff] Backing off _do_read(…) for 2.0s (asyncio.exceptions.TimeoutError)

2022-01-31 22:11:48 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 2 tries

2022-01-31 22:11:50 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x3 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1

2022-01-31 22:11:50 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 3

2022-01-31 22:11:53 INFO (MainThread) [backoff] Backing off _do_read(…) for 2.0s (asyncio.exceptions.TimeoutError)

2022-01-31 22:11:53 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 3 tries

2022-01-31 22:11:55 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x4 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1

2022-01-31 22:11:55 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 4

2022-01-31 22:11:58 INFO (MainThread) [backoff] Backing off _do_read(…) for 2.0s (asyncio.exceptions.TimeoutError)

2022-01-31 22:11:58 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 4 tries

2022-01-31 22:12:00 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x5 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1

2022-01-31 22:12:00 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 5

2022-01-31 22:12:03 ERROR (MainThread) [backoff] Giving up _do_read(…) after 5 tries (asyncio.exceptions.TimeoutError)

Ok It’s working now I updated MBUS on inverter

Hi Fistacho,

I have the exact same problem an log items. The difference is the firmware version of the sDongel. mine is: V100R001C00SPC127.

What version of the MBUS in the inverter do you have? I updated to V100R001C00SPC300 but it still doesn’t work.

Gr. EJ

Ok It’s working now. I set the Slave Id to 1, then it worked.

Hi all. I will install Sun2000 6ktl this spring. I have 3 questions to point in the right direction:

  1. This component (Issues · Emilv2/huawei_solar · GitHub) is the main way to integrate it in homeassistant?
  2. S dongle is needed in order to connect it to that integration?
  3. It is suggested to get also the Huawei Smart power sensor or it is quite unuseful?

Thank you

  1. I think GitHub - wlcrs/huawei_solar at develop will be better and @wlcrs is trying to integrate it with HA out of box without installing custom component.
  2. You don’t need Sdongle, you can read data connecting to internal invetrer AP.
  3. It depends if you need it, with smart meter you can block exporting energy to grid or set limit. I’m using smart meter only for statistics but I don’t regret extra money spent on this.
1 Like

Hi

Hoping i could get some help with this, i had the integration working until yesterday.
Now im getting this when i try to add the inverter.

2022-02-02 13:12:15 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Connecting to 192.168.0.109:502.
2022-02-02 13:12:15 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Connecting.
2022-02-02 13:12:15 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Client connected to modbus server
2022-02-02 13:12:15 INFO (MainThread) [pymodbus.client.asynchronous.async_io] Protocol made connection.
2022-02-02 13:12:15 INFO (MainThread) [pymodbus.client.asynchronous.async_io] Connected to 192.168.0.109:502.
2022-02-02 13:12:16 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 43006
2022-02-02 13:12:16 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x1 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1
2022-02-02 13:12:16 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 1
2022-02-02 13:12:19 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-02-02 13:12:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 1 tries
2022-02-02 13:12:21 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x2 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1
2022-02-02 13:12:21 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 2
2022-02-02 13:12:24 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-02-02 13:12:24 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 2 tries
2022-02-02 13:12:26 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x3 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1
2022-02-02 13:12:26 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 3
2022-02-02 13:12:29 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-02-02 13:12:29 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 3 tries
2022-02-02 13:12:31 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x4 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1
2022-02-02 13:12:31 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 4
2022-02-02 13:12:34 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-02-02 13:12:34 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 4 tries
2022-02-02 13:12:36 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] send: 0x0 0x5 0x0 0x0 0x0 0x6 0x0 0x3 0xa7 0xfe 0x0 0x1
2022-02-02 13:12:36 DEBUG (MainThread) [pymodbus.transaction] Adding transaction 5
2022-02-02 13:12:39 ERROR (MainThread) [backoff] Giving up _do_read(...) after 5 tries (asyncio.exceptions.TimeoutError)

Hi Thijs,

Yesterday I managed to get it to work with the SDongle.
I would also like to see the data of all optimizers, can this be activated? I can’t find if and how to activate this.
According to sensor.optimizers_online, all 18 were online today.

Can you help me, or am I looking for something that isn’t there?

While the integration was able to setup the initial connection to the Huawei Inverter, it did not respond to any queries in time. This is probably caused by using the wrong slave ID (typically 0 or 1, try both or ask your installer if unsure).

Hi Erikjan, the optimizer data is not easily accessible like the other fields that I query. I need to implement some kind of custom “download”-protocol over Modbus to get to that information (they confusingly call it “Upload” in their documentation because it uploads data from the inverter to the client I guess?)

It’s on my todo-list, but I want to polish the existing features first before I implement anything new.

FYI: the optimizer data is only refreshed every 5 minutes. If I get around to implementing this feature, it won’t be realtime like the rest of the data fields.

Hi Thijs,

Thanks for your reply and confirmation that I’m looking for something that isn’t there at all.

It would be great if it is added in the future, I’ll wait patiently :wink:

Thanks for the good job!

Thanks for the tip, i have tried ID from 0 to 16 now.
Sadly only the same in the log :frowning:
Anything else i can test? Or anything i need to do in the inverter or dongle settings?

2022-02-02 20:24:12 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Waiting 100 ms before next connection attempt.
2022-02-02 20:24:12 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Connecting.
2022-02-02 20:24:12 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Client connected to modbus server
2022-02-02 20:24:12 INFO (MainThread) [pymodbus.client.asynchronous.async_io] Protocol made connection.
2022-02-02 20:24:12 INFO (MainThread) [pymodbus.client.asynchronous.async_io] Connected to 192.168.0.109:502.
2022-02-02 20:24:12 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Client disconnected from modbus server: None
2022-02-02 20:24:12 INFO (MainThread) [pymodbus.client.asynchronous.async_io] Protocol lost connection.
2022-02-02 20:24:12 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Waiting 100 ms before next connection attempt.
2022-02-02 20:24:12 DEBUG (MainThread) [pymodbus.client.asynchronous.async_io] Connecting