wills106 / homeassistant-solax-modbus

SolaX Power Modbus custom_component for Home Assistant (Supports some AlphaESS, Growatt, Sofar, Solinteg, Solis, SRNE, Swatten)
317 stars 101 forks source link

[Bug]: Integration stops updating after some time #816

Closed ruimmsimoes closed 7 months ago

ruimmsimoes commented 7 months ago

Describe the bug

Last few weeks once/ twice a day the integration stops updating values.

This week the problems started occurring more often (many times a day). I created an automation to reload the integration, and after the reload the data starts flowing again.

The integration had been working without any problem for several months.

Integration Version

2024.03.6

Homeassistant core version

2024.3.1

Inverter brand

SolaX Power

Plugin used

plugin_solax.py

Serial prefix

H34A15

Inverter firmware versions

ARM 1.35 and DSP 1.33

Connection Method

Generic USB RS-485 adapter

Dongle firmware

Serial connection

Detailed Error Log

2024-03-19 15:31:06.273 INFO (MainThread) [homeassistant.setup] Setting up solax_modbus
2024-03-19 15:31:06.273 INFO (MainThread) [homeassistant.setup] Setup of domain solax_modbus took 0.0 seconds
2024-03-19 15:31:06.277 INFO (MainThread) [custom_components.solax_modbus.config_flow] detected HA core version 2024 3
2024-03-19 15:31:06.277 INFO (MainThread) [custom_components.solax_modbus.config_flow] starting configflow - domain = solax_modbus
2024-03-19 15:31:06.277 INFO (MainThread) [custom_components.solax_modbus] trying to load plugin - plugin_name: solax

2024-03-19 15:31:56.682 INFO (MainThread) [custom_components.solax_modbus] Inverter is not connected, trying to connect
2024-03-19 15:31:56.684 INFO (MainThread) [custom_components.solax_modbus] Inverter connected at /dev/ttyUSB0:0
2024-03-19 15:31:56.684 INFO (MainThread) [custom_components.solax_modbus.plugin_solax] SolaX: trying to determine inverter type

