Integration Solar inverter huawei 2000L

yeah that is a FE dongle need to buy it separately wifi is integrated

Hello,

Ive tried to install this plugin but get following error:

Error while setting up huawei_solar platform for sensor
Traceback (most recent call last):

File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform

await asyncio.shield(task)

File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run

result = self.fn(*self.args, **self.kwargs)

File "/config/custom_components/huawei_solar/sensor.py", line 115, in setup_platform

HuaweiSolarSensor(inverter, config[CONF_OPTIMIZERS], config[CONF_BATTERY])

File "/config/custom_components/huawei_solar/sensor.py", line 130, in __init__

self._name = self._inverter.get("model_name").value

File "/usr/local/lib/python3.9/site-packages/huawei_solar/huawei_solar.py", line 265, in get

response = self.read_register(reg.register, reg.length)

File "/usr/local/lib/python3.9/site-packages/huawei_solar/huawei_solar.py", line 312, in read_register

raise ReadException(message)

huawei_solar.huawei_solar.ReadException: could not read register value, is an other device already connected?

However when I ssh onto the machine and try it with python, it works:

>>> inverter.get ("model_name")
Result(value='SUN2000L-4.6KTL', unit=None)

Anyone else has ideas on what I could try?

Thanks

Po niedawnej aktualizacji 2021.07.01 i aktualizacji modbusa integracja zaczela mi wariowac.
Czesc sensorow jest “unavailable” czasem sie pojawiaja jak zresetuje itp.

Czy ktos sie spotkal z czyms takim ?
Mam zintegrowane przez modbusa i wbudowany AP a do tego podlaczylem jeszcze kablem dongla i na razie odczytalo wszystkie wazne sensory ale chwile temu polowy nie bylo.

Pozdrawiam
Wojtek

Hi, I face the same error message… but i am connected with direct wifi AP (which is easy as my raspberry pi wlan is otherwise out of duty)…
you can check the dongle firmware also in the FusionSolar app, Tap devices at the bottom and there the dongle should apear and your inverter.
If you want to use the dongle, you have to be connected wired (attached in the dongle at the bottom).

Interesting wise for me: my connection was working the day before perfectly… and suddenly it stops working… when i enable the modbus plugin in FHEM again, it works out of the box - so seems that the python implementation is doing something differently - maybe timing, idk.

update: error gone, connection established… strange :slight_smile:

U mnie działa bez problemów z donglem zaktualizowanym do wersji V100R001C00SPC122 w węwnętrznej sieci. HA w najnowszej wersji 2021.08.02

Thanks for the tip. I was able to add Sonoff Pow2 using Alexxit’s SonoffLan control to Energy dashboard. GitHub - AlexxIT/SonoffLAN: Control Sonoff Devices with eWeLink (original) firmware over LAN and/or Cloud from Home Assistant
Steps are simple

  1. configuration
  2. Scroll down to Customizations
  3. select your entity
  4. select device class as “energy”
  5. select state class as " measurement"
  6. Select other
  7. Attribute name “last_reset”.
    8 attribute value “1970-01-01T00:00:00+00:00”
  8. click save
  9. Now your sensor will show up in energy dashboard.

I don’t know why every day start with -43kwh in chart.

Probably you ara using the daily yield.
At midnight night it goes down the yesterday production.
I use Total yield… And everything it’s ok.

I think the last_reset definition can solve…
But I don’t know how.
If the last reset was set to last midnight…
Anyone can do that?

The only this I have not working is the CO2.
The integration is OK… I have the value on my lovelace… But the Energy dashboard say… Can’t calculate…
Any help?

Thanks everybody
GP

1 Like

How did you get access to the firmware? I have a ticket open with Huawei at the moment to get access to it, but for some reason none of my accounts seem to allow me to download anything other than V100R001C00SPC110 release, and even then they won’t let me download that, stuck on V100R001C00SPC109

thanks .i changed to Total yield. hope all will be ok now

https://easyupload.io/pyh5l5 got it from them 10 days ago, SPC122.

Is there anything big that have been changed lately ??..

Beacuse my sd card crashed a while ago and have had it working then . but now after i got my backup installed in a ssd i cant get it to connect to the inverter anymoore ??

i get these errors below

Is there anything that i need to change ??
My settings in config is

  - platform: huawei_solar   
    host: 192.168.8.1
    optimizers: false
    battery: false
    slave: 0

And i have also tride to use slave 1 but with the same results

Logger: homeassistant.components.sensor
Source: custom_components/huawei_solar/sensor.py:130
Integration: Sensor (documentation, issues)
First occurred: 3:25:26 PM (1 occurrences)
Last logged: 3:25:26 PM

