Integration Solar inverter huawei 2000L

Please submit a bugreport including a diagnostics data file. Make sure to use the latest beta as I’ve improved the diagnostics file generation in 1.2.0b3

Logger: homeassistant.components.websocket_api.http.connection
Source: components/number/init.py:349
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 18:23:57 (2 occurrences)
Last logged: 18:28:42

[139772920293712] Value 1000.0 for Grid charge maximum power is outside valid range 0 - 100.0
[139772326438864] Value 1000.0 for Grid charge maximum power is outside valid range 0 - 100.0
Traceback (most recent call last):
File “/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py”, line 200, in handle_call_service
await hass.services.async_call(
File “/usr/src/homeassistant/homeassistant/core.py”, line 1745, in async_call
task.result()
File “/usr/src/homeassistant/homeassistant/core.py”, line 1782, in _execute_service
await cast(Callable[[ServiceCall], Awaitable[None]], handler.job.target)(
File “/usr/src/homeassistant/homeassistant/helpers/entity_component.py”, line 213, in handle_service
await service.entity_service_call(
File “/usr/src/homeassistant/homeassistant/helpers/service.py”, line 678, in entity_service_call
future.result() # pop exception if have
File “/usr/src/homeassistant/homeassistant/helpers/entity.py”, line 943, in async_request_call
await coro
File “/usr/src/homeassistant/homeassistant/helpers/service.py”, line 715, in _handle_entity_call
await result
File “/usr/src/homeassistant/homeassistant/components/number/init.py”, line 349, in async_set_value
raise ValueError(
ValueError: Value 1000.0 for Grid charge maximum power is outside valid range 0 - 100.0

{
“home_assistant”: {
“installation_type”: “Home Assistant OS”,
“version”: “2022.12.8”,
“dev”: false,
“hassio”: true,
“virtualenv”: false,
“python_version”: “3.10.7”,
“docker”: true,
“arch”: “x86_64”,
“timezone”: “Europe/Brussels”,
“os_name”: “Linux”,
“os_version”: “5.15.80”,
“supervisor”: “2022.11.2”,
“host_os”: “Home Assistant OS 9.4”,
“docker_version”: “20.10.19”,
“chassis”: “vm”,
“run_as_root”: true
},
“custom_components”: {
“midea_ac_lan”: {
“version”: “v0.3.16-Beta7”,
“requirements”: []
},
“blitzortung”: {
“version”: “1.0.1”,
“requirements”: [
“paho-mqtt>=1.5.0”
]
},
“neerslag”: {
“version”: “2022.07.07.1”,
“requirements”: []
},
“spotcast”: {
“version”: “v3.6.30”,
“requirements”: [
“spotify_token==1.0.0”
]
},
“sonoff”: {
“version”: “3.3.1”,
“requirements”: [
“pycryptodome>=3.6.6”
]
},
“average”: {
“version”: “2.3.0”,
“requirements”: []
},
“webrtc”: {
“version”: “v2.3.1”,
“requirements”: []
},
“afvalbeheer”: {
“version”: “5.0.10”,
“requirements”: [
“rsa”,
“pycryptodome”
]
},
“simple_thermostat”: {
“version”: “1.0.2”,
“requirements”: []
},
“tapo_control”: {
“version”: “4.2.1”,
“requirements”: [
“pytapo==2.8”,
“onvif-zeep-async==1.2.0”
]
},
“fontawesome”: {
“version”: “2.1.5”,
“requirements”: []
},
“elro_connects”: {
“version”: “0.1.12”,
“requirements”: [
“lib-elro-connects==0.5.4”
]
},
“huawei_solar”: {
“version”: “1.2.0b4”,
“requirements”: [
“huawei-solar==2.2.0b4”
]
},
“watchman”: {
“version”: “0.5.1”,
“requirements”: [
“prettytable==3.0.0”
]
},
“localtuya”: {
“version”: “4.1.1”,
“requirements”: []
},
“scheduler”: {
“version”: “v0.0.0”,
“requirements”: []
},
“waste_collection_schedule”: {
“version”: “1.31.0”,
“requirements”: [
“icalendar”,
“recurring_ical_events”,
“icalevents”,
“bs4”
]
},
“google_home”: {
“version”: “1.9.15”,
“requirements”: [
“glocaltokens==0.6.8”
]
},
“sunspec”: {
“version”: “0.0.22”,
“requirements”: [
“pysunspec2==1.0.8”
]
},
“hacs”: {
“version”: “1.29.0”,
“requirements”: [
“aiogithubapi>=22.10.1”
]
},
“hekr”: {
“version”: “v0.2.14”,
“requirements”: [
“hekrapi==0.3.1”
]
},
“asusrouter”: {
“version”: “0.16.0”,
“requirements”: [
“asusrouter==0.15.1”
]
}
},
“integration_manifest”: {
“domain”: “huawei_solar”,
“name”: “Huawei Solar”,
“config_flow”: true,
“documentation”: “https://www.home-assistant.io/integrations/huawei_solar”,
“issue_tracker”: “Issues · wlcrs/huawei_solar · GitHub”,
“requirements”: [
“huawei-solar==2.2.0b4”
],
“codeowners”: [
@wlcrs
],
“iot_class”: “local_polling”,
“version”: “1.2.0b4”,
“loggers”: [
“huawei_solar”,
“pymodbus”
],
“is_built_in”: false
},
“data”: {
“config_entry_data”: {
“host”: “192.168.200.1”,
“port”: 6607,
“slave_ids”: [
0
],
“enable_parameter_configuration”: true,
“username”: “installer”,
“password”: “REDACTED
},
“slave_0”: {
“model_name”: “SUN2000-4.6KTL-L1”,
“pv_string_count”: 2,
“has_optimizers”: 0,
“battery_type”: 2,
“battery_1_type”: 2,
“battery_2_type”: 0,
“power_meter_type”: 0,
“supports_capacity_control”: true
},
“slave_0_data”: {
“input_power”: [
0,
“W”
],
“line_voltage_A_B”: [
220.7,
“V”
],
“line_voltage_B_C”: [
0.0,
“V”
],
“line_voltage_C_A”: [
0.0,
“V”
],
“phase_A_voltage”: [
107.8,
“V”
],
“phase_B_voltage”: [
0.2,
“V”
],
“phase_C_voltage”: [
0.0,
“V”
],
“phase_A_current”: [
0.348,
“A”
],
“phase_B_current”: [
0.0,
“A”
],
“phase_C_current”: [
0.0,
“A”
],
“day_active_power_peak”: [
1848,
“W”
],
“active_power”: [
0,
“W”
],
“reactive_power”: [
0,
“VA”
],
“power_factor”: [
0.999,
null
],
“grid_frequency”: [
50.0,
“Hz”
],
“efficiency”: [
100.0,
“%”
],
“internal_temperature”: [
24.0,
“\u00b0C”
],
“insulation_resistance”: [
30.0,
“MOhm”
],
“device_status”: [
“On-grid”,
null
],
“fault_code”: [
0,
null
],
“startup_time”: [
“2022-12-26T07:52:11+00:00”,
null
],
“shutdown_time”: [
“2022-12-25T15:30:17+00:00”,
null
],
“accumulated_yield_energy”: [
2805.39,
“kWh”
],
“daily_yield_energy”: [
1.82,
“kWh”
],
“state_1”: [
[
“Grid-Connected”,
“Grid-Connected normally”
],
null
],
“state_2”: [
[
“Unlocked”,
“PV disconnected”,
“DSP data collection”
],
null
],
“state_3”: [
[
“On-grid”,
“Off-grid switch disabled”
],
null
],
“alarm_1”: [
[],
null
],
“alarm_2”: [
[],
null
],
“alarm_3”: [
[],
null
],
“pv_01_voltage”: [
0.0,
“V”
],
“pv_01_current”: [
0.0,
“A”
],
“pv_02_voltage”: [
0.0,
“V”
],
“pv_02_current”: [
0.0,
“A”
],
“grid_A_voltage”: [
218.1,
“V”
],
“grid_B_voltage”: [
null,
“V”
],
“grid_C_voltage”: [
null,
“V”
],
“active_grid_A_current”: [
-2.32,
“I”
],
“active_grid_B_current”: [
null,
“I”
],
“active_grid_C_current”: [
null,
“I”
],
“power_meter_active_power”: [
-384,
“W”
],
“power_meter_reactive_power”: [
330,
“Var”
],
“active_grid_power_factor”: [
-0.758,
null
],
“active_grid_frequency”: [
49.97,
“Hz”
],
“grid_exported_energy”: [
1072.21,
“kWh”
],
“grid_accumulated_energy”: [
403.3,
“kWh”
],
“grid_accumulated_reactive_power”: [
0.0,
“kVarh”
],
“meter_type”: [
0,
null
],
“active_grid_A_B_voltage”: [
null,
“V”
],
“active_grid_B_C_voltage”: [
null,
“V”
],
“active_grid_C_A_voltage”: [
null,
“V”
],
“active_grid_A_power”: [
null,
“W”
],
“active_grid_B_power”: [
null,
“W”
],
“active_grid_C_power”: [
null,
“W”
],
“storage_state_of_capacity”: [
2.0,
“%”
],
“storage_running_status”: [
2,
null
],
“storage_bus_voltage”: [
423.7,
“V”
],
“storage_bus_current”: [
0.0,
“A”
],
“storage_charge_discharge_power”: [
0,
“W”
],
“storage_total_charge”: [
946.48,
“kWh”
],
“storage_total_discharge”: [
921.77,
“kWh”
],
“storage_current_day_charge_capacity”: [
0.57,
“kWh”
],
“storage_current_day_discharge_capacity”: [
0.51,
“kWh”
]
},
“slave_0_config_data”: {
“storage_maximum_charging_power”: [
2500,
“W”
],
“storage_maximum_discharging_power”: [
2500,
“W”
],
“storage_charging_cutoff_capacity”: [
100.0,
“%”
],
“storage_discharging_cutoff_capacity”: [
0.0,
“%”
],
“storage_working_mode_settings”: [
2,
null
],
“storage_charge_from_grid_function”: [
true,
null
],
“storage_grid_charge_cutoff_state_of_charge”: [
25.0,
“%”
],
“storage_fixed_charging_and_discharging_periods”: [
[],
null
],
“storage_power_of_charge_from_grid”: [
100,
“W”
],
“storage_maximum_power_of_charge_from_grid”: [
3000,
“W”
],
“storage_time_of_use_charging_and_discharging_periods”: [
[
{
“__type”: “<class ‘huawei_solar.registers.HUAWEI_LUNA2000_TimeOfUsePeriod’>”,
“repr”: “HUAWEI_LUNA2000_TimeOfUsePeriod(start_time=0, end_time=360, charge_flag=<ChargeFlag.CHARGE: 0>, days_effective=(True, True, True, True, True, True, True))”
},
{
“__type”: “<class ‘huawei_solar.registers.HUAWEI_LUNA2000_TimeOfUsePeriod’>”,
“repr”: “HUAWEI_LUNA2000_TimeOfUsePeriod(start_time=480, end_time=1320, charge_flag=<ChargeFlag.DISCHARGE: 1>, days_effective=(True, True, True, True, True, True, True))”
}
],
null
],
“storage_excess_pv_energy_use_in_tou”: [
1,
null
],
“storage_capacity_control_mode”: [
0,
null
],
“storage_capacity_control_soc_peak_shaving”: [
20.0,
“%”
],
“storage_capacity_control_periods”: [
[
{
“__type”: “<class ‘huawei_solar.registers.PeakSettingPeriod’>”,
“repr”: “PeakSettingPeriod(start_time=0, end_time=1439, power=2000, days_effective=(True, True, True, True, True, True, True))”
}
],
null
]
}
}
}

Looks like the issue had started when i added the control period 00-23:59.

Thank you for the diagnostics file contents. It helped me rule out some problems.

Can you try again with 1.2.0 beta 5?

1 Like

Does anyone know if resetting the installer password also resets the remote management settings set by my installer?

I don’t know the installer password and I don’t want to reset it if it also resets something else

Yep, your new beta has fixed the issue!
Love your great work man!

1 Like

i had the same question but i just did it on my inverter and everything is just fine. Only the installer password has been reset

I just created an issue on Github, because I have frequent connection errors with the 1.2.x versions of the integration. This might stem from the fact that I have a bit of an unusual setup with two cascaded inverters. I do not connect to the inverters via the dongle (too slow) but instead I setup two Wifi bridges which connect to the internal APs of the inverters. Each bridge has its own IP address and I then create two instances of the huawei solar integration in HA, each connecting to one of the IPs. That works perfectly until version 1.1.6.

I have the exact same setup - I’ve only just installed 1.1.6 though, so I’ll let you know how I get on :slight_smile:

Does somebody successfully connected with modbus TCP through the dongle not the inverer’s internal wifi? I read on the github, that after the last firmware upgrade it is agin available, I updateed the inverter and the dongle, but I don’t have the option in the router settings section of the app.

Hi

don’t know if it is the new beta version or the latest update of HA, but i’m having again connection problems via Wifi - 192.168.200.1 - always errors

Do I understand it correctly that by connecting to the inverters AP one can fetch data without the need to be an installer (without the need to enable the Modbus TCP setting)? As in, I do not have the installers password and the installer does not really want to give it to me.

Hi everyone,

When my inverter is in Standby modus I am not able to write any configuration values (error message “Failed to write valua to register …. Slave Failure”.
Once the inverter is back in Grid connected modus (eg at sunrise) same values can be written without any issues.

Is this a known issue?
Is there a way to wake up the inverter?

I use a direct RS485 connection to the inverter.

Yes and no. You need to log into the inverter directly to enable Modbus/TCP. To do that you need the Installer Password for the Inverter, which you can reset yourself without any help from the Installer…and then you get all the date you need in Home Assistant.

And that will not reset the settings the installer did, only the password? That is the only thing that prevents me from trying that.

It does not reset any settings. Don’t worry, it’s pretty easy and was actually recommend to me by Huawei Support.

1 Like

I finally enabled Modbus TCP (unrestricted) and I am connected via FE to the network using the dongle. I have tried to setup the integration but it fails with could not connect error. I then downloaded QModMaster to try to debug and I managed to read some registers such as 30000 as stated in the GitHub examples. However, I am only successful in reading the data very occasionally. For example, out of the 23 attempts only 3 succeeded. Whats up with that? Could that be why the integration is not working? Any idea what could be the cause?

Hi i have problem with connection . I can connect and after some time inverter disconnect me and after that the integration always show failed to connect . Have somebody similar behavior ?


Seems almost like my issue above. My issue just got fixed by updating to later firmware on the dongle (if you are using a cable to connect to the inverter).

Same for me.