2024-03-19 15:31:56.781 INFO (MainThread) [custom_components.solax_modbus.plugin_solax] Read SolaX 0x0 serial number before potential swap: **************
2024-03-19 15:31:56.807 INFO (MainThread) [homeassistant.components.button] Setting up solax_modbus.button
2024-03-19 15:31:56.808 INFO (MainThread) [custom_components.solax_modbus.button] hub.wakeuButton: SolaxModbusButtonEntityDescription(key='battery_awaken', device_class=None, entity_category=None, entity_registry_enabled_default=False, entity_registry_visible_default=True, force_update=False, icon='mdi:battery-alert-variant', has_entity_name=False, name='Battery Awaken', translation_key=None, translation_placeholders=None, unit_of_measurement=None, allowedtypes=6144, register=86, command=1, blacklist=None, write_method=1, value_function=None, autorepeat=None)
2024-03-19 15:31:56.811 INFO (MainThread) [homeassistant.components.number] Setting up solax_modbus.number
2024-03-19 15:31:56.819 INFO (MainThread) [homeassistant.components.select] Setting up solax_modbus.select
2024-03-19 15:31:56.828 INFO (MainThread) [homeassistant.components.sensor] Setting up solax_modbus.sensor
2024-03-19 15:31:56.845 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x0 seriesnumber to block with start 0x0
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x1d safety_code to block with start 0x0
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x1e matebox_enabled to block with start 0x0
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] Starting new block at 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x7d firmware_DSP_minor_version to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x7e firmware_DSP_hardware_version to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x7f firmware_DSP_major_version to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x80 firmware_ARM_major_version to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x81 firmwareversion_modbustcp_major to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x82 firmwareversion_modbustcp_minor to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x83 firmware_ARM_minor_version to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x84 bootloader_version to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x85 rtc to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x8b charger_use_mode to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x8c manual_mode to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x8d battery_type to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x8e battery_charge_float_voltage to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x8f battery_discharge_cut_off_voltage to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x90 battery_charge_max_current to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x91 battery_discharge_max_current to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x94 selfuse_nightcharge_upper_soc to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x97 charger_start_time_1 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x98 charger_end_time_1 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x99 discharger_start_time_1 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9a discharger_end_time_1 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9b charge_period2_enable to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9c charger_start_time_2 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9d charger_end_time_2 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9e discharger_start_time_2 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9f discharger_end_time_2 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa1 hotstandby to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa2 extend_bms_setting to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa3 battery_heating to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa4 battery_heating_start_time_1 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa5 battery_heating_end_time_1 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa6 battery_heating_start_time_2 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa7 battery_heating_end_time_2 to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xaa registration_code_pocket to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb2 pgrid_bias to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb5 export_control_factory_limit to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb6 export_control_user_limit to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb8 eps_min_soc to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb9 eps_frequency_test to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xba inverter_rate_power to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xbb language to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xbc mppt_toggle to block with start 0x7d
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] Starting new block at 0x102
2024-03-19 15:31:56.846 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x102 drm_function_enable to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x103 ct_type to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x104 shadow_fix_enable to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x105 machine_type to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x106 phase_power_balance_x3 to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x107 machine_style to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x108 meter_function to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x109 meter_1_id to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x10a meter_2_id to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x10e battery_charge_upper_soc to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x111 disch_cut_off_point_different to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x113 disch_cut_off_voltage_grid_mode to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x114 shadow_fix2_enable to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x115 ct_meter_setting to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x116 fvrt_function to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x117 fvrt_vac_upper to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x118 fvrt_vac_lower to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x11b pv_connection_mode to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x11c shutdown to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x11d microgrid to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x11e selfuse_mode_backup to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x11f selfuse_backup_soc to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x120 lease_mode to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x121 device_lock to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x122 manual_mode_control to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x123 feedin_on_power to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x124 switch_on_soc to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x125 consume_off_power to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x126 switch_off_soc to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x127 minimum_per_on_signal to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x128 maximum_per_day_on to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x129 schedule to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x130 parallel_setting to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x14f peakshaving_discharge_start_time_1 to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x150 peakshaving_discharge_stop_time_1 to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x151 peakshaving_discharge_start_time_2 to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x152 peakshaving_discharge_stop_time_2 to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x153 peakshaving_discharge_limit_1 to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x154 peakshaving_discharge_limit_2 to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x155 peakshaving_charge_from_grid to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x156 peakshaving_charge_limit to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x157 peakshaving_max_soc to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x158 peakshaving_reserved_soc to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x160 ct_cycle_detection to block with start 0x102
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x0 inverter_voltage to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x1 inverter_current to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x2 inverter_load to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x3 pv_voltage_1 to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x4 pv_voltage_2 to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x5 pv_current_1 to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x6 pv_current_2 to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x7 grid_frequency to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x8 inverter_temperature to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9 run_mode to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa pv_power_1 to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb pv_power_2 to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x13 time_count_down to block with start 0x0
2024-03-19 15:31:56.847 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x14 battery_voltage_charge to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x15 battery_current_charge to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x16 battery_power_charge to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x17 bms_connect_state to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x18 battery_temperature to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x1a grid_status to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x1c battery_capacity_charge to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x1d output_energy_charge to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x20 output_energy_charge_today to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x21 input_energy_charge to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x23 input_energy_charge_today to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x24 bms_charge_max_current to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x25 bms_discharge_max_current to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x26 bms_battery_capacity to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x46 measured_power to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x48 grid_export_total to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x4a grid_import_total to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x50 today_yield to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x52 total_yield to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x54 lock_state to block with start 0x0
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] Starting new block at 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x66 bus_volt to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x67 dc_fault_val to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x68 overload_fault_val to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x69 battery_volt_fault_val to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x6a grid_voltage_l1 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x6b grid_current_l1 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x6c grid_power_l1 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x6d grid_frequency_l1 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x6e grid_voltage_l2 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x6f grid_current_l2 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x70 grid_power_l2 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x71 grid_frequency_l2 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x72 grid_voltage_l3 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x73 grid_current_l3 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x74 grid_power_l3 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x75 grid_frequency_l3 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x82 measured_power_l1 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x84 measured_power_l2 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x86 measured_power_l3 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x88 grid_mode_runtime to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x91 e_charge_today to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x92 e_charge_total to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x94 solar_energy_total to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x96 solar_energy_today to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x98 export_energy_today to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x9a import_energy_today to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xa8 meter_2_measured_power to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xaa meter_2_export_total to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xac meter_2_import_total to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xae meter_2_export_today to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb0 meter_2_import_today to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb2 meter_2_measured_power_l1 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb4 meter_2_measured_power_l2 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb6 meter_2_measured_power_l3 to block with start 0x66
2024-03-19 15:31:56.848 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb8 meter_1_communication_state to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xb9 meter_2_communication_state to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xba battery_temperature_high to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xbb battery_temperature_low to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xbc cell_voltage_high to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xbd cell_voltage_low to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xbf battery_soh to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xc8 grid_frequency_meter to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xc9 grid_voltage_meter to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xca grid_voltage_meter_l1 to block with start 0x66
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] Starting new block at 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xcb grid_voltage_meter_l2 to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0xcc grid_voltage_meter_l3 to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x100 modbus_power_control to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x101 target_finish_flag to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x102 active_power_target to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x104 reactive_power_target to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x106 active_power_real to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x108 reactive_power_real to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x10a active_power_upper to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x10c active_power_lower to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x10e reactive_power_upper to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x110 reactive_power_lower to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x114 charge_discharge_power to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x116 chargeable_battery_capacity to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] adding register 0x118 remaining_battery_capacity to block with start 0xcb
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] SolaX returning holding block: 0x0 0x1f [0, 29, 30]
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] SolaX returning holding block: 0x7d 0xbd [125, 126, 127, 128, 129, 130, 131, 132, 133, 139, 140, 141, 142, 143, 144, 145, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, 161, 162, 163, 164, 165, 166, 167, 170, 178, 181, 182, 184, 185, 186, 187, 188]
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] SolaX returning holding block: 0x102 0x161 [258, 259, 260, 261, 262, 263, 264, 265, 266, 270, 273, 275, 276, 277, 278, 279, 280, 283, 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, 304, 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, 352]
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] SolaX returning input block: 0x0 0x55 [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 19, 20, 21, 22, 23, 24, 26, 28, 29, 32, 33, 35, 36, 37, 38, 70, 72, 74, 80, 82, 84]
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] SolaX returning input block: 0x66 0xcb [102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 130, 132, 134, 136, 145, 146, 148, 150, 152, 154, 168, 170, 172, 174, 176, 178, 180, 182, 184, 185, 186, 187, 188, 189, 191, 200, 201, 202]
2024-03-19 15:31:56.849 INFO (MainThread) [custom_components.solax_modbus.sensor] SolaX returning input block: 0xcb 0x11a [203, 204, 256, 257, 258, 260, 262, 264, 266, 268, 270, 272, 276, 278, 280]
2024-03-19 15:31:56.853 INFO (MainThread) [custom_components.solax_modbus.sensor] computedRegs: {'grid_export': SolaXModbusSensorEntityDescription(key='grid_export', device_class=<SensorDeviceClass.POWER: 'power'>, entity_category=None, entity_registry_enabled_default=True, entity_registry_visible_default=True, force_update=False, icon='mdi:home-export-outline', has_entity_name=False, name='Grid Export', translation_key=None, translation_placeholders=None, unit_of_measurement=None, last_reset=None, native_unit_of_measurement=<UnitOfPower.WATT: 'W'>, options=None, state_class=<SensorStateClass.MEASUREMENT: 'measurement'>, suggested_display_precision=None, suggested_unit_of_measurement=None, allowedtypes=6174, scale=1, read_scale_exceptions=None, read_scale=1, blacklist=None, register=-1, rounding=1, register_type=1, unit='_uint16', newblock=False, value_function=<function value_function_grid_export at 0x7f34b0900180>, wordcount=None, sleepmode=1, ignore_readerror=False), 'grid_import': SolaXModbusSensorEntityDescription(key='grid_import', device_class=<SensorDeviceClass.POWER: 'power'>, entity_category=None, entity_registry_enabled_default=True, entity_registry_visible_default=True, force_update=False, icon='mdi:home-import-outline', has_entity_name=False, name='Grid Import', translation_key=None, translation_placeholders=None, unit_of_measurement=None, last_reset=None, native_unit_of_measurement=<UnitOfPower.WATT: 'W'>, options=None, state_class=<SensorStateClass.MEASUREMENT: 'measurement'>, suggested_display_precision=None, suggested_unit_of_measurement=None, allowedtypes=6174, scale=1, read_scale_exceptions=None, read_scale=1, blacklist=None, register=-1, rounding=1, register_type=1, unit='_uint16', newblock=False, value_function=<function value_function_grid_import at 0x7f34b09000e0>, wordcount=None, sleepmode=1, ignore_readerror=False), 'house_load': SolaXModbusSensorEntityDescription(key='house_load', device_class=<SensorDeviceClass.POWER: 'power'>, entity_category=None, entity_registry_enabled_default=True, entity_registry_visible_default=True, force_update=False, icon='mdi:home-lightning-bolt', has_entity_name=False, name='House Load', translation_key=None, translation_placeholders=None, unit_of_measurement=None, last_reset=None, native_unit_of_measurement=<UnitOfPower.WATT: 'W'>, options=None, state_class=<SensorStateClass.MEASUREMENT: 'measurement'>, suggested_display_precision=None, suggested_unit_of_measurement=None, allowedtypes=6174, scale=1, read_scale_exceptions=None, read_scale=1, blacklist=None, register=-1, rounding=1, register_type=1, unit='_uint16', newblock=False, value_function=<function value_function_house_load at 0x7f34b0900220>, wordcount=None, sleepmode=1, ignore_readerror=False), 'house_load_alt': SolaXModbusSensorEntityDescription(key='house_load_alt', device_class=<SensorDeviceClass.POWER: 'power'>, entity_category=None, entity_registry_enabled_default=False, entity_registry_visible_default=True, force_update=False, icon='mdi:home-lightning-bolt', has_entity_name=False, name='House Load Alt', translation_key=None, translation_placeholders=None, unit_of_measurement=None, last_reset=None, native_unit_of_measurement=<UnitOfPower.WATT: 'W'>, options=None, state_class=<SensorStateClass.MEASUREMENT: 'measurement'>, suggested_display_precision=None, suggested_unit_of_measurement=None, allowedtypes=6174, scale=1, read_scale_exceptions=None, read_scale=1, blacklist=None, register=-1, rounding=1, register_type=1, unit='_uint16', newblock=False, value_function=<function value_function_house_load_alt at 0x7f34b09002c0>, wordcount=None, sleepmode=1, ignore_readerror=False), 'pv_power_total': SolaXModbusSensorEntityDescription(key='pv_power_total', device_class=<SensorDeviceClass.POWER: 'power'>, entity_category=None, entity_registry_enabled_default=True, entity_registry_visible_default=True, force_update=False, icon='mdi:solar-power-variant', has_entity_name=False, name='PV Power Total', translation_key=None, translation_placeholders=None, unit_of_measurement=None, last_reset=None, native_unit_of_measurement=<UnitOfPower.WATT: 'W'>, options=None, state_class=<SensorStateClass.MEASUREMENT: 'measurement'>, suggested_display_precision=None, suggested_unit_of_measurement=None, allowedtypes=4096, scale=1, read_scale_exceptions=None, read_scale=1, blacklist=None, register=-1, rounding=1, register_type=1, unit='_uint16', newblock=False, value_function=<function value_function_pv_power_total at 0x7f34b086fd80>, wordcount=None, sleepmode=1, ignore_readerror=False), 'remotecontrol_autorepeat_remaining': SolaXModbusSensorEntityDescription(key='remotecontrol_autorepeat_remaining', device_class=None, entity_category=None, entity_registry_enabled_default=True, entity_registry_visible_default=True, force_update=False, icon='mdi:home-clock', has_entity_name=False, name='Remotecontrol Autorepeat Remaining', translation_key=None, translation_placeholders=None, unit_of_measurement=None, last_reset=None, native_unit_of_measurement=<UnitOfTime.SECONDS: 's'>, options=None, state_class=<SensorStateClass.MEASUREMENT: 'measurement'>, suggested_display_precision=None, suggested_unit_of_measurement=None, allowedtypes=6168, scale=1, read_scale_exceptions=None, read_scale=1, blacklist=None, register=-1, rounding=1, register_type=1, unit='_uint16', newblock=False, value_function=<function value_function_remotecontrol_autorepeat_remaining at 0x7f34b08f6fc0>, wordcount=None, sleepmode=1, ignore_readerror=False)}

