Android TV Remote Mibox 4

Hi,

My Android TV Remote integration after long time working now stoped working, after remove integration and setup again. Cannot connect to Mibox. I have two Mibox devices “S” and “4” models.
Both Mibox IP address is dhcp static lease from the router.
Mibox4 is 192.168.222.5 FAILED (android 9)
MiboxS is 192.168.222.10 OK (android 11)

The message when try to add 192.168.222.5 is:

Failed to connect

I tryed to change IP address from .5 to .6 but result is the same.
Also tryed to remove integration and add again.
Also reset Mibox 4 (enable developers options to prevent sleep)

  • Core2024.8.3
  • Supervisor2024.08.0
  • Operating System13.1
  • Frontend20240809.0

Here is debug log when i add devices to integration.

	Line 1123: 2024-08-27 09:44:31.558 DEBUG (MainThread) [androidtvremote2] Connected to ('192.168.222.5', 6467)
	Line 1124: 2024-08-27 09:44:31.559 DEBUG (MainThread) [androidtvremote2] Sending: protocol_version: 2 status: STATUS_OK pairing_request { service_name: "atvremote" client_name: "Home Assistant" }
	Line 1125: 2024-08-27 09:44:31.565 DEBUG (MainThread) [androidtvremote2] Received: 
	Line 1126: 2024-08-27 09:44:31.565 DEBUG (MainThread) [androidtvremote2] Unhandled msg: 
	Line 1127: 2024-08-27 09:44:31.567 DEBUG (MainThread) [androidtvremote2] Received: 
	Line 1128: 2024-08-27 09:44:31.567 DEBUG (MainThread) [androidtvremote2] Unhandled msg: 
	Line 1129: 2024-08-27 09:44:31.567 DEBUG (MainThread) [androidtvremote2] Received: 
	Line 1130: 2024-08-27 09:44:31.568 DEBUG (MainThread) [androidtvremote2] Unhandled msg: 
	Line 1131: 2024-08-27 09:44:31.574 DEBUG (MainThread) [androidtvremote2] Connection lost. Error: [SSL: APPLICATION_DATA_AFTER_CLOSE_NOTIFY] application data after close notify (_ssl.c:2685)
	Line 1132: 2024-08-27 09:44:35.452 DEBUG (MainThread) [androidtvremote2] Connected to ('192.168.222.10', 6467)
	Line 1133: 2024-08-27 09:44:35.453 DEBUG (MainThread) [androidtvremote2] Sending: protocol_version: 2 status: STATUS_OK pairing_request { service_name: "atvremote" client_name: "Home Assistant" }
	Line 1134: 2024-08-27 09:44:35.503 DEBUG (MainThread) [androidtvremote2] Received: protocol_version: 2 status: STATUS_OK pairing_request_ack { }
	Line 1135: 2024-08-27 09:44:35.504 DEBUG (MainThread) [androidtvremote2] Sending: protocol_version: 2 status: STATUS_OK options { input_encodings { type: ENCODING_TYPE_HEXADECIMAL symbol_length: 6 } preferred_role: ROLE_TYPE_INPUT }
	Line 1136: 2024-08-27 09:44:35.554 DEBUG (MainThread) [androidtvremote2] Received: protocol_version: 2 status: STATUS_OK options { output_encodings { type: ENCODING_TYPE_HEXADECIMAL symbol_length: 6 } preferred_role: ROLE_TYPE_INPUT }
	Line 1137: 2024-08-27 09:44:35.554 DEBUG (MainThread) [androidtvremote2] Sending: protocol_version: 2 status: STATUS_OK configuration { encoding { type: ENCODING_TYPE_HEXADECIMAL symbol_length: 6 } client_role: ROLE_TYPE_INPUT }
	Line 1138: 2024-08-27 09:44:35.603 DEBUG (MainThread) [androidtvremote2] Received: protocol_version: 2 status: STATUS_OK configuration_ack { }
	Line 1139: 2024-08-27 09:44:49.729 DEBUG (MainThread) [androidtvremote2] Sending: protocol_version: 2 status: STATUS_OK secret { secret: "blablabla-replaced" }
	Line 1140: 2024-08-27 09:44:49.756 DEBUG (MainThread) [androidtvremote2] Received: protocol_version: 2 status: STATUS_OK secret_ack { secret: "blablabla-replaced" }
	Line 1143: 2024-08-27 09:44:49.915 DEBUG (MainThread) [androidtvremote2] Connected to ('192.168.222.10', 6466)
	Line 1144: 2024-08-27 09:44:49.945 DEBUG (MainThread) [androidtvremote2] Received: remote_configure { code1: 639 device_info { model: "MiTV-AFKR0" vendor: "Xiaomi" unknown1: 1 unknown2: "11" package_name: "com.google.android.tv.remote.service" app_version: "6.0.648630202" } }
	Line 1145: 2024-08-27 09:44:49.945 DEBUG (MainThread) [androidtvremote2] Device supports: [<Feature.PING|KEY|IME|POWER|VOLUME|APP_LINK|24: 639>]
	Line 1146: 2024-08-27 09:44:49.946 DEBUG (MainThread) [androidtvremote2] Sending: remote_configure { code1: 615 device_info { unknown1: 1 unknown2: "1" package_name: "atvremote" app_version: "1.0.0" } }
	Line 1147: 2024-08-27 09:44:49.954 DEBUG (MainThread) [androidtvremote2] Received: remote_set_active { }
	Line 1148: 2024-08-27 09:44:49.954 DEBUG (MainThread) [androidtvremote2] Sending: remote_set_active { active: 615 }
	Line 1149: 2024-08-27 09:44:49.992 DEBUG (MainThread) [androidtvremote2] Received: remote_set_volume_level { unknown1: 17 unknown2: 9 player_model: "MiTV-AFKR0" unknown4: 2 volume_max: 15 volume_level: 12 }
	Line 1150: 2024-08-27 09:44:49.996 DEBUG (MainThread) [androidtvremote2] Received: remote_ime_key_inject { app_info { app_package: "com.google.android.youtube.tv" } }
	Line 1151: 2024-08-27 09:44:49.998 DEBUG (MainThread) [androidtvremote2] Received: remote_start { started: true }
	Line 1168: 2024-08-27 09:45:19.757 DEBUG (MainThread) [androidtvremote2] Connection lost. Error: SSL shutdown timed out
	Line 1189: 2024-08-27 09:47:01.382 DEBUG (MainThread) [androidtvremote2] Connection lost. Error: None
	Line 1190: 2024-08-27 09:47:01.455 DEBUG (MainThread) [androidtvremote2] Connected to ('192.168.222.10', 6466)
	Line 1191: 2024-08-27 09:47:01.465 DEBUG (MainThread) [androidtvremote2] Received: remote_configure { code1: 639 device_info { model: "MiTV-AFKR0" vendor: "Xiaomi" unknown1: 1 unknown2: "11" package_name: "com.google.android.tv.remote.service" app_version: "6.0.648630202" } }
	Line 1192: 2024-08-27 09:47:01.465 DEBUG (MainThread) [androidtvremote2] Device supports: [<Feature.PING|KEY|IME|POWER|VOLUME|APP_LINK|24: 639>]
	Line 1193: 2024-08-27 09:47:01.465 DEBUG (MainThread) [androidtvremote2] Sending: remote_configure { code1: 615 device_info { unknown1: 1 unknown2: "1" package_name: "atvremote" app_version: "1.0.0" } }
	Line 1194: 2024-08-27 09:47:01.471 DEBUG (MainThread) [androidtvremote2] Received: remote_set_active { }
	Line 1195: 2024-08-27 09:47:01.471 DEBUG (MainThread) [androidtvremote2] Sending: remote_set_active { active: 615 }
	Line 1196: 2024-08-27 09:47:01.480 DEBUG (MainThread) [androidtvremote2] Received: remote_set_volume_level { unknown1: 17 unknown2: 9 player_model: "MiTV-AFKR0" unknown4: 2 volume_max: 15 volume_level: 12 }
	Line 1197: 2024-08-27 09:47:01.481 DEBUG (MainThread) [androidtvremote2] Received: remote_start { started: true }
	Line 1200: 2024-08-27 09:47:01.489 DEBUG (MainThread) [androidtvremote2] Received: remote_ime_key_inject { app_info { app_package: "com.google.android.youtube.tv" } }
	Line 1201: 2024-08-27 09:47:11.810 DEBUG (MainThread) [androidtvremote2] Connected to ('192.168.222.5', 6467)
	Line 1202: 2024-08-27 09:47:11.811 DEBUG (MainThread) [androidtvremote2] Sending: protocol_version: 2 status: STATUS_OK pairing_request { service_name: "atvremote" client_name: "Home Assistant" }
	Line 1203: 2024-08-27 09:47:11.820 DEBUG (MainThread) [androidtvremote2] Received: 
	Line 1204: 2024-08-27 09:47:11.821 DEBUG (MainThread) [androidtvremote2] Unhandled msg: 
	Line 1205: 2024-08-27 09:47:11.823 DEBUG (MainThread) [androidtvremote2] Received: 
	Line 1206: 2024-08-27 09:47:11.823 DEBUG (MainThread) [androidtvremote2] Unhandled msg: 
	Line 1207: 2024-08-27 09:47:11.823 DEBUG (MainThread) [androidtvremote2] Received: 
	Line 1208: 2024-08-27 09:47:11.824 DEBUG (MainThread) [androidtvremote2] Unhandled msg: 
	Line 1209: 2024-08-27 09:47:11.829 DEBUG (MainThread) [androidtvremote2] Connection lost. Error: [SSL: APPLICATION_DATA_AFTER_CLOSE_NOTIFY] application data after close notify (_ssl.c:2685)
	Line 1210: 2024-08-27 09:47:14.250 DEBUG (MainThread) [androidtvremote2] Closing idle connection

I suspect that this integration have some changes in pairing request:

Received:
Unhandled msg:
Received:
Unhandled msg:
Received:
Unhandled msg:

But I cannot fix it. Do you have some idea what I have to do for this integration to start working again ?
Or I have to rise issue in github ?

Thank you for attention!

Regards,
Jeff

Forgot to mention,

Mibox4 can pair with phone “android remote tv app” and work as expected.

Again thank you for feature suggestions.

Regards,
Jeff

The problem is solved.
After updating the OS to 9, the next step is to go to the Play Store and find “Android TV Remote service” and simply update the app.
The device is old and there is no automatic app update.

Regards,
Jeff