I’m also having the same exact issue. HA successfully finds my AC with this component and I can run a fan command “sometimes”. However, even though I hear my AC beep confirm the call into action from it, HA still errors out with the same [Wrong response error]. See below.
I’m running python3.7 since 3.6 is being phased out after HA version 103.
Wrong response for type 101_0: f4f50140490100fe0101010100650001000002171514808000010104000000000000008000000500000000000405084b000080000000000000000000000000000000000000000000000000000000049cf4fb
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/components/websocket_api/commands.py", line 133, in handle_call_service
connection.context(msg),
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/core.py", line 1235, in async_call
await asyncio.shield(self._execute_service(handler, service_call))
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/core.py", line 1260, in _execute_service
await handler.func(service_call)
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/helpers/entity_component.py", line 205, in handle_service
self._platforms.values(), func, call, service_name, required_features
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/helpers/service.py", line 336, in entity_service_call
future.result() # pop exception if have
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/helpers/service.py", line 358, in _handle_service_platform_call
await getattr(entity, func)(**data)
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/components/hisense_aehw4a1/climate.py", line 424, in async_set_hvac_mode
await self.async_turn_off()
File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/components/hisense_aehw4a1/climate.py", line 438, in async_turn_off
await self._device.command("off")
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 68, in command
return await self._update_command(member)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 75, in _update_command
if (await self._check_response(packet_type, pure_bytes)):
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 131, in _check_response
f"Wrong response for type {packet_type}: {pure_bytes.hex()}"
pyaehw4a1.exceptions.WrongRespError: Wrong response for type 101_0: f4f50140490100fe0101010100650001000002171514808000010104000000000000008000000500000000000405084b000080000000000000000000000000000000000000000000000000000000049cf4fb
I followed the commands that you pasted earlier, attempting to see what commands I actually get a successful return from. Only the first and the last "seemed to work but I don’t understand this code either.
Here’s the outputs. They’re labeled.
> python -m pyaehw4a1 version --host 192.168.99.142
usage: aehw4a1 [-h] {discovery,AC,check} ...
aehw4a1: error: argument choise: invalid choice: 'version' (choose from 'discovery', 'AC', 'check')
> python -m pyaehw4a1 check --host 192.168.99.142
Found!
> python -m pyaehw4a1 AC --host 192.168.99.142
AC 192.168.99.142 status_102_0 :
{
"wind_status": "00001110",
"sleep_status": "0000000",
"mode_status": "0000",
"run_status": "1",
"direction_status": "10",
"indoor_temperature_setting": "00010111",
"indoor_temperature_status": "00010101",
"indoor_pipe_temperature": "00010100",
"indoor_humidity_setting": "10000000",
"indoor_humidity_status": "10000000",
"somatosensory_temperature": "00000000",
"somatosensory_compensation": "00000",
"somatosensory_compensation_ctrl": "001",
"temperature_compensation": "00000",
"temperature_Fahrenheit": "0",
"timer": "00000100",
"hour": "00000000",
"minute": "00000000",
"poweron_hour": "00000",
"poweron_minute": "000000",
"poweron_status": "0",
"poweroff_hour": "00000",
"poweroff_minute": "000000",
"poweroff_status": "0",
"drying": "0000",
"wind_door": "0000",
"up_down": "1",
"left_right": "0",
"nature": "0",
"heat": "0",
"low_power": "0",
"low_electricity": "0",
"efficient": "0",
"dual_frequency": "0",
"dew": "0",
"swap": "0",
"indoor_clear": "0",
"outdoor_clear": "0",
"smart_eye": "0",
"mute": "0",
"voice": "0",
"smoke": "0",
"back_led": "1",
"display_led": "0",
"indicate_led": "0",
"indoor_led": "0",
"filter_reset": "0",
"left_wind": "0",
"right_wind": "0",
"indoor_electric": "0",
"auto_check": "0",
"time_laps": "0",
"rev23": "0001",
"sample": "0",
"indoor_eeprom": "1",
"indoor_temperature_sensor": "0",
"indoor_temperature_pipe_sensor": "0",
"indoor_humidity_sensor": "0",
"indoor_water_pump": "0",
"indoor_machine_run": "0",
"indoor_bars": "0",
"indoor_zero_voltage": "0",
"indoor_outdoor_communication": "0",
"display_communication": "0",
"keypad_communication": "0",
"wifi_communication": "0",
"electric_communication": "0",
"eeprom_communication": "0",
"rev25": "000",
"compressor_frequency": "00000000",
"compressor_frequency_setting": "00000000",
"compressor_frequency_send": "00000000",
"outdoor_temperature": "00001001",
"outdoor_condenser_temperature": "00001010",
"compressor_exhaust_temperature": "00010010",
"target_exhaust_temperature": "01001011",
"expand_threshold": "00000000",
"UAB_HIGH": "00000000",
"UAB_LOW": "10000000",
"UBC_HIGH": "00000000",
"UBC_LOW": "00000000",
"UCA_HIGH": "00000000",
"UCA_LOW": "00000000",
"IAB": "00000000",
"IBC": "00000000",
"ICA": "00000000",
"generatrix_voltage_high": "00000000",
"generatrix_voltage_low": "00000000",
"IUV": "00000000",
"rev46": "000",
"four_way": "0",
"outdoor_machine": "0",
"wind_machine": "000",
"rev47": "00000000",
"rev48": "00000000",
"rev49": "00000000",
"rev50": "00000000",
"rev51": "00000000",
"rev52": "00000000",
"rev53": "00000000",
"rev54": "00000000",
"rev55": "00000000",
"rev56": "00000000"
}
> python -m pyaehw4a1 AC --host 192.168.99.142 --command status_3_0
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 57, in <module>
main()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 42, in main
parsed = asyncio.run(client.command(command))
File "/usr/lib/python3.7/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.7/asyncio/base_events.py", line 583, in run_until_complete
return future.result()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 58, in command
return await self._read_command(member)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 87, in _read_command
result = await self._bits_value(packet_type, pure_bytes, data_start_pos)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 117, in _bits_value
raise UnkDataError(f"Unknown data type {packet_type}: {binary_data}")
pyaehw4a1.exceptions.UnkDataError: Unknown data type 3_0: 00000001
> python -m pyaehw4a1 AC --host 192.168.99.142 --command status_3_1
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 57, in <module>
main()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 42, in main
parsed = asyncio.run(client.command(command))
File "/usr/lib/python3.7/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.7/asyncio/base_events.py", line 583, in run_until_complete
return future.result()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 58, in command
return await self._read_command(member)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 87, in _read_command
result = await self._bits_value(packet_type, pure_bytes, data_start_pos)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 117, in _bits_value
raise UnkDataError(f"Unknown data type {packet_type}: {binary_data}")
pyaehw4a1.exceptions.UnkDataError: Unknown data type 3_1: 00000001
> python -m pyaehw4a1 AC --host IP_ADDRESS --command status_7_1
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 57, in <module>
main()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 42, in main
parsed = asyncio.run(client.command(command))
File "/usr/lib/python3.7/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.7/asyncio/base_events.py", line 583, in run_until_complete
return future.result()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 58, in command
return await self._read_command(member)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 87, in _read_command
result = await self._bits_value(packet_type, pure_bytes, data_start_pos)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 117, in _bits_value
raise UnkDataError(f"Unknown data type {packet_type}: {binary_data}")
pyaehw4a1.exceptions.UnkDataError: Unknown data type 7_1: 0000000100010000000000100001010100000001
> python -m pyaehw4a1 AC --host 192.168.99.142 --command status_10_4
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 57, in <module>
main()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/__main__.py", line 42, in main
parsed = asyncio.run(client.command(command))
File "/usr/lib/python3.7/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.7/asyncio/base_events.py", line 583, in run_until_complete
return future.result()
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 58, in command
return await self._read_command(member)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 87, in _read_command
result = await self._bits_value(packet_type, pure_bytes, data_start_pos)
File "/srv/homeassistant/lib/python3.7/site-packages/pyaehw4a1/aehw4a1.py", line 117, in _bits_value
raise UnkDataError(f"Unknown data type {packet_type}: {binary_data}")
pyaehw4a1.exceptions.UnkDataError: Unknown data type 10_4: 000000010000000100000001
> python -m pyaehw4a1 AC --host 192.168.99.142 --command status_102_64 AC 192.168.99.142 status_102_64 :
{
"ONE_KWH_I": "00001001",
"ONE_KWH_F": "00000100",
"ONE_KWH_D": "11010110",
"KWH_DAY": "00000101",
"KWH_WEEK_H": "00000111",
"KWH_WEEK_L": "11101010",
"KWH_MONTH_H": "00000001",
"KWH_MONTH_L": "01110000",
"KWH_QUARTER_H": "01001000",
"KWH_QUARTER_L": "10000000",
"KWH_HALFYEAR_H": "10000000",
"KWH_HALFYEAR_L": "00000000",
"KWH_YEAR_H": "00000000",
"KWH_YEAR_L": "00000000",
"KWH_H": "00000000",
"KWH_SH": "00000000",
"KWH_SL": "00000000",
"KWH_L": "00000101"
}
Could you assist as well, me, in your investigation on what’s going on here? Thanks!