2024-03-19 15:32:27.350 INFO (MainThread) [custom_components.solax_modbus] no local data file found after 5 tries - is this a first time run? or didnt you modify any DATA_LOCAL entity?

2024-03-19 15:35:14.435 INFO (MainThread) [custom_components.solax_modbus] exception Modbus Error: [Connection] Not connected[AsyncModbusSerialClient /dev/ttyUSB0:0] : SolaX cannot read holding registers at device 1 position 0x0

2024-03-19 16:54:50.585 INFO (MainThread) [custom_components.solax_modbus] exception Modbus Error: [Input/Output] ERROR: No response received after 3 retries : SolaX cannot read holding registers at device 1 position 0x0
NoneType: None
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0x9c: charger_start_time_2
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0x9d: charger_end_time_2
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0x9e: discharger_start_time_2
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0x9f: discharger_end_time_2
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xa1: hotstandby
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xa2: extend_bms_setting
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xa3: battery_heating
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xa4: battery_heating_start_time_1
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xa5: battery_heating_end_time_1
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xa6: battery_heating_start_time_2
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xa7: battery_heating_end_time_2
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xb2: pgrid_bias
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xb5: export_control_factory_limit
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xb6: export_control_user_limit
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xb8: eps_min_soc
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xb9: eps_frequency_test
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xba: inverter_rate_power
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xbb: language
2024-03-19 16:55:27.329 WARNING (MainThread) [custom_components.solax_modbus] SolaX: read failed at 0xbc: mppt_toggle