Error while setting up huawei_solar platform for sensor
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/huawei_solar/huawei_solar.py", line 293, in read_register
    response = self.client.read_holding_registers(
  File "/usr/local/lib/python3.9/site-packages/pymodbus/client/common.py", line 114, in read_holding_registers
    return self.execute(request)
  File "/usr/local/lib/python3.9/site-packages/pymodbus/client/sync.py", line 108, in execute
    raise ConnectionException("Failed to connect[%s]" % (self.__str__()))
pymodbus.exceptions.ConnectionException: Modbus Error: [Connection] Failed to connect[ModbusTcpClient(192.168.8.1:502)]

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform
    await asyncio.shield(task)
  File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/huawei_solar/sensor.py", line 115, in setup_platform
    HuaweiSolarSensor(inverter, config[CONF_OPTIMIZERS], config[CONF_BATTERY])
  File "/config/custom_components/huawei_solar/sensor.py", line 130, in __init__
    self._name = self._inverter.get("model_name").value
  File "/usr/local/lib/python3.9/site-packages/huawei_solar/huawei_solar.py", line 265, in get
    response = self.read_register(reg.register, reg.length)
  File "/usr/local/lib/python3.9/site-packages/huawei_solar/huawei_solar.py", line 298, in read_register
    raise ConnectionException(ex)
huawei_solar.huawei_solar.ConnectionException: Modbus Error: [Connection] Failed to connect[ModbusTcpClient(192.168.8.1:502)]

Logger: pymodbus.client.sync
Source: /usr/local/lib/python3.9/site-packages/pymodbus/client/sync.py:218
First occurred: 3:25:18 PM (2 occurrences)
Last logged: 3:25:25 PM

Connection to (192.168.8.1, 502) failed: timed out
Logger: huawei_solar.huawei_solar
Source: /usr/local/lib/python3.9/site-packages/huawei_solar/huawei_solar.py:297
First occurred: 3:25:25 PM (1 occurrences)
Last logged: 3:25:25 PM

failed to connect to device, is the host correct?
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/huawei_solar/huawei_solar.py", line 293, in read_register
    response = self.client.read_holding_registers(
  File "/usr/local/lib/python3.9/site-packages/pymodbus/client/common.py", line 114, in read_holding_registers
    return self.execute(request)
  File "/usr/local/lib/python3.9/site-packages/pymodbus/client/sync.py", line 108, in execute
    raise ConnectionException("Failed to connect[%s]" % (self.__str__()))
pymodbus.exceptions.ConnectionException: Modbus Error: [Connection] Failed to connect[ModbusTcpClient(192.168.8.1:502)]

Thanks for the link, though for some reason it refuses to upgrade on my unit. I did finally hear back from the Huawei support team, and they also supplied me the SPC118 release and SPC122 and neither works. I hope it’s just a case of my current firmware being so old that there is an intermediate release which I can see SPC110 is released on the main site. Waiting yet again to hear back, in the meantime I am back to querying it over the internal inverter wifi. Not that it doesn’t work, but it’s messy, and would much rather it simply be on the LAN.

No one that can help me out ??

Check if inverter IP is still 192.168.8.1. I know few people that after firmware update it changed to 192.168.200.1. You can also check if the connection to inverter is working correctly and try if modbus integration is working correctly. If you can ping inverter from HA and modbus integration is working, then there is something wrong with huawei_solar integration. Did you update also files from huawei_solar integration?

The inverter still has the ip 192.168.8.1 and my Dongle has the software version :
V100R001C00SPC118.

But i try to connect to the internal wifi of the inverter with the interna wifi from RPI4

Cant upgrade to any newer in the device upgrade ??.

The problem now is that i cant find the wifi from Home assistant to the inverter … i have used the NMCLI to connect to it .
But when i take my phone i can find the network and connect to it .

I dont know how to be able to ping it from HA but it dont connect to it it says

Logger: pymodbus.client.sync
Source: /usr/local/lib/python3.9/site-packages/pymodbus/client/sync.py:218
First occurred: 4:33:01 PM (2 occurrences)
Last logged: 4:33:08 PM

Connection to (192.168.5.1, 502) failed: timed out

Here above i tried to change to 192.168.5.1 but still the same

I have made a clean install with everything but still the same outcome sadly …

I have the dongle connected by cable but cant get it to work by that way either …

If I correctly understand, the problem is connection from HA to the inverter.

You can use https://www.home-assistant.io/integrations/ping/ to check if HA see inverter. If you want to use LAN you must have *SPC120 or *SPC122 firmware in smart dongle (it was posted in this topic: Integration Solar inverter huawei 2000L - #594 by andro1, and manual how to upgrade smart dongle: Integration Solar inverter huawei 2000L - #514 by giuseppe07)

This is my first post …Hello everyone
I have a Sun2000-8KTL-M1 inverter. I asked tech support for a new dongle firmware and got this answer:
Hello,
My recommendation for you is to wait until the improved version SPC123 for the SDongle will be launched by the end of this week as expected.
I also recommend you to upgrade your inverter to the latest SPC135 (currently, your inverter is running SPC133).
Please let me know, do you want me to perform the upgrade for you remotely? or do you prefer to provide you the SPC135 software package?

So it looks like it. that Version SPC122 seems to have some problems.

1 Like

sorry but I have problem witho solar item of new energy panel.

I try our idea but not work for me

  • platform: template
    sensors:
    solar_daily:
    friendly_name: “Energetica giornaliera”
    unit_of_measurement: ‘kWh’
    icon_template: mdi:solar-power
    value_template: “{{ state_attr(‘sensor.sun2000l_3ktl’, ‘daily_yield’) }}”

I view 0 value

How do you upgrade fromn a downloaded file ?? i dont have acess to that filename in my login only older versions but cant find any upload button