Additional context

No response

simondrake commented 7 months ago

+1 same here. I take some solace in the fact I'm not alone, as I was going mad trying to figure out what was wrong on my end.

@ruimmsimoes - can you share the automation that does the reload, please?

anton4 commented 7 months ago

I had to revert back to 2024.02.7b2 and that version is working fine.

simondrake commented 7 months ago

I don't see that in the list of versions, on mobile at least, did you download it manually?

ruimmsimoes commented 7 months ago

Here is the automation I created, it also notifies me every time the integration is restarted:

alias: Reiniciar integração SolaX
description: ""
trigger:
  - platform: template
    value_template: >-
      {{ now() - states.sensor.solax_house_load.last_updated >=
      timedelta(minutes=15) }}
condition: []
action:
  - service: homeassistant.reload_config_entry
    metadata: {}
    data:
      entry_id: 277a443271216e367913be7bf7e5794b
  - service: notify.mobile_app_iphonex_de_rui
    metadata: {}
    data:
      title: Reiniciada integração SolaX
      message: >-
        Dados SolaX sem actualização à mais de 15 minutos, integração
        reinicializada.
mode: single

To find out the entry_id of your integration, using the file editor, go to file /homeassistant/.storage/core.config_entries and search for 'solax_modbus'.

Unfortunately the automation is executing more than twice every hour.

ruimmsimoes commented 7 months ago

I had to revert back to 2024.02.7b2 and that version is working fine.

I also can't revert back to that version. The earliest it lets me revert to is 2024.03.2. @anton4 How did you manage to revert?

If that version is working then the problem is probably with the changes put in place in version 2024.03.1.

wills106 commented 7 months ago

By default HACS only shows the previous 5 https://hacs.xyz/docs/configuration/options

simondrake commented 7 months ago

@ruimmsimoes - thanks.

I changed to using config_entry_id. For anybody else seeing this, if you want to validate it's correct- you can run the following:

cat homeassistant/.storage/core.config_entries | jq -r '.data.entries | .[] | select(.title == '<integration name>' | .entry_id'

Thanks @wills106 - I see it now. I've just updated to the newest version, so I'll see if the issue happens again and, if it does, I'll downgrade.

anton4 commented 7 months ago

I don't see that in the list of versions, on mobile at least, did you download it manually?

Yes, I did it manually, but @wills106 pointed out you can modify the default HACS (5 previous versions) to show earlier versions also.

PatrikTrestik commented 7 months ago

It also happened to me. Can you confirm that you are using any "remotecontrol" automation?

I had impression that after disabling my remote control it works without issue. I specifically blame "Enabled No Discharge". Checking the code.

ruimmsimoes commented 7 months ago

Downgraded to integration version 2024.02.6 and since downgrading the integration only had to be restarted 4 times in two days. Although not perfect it is much more stable.

Has anyone been able to find out which changes are provoking this behavior?

If you need someone to test any changes I’m available.

@PatrikTrestik I am not using any automations.

lazy-pete commented 7 months ago

Hi - I e also been seeing a lot of failures. I’m using the solax_Modbus integration as comms for fboundy’s PV_opt integration and found over the past few days that the integration is failing overnight - most evident by a huge drift between the clock sync times I see in the pv_opt dashboard, so I’m guessing the inverter time last seen is when it fails.

Logs from last night below I think - I’ll try and put in the reload automation and downgrade as above meantime.

IMG_6165

Logger: homeassistant Source: helpers/update_coordinator.py:261 First occurred: 03:26:12 (2 occurrences) Last logged: 03:26:16

Error doing job: Task exception was never retrieved Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 417, in _async_refresh self.async_update_listeners() File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 183, in async_update_listeners update_callback() File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 497, in _handle_coordinator_update self.async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 992, in async_write_ha_state self._async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1113, in _async_write_ha_state state, attr, capabilities, shadowed_attr = self.async_calculate_state() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1050, in async_calculate_state state = self._stringify_state(available) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 998, in _stringify_state if (state := self.state) is None: ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/sensor/init.py", line 548, in state value = self.native_value ^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/devolo_home_network/sensor.py", line 229, in native_value next( StopIteration

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 261, in _handle_refresh_interval await self._async_refresh(log_failures=True, scheduled=True) RuntimeError: coroutine raised StopIteration

This error originated from a custom integration.

Logger: pymodbus.logging Source: custom_components/solax_modbus/init.py:388 integration: SolaX Inverter Modbus (documentation, issues) First occurred: 25 March 2024 at 23:48:14 (61 occurrences) Last logged: 03:27:55

Failed to connect Failed to connect [Errno 113] Connect call failed ('192.168.1.25', 502)

This error originated from a custom integration.

Logger: custom_components.solax_modbus Source: custom_components/solax_modbus/init.py:393 integration: SolaX Inverter Modbus (documentation, issues) First occurred: 25 March 2024 at 23:48:14 (61 occurrences) Last logged: 03:27:55

Unable to connect to Inverter at 192.168.1.25:502

lazy-pete commented 7 months ago

I’m wondering from some of the above whether it’s actually a local networking fail to communicate with the EW11 dongle, although a HA restart seems to fix things which would counter that.

simondrake commented 7 months ago

Downgrading to 2024.03.7b4 didn't fix the issue for me, it would occasionally zero out all the stats and only a HA restart fixes the issue - integration reload didn't.

I've upgraded to 2024.03.7b4 again, but if anyone has a confirmed working version please share it.

The fact a HA restart fixes the problem, I'd hazard a guess it's an issue inside HA.

matomatusov commented 7 months ago

@simondrake I think version 2024.02.5 is stable. I was also reverting to lower versions.

mlj11 commented 7 months ago

I have the same problem. The integration stops working and the only soulution is to restart HA. It stops working usually when the remote control is activated and within a few seconds/minutes it stops updating (not always, but very likely). There is probably a delay when reading data, because the entities are not updated at 15s interval, but with some delays (15-25s). I've gone back a few versions and can confirm that I don't see this issue with version 2024.02.6. The remote control works correctly and the updates are done exactly at 15s intervals.

johny-mnemonic commented 7 months ago

I can confirm the same behavior. Integration works just fine till you try to use Remotecontrol. No matter whether it's from automation or manually.

Seems like the integration gets completely stuck as only restart of HA helps. Trying to reload the integration just gets the service stuck as well.

Here is my debug log output:

2024-03-29 04:16:56.041 DEBUG (MainThread) [custom_components.solax_modbus.plugin_solax] Evaluated remotecontrol_trigger: corrected/clamped values: [('remotecontrol_power_control', 'Enabled Power Control'), ('remotecontrol_set_type', 'Set'), ('remotecontrol_active_power', 3000.0), ('remotecontrol_reactive_power', 0), ('remotecontrol_duration', 20.0)]
2024-03-29 04:16:56.042 DEBUG (MainThread) [custom_components.solax_modbus] Ready to write multiple registers at 0x7c: [1, 1, 3000, 0, 0, 0, 20]
2024-03-29 04:17:02.477 DEBUG (MainThread) [custom_components.solax_modbus.plugin_solax] Evaluated remotecontrol_trigger: corrected/clamped values: [('remotecontrol_power_control', 'Enabled Power Control'), ('remotecontrol_set_type', 'Set'), ('remotecontrol_active_power', 3000.0), ('remotecontrol_reactive_power', 0), ('remotecontrol_duration', 20.0)]
2024-03-29 04:17:02.477 DEBUG (MainThread) [custom_components.solax_modbus] ready to repeat button remotecontrol_trigger data: [('remotecontrol_power_control', 'Enabled Power Control'), ('remotecontrol_set_type', 'Set'), ('remotecontrol_active_power', 3000.0), ('remotecontrol_reactive_power', 0), ('remotecontrol_duration', 20.0)]
2024-03-29 04:23:04.534 WARNING (MainThread) [homeassistant.components.automation.solax_not_updated] Solax not updated : Already running

It basically sets the Remotecontrol and immediately gets stuck. Probably it is somewhere in the autorepeat function.

I have an automation to detect stuck Solax integration and reload the integration, but as you can see on the last line, it reports Already running as the service which tries to reload the integration got stuck as well trying to reload the integration...

Downgrade to 2024.02.6 fixed it for me as well.

PatrikTrestik commented 7 months ago

It also crashed for me while using Remote control. But it works when I use only "Enable Power Control" which does no calculation and only sets "Active Power Target".

I'm going to check code if there is something obvious.

PatrikTrestik commented 7 months ago

Hang in debugger, good. It seams that there is some locking problem. I would like to fix it today if I find a time.

adamhf commented 7 months ago

@PatrikTrestik I'm seeing the same issue as you, issuing a PowerControl command such as 'No Discharge' causes the integration to lock up. Reverting to 2024.02.6 seems to have resolved the issue. I saw it for the first time last night after a reboot, I've kept up to date with HA core releases and versions of this plugin so unsure which combination caused the issue to surface.

Edit: This is with a Solax G4 3.7Kw Hybrid and the Waveshare RS485

Looking at my update history, this issue started after updating to 2024.03.07 from 2024.03.06 whilst running HA Core 2024.3.3

PatrikTrestik commented 7 months ago

https://github.com/wills106/homeassistant-solax-modbus/pull/827 should help.

If you have time please test from my branch even before it is merged.

simondrake commented 7 months ago

image

Still happening for me. @wills106 - can we reopen this?

lazy-pete commented 7 months ago

Also still having to reboot HA periodically

P

On Mon, 1 Apr 2024 at 15:30, Simon Drake @.***> wrote:

28120F89-654E-4FC5-81C7-CBBC38048AAB.jpeg (view on web) https://github.com/wills106/homeassistant-solax-modbus/assets/62928647/efeb6c5f-4bd1-4b52-bc68-0ac07a17050d

Still happening for me. @wills106 https://github.com/wills106 - can we reopen this?

— Reply to this email directly, view it on GitHub https://github.com/wills106/homeassistant-solax-modbus/issues/816#issuecomment-2029847564, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHMEIQYVC3USFC32F5FGLADY3FVO7AVCNFSM6AAAAABFBVRUNCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMRZHA2DONJWGQ . You are receiving this because you commented.Message ID: @.***>