Hello everyone,
i need support with my hardware. My Bluetooth adapter is not recognized correctly in Home Assistant. I see the following messages in the logs.
Home Assistant Core Protocol:
2024-09-13 13:44:29.024 ERROR (MainThread) [bluetooth_auto_recovery.recover] Unexpected error while attempting USB reset of hci0: [Errno 19] No such device
Traceback (most recent call last):
File "/usr/local/lib/python3.12/site-packages/bluetooth_auto_recovery/recover.py", line 515, in _usb_reset_adapter
return await dev.async_reset()
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/usb_devices/__init__.py", line 49, in async_reset
return await asyncio.get_running_loop().run_in_executor(None, self.reset)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/usb_devices/__init__.py", line 56, in reset
return self.usb_device.reset()
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/usb_devices/__init__.py", line 141, in reset
return ioctl(usb_dev, USBDEVFS_RESET, 0) > -1
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
OSError: [Errno 19] No such device
2024-09-13 13:44:29.026 ERROR (MainThread) [habluetooth.scanner] hci0 (A8:43:A4:29:16:2D): Failed to restart Bluetooth scanner: hci0 (A8:43:A4:29:16:2D): Failed to start Bluetooth: adapter 'hci0' not found; Try power cycling the Bluetooth hardware.
Traceback (most recent call last):
File "src/habluetooth/scanner.py", line 329, in habluetooth.scanner.HaScanner._async_start_attempt
File "src/habluetooth/scanner.py", line 329, in habluetooth.scanner.HaScanner._async_start_attempt
File "src/habluetooth/scanner.py", line 332, in habluetooth.scanner.HaScanner._async_start_attempt
File "/usr/local/lib/python3.12/site-packages/bleak/__init__.py", line 203, in start
await self._backend.start()
File "/usr/local/lib/python3.12/site-packages/bleak/backends/bluezdbus/scanner.py", line 178, in start
self._stop = await manager.passive_scan(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/bleak/backends/bluezdbus/manager.py", line 513, in passive_scan
self._check_adapter(adapter_path)
File "/usr/local/lib/python3.12/site-packages/bleak/backends/bluezdbus/manager.py", line 209, in _check_adapter
raise BleakError(f"adapter '{adapter_path.split('/')[-1]}' not found")
bleak.exc.BleakError: adapter 'hci0' not found
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "src/habluetooth/scanner.py", line 528, in habluetooth.scanner.HaScanner._async_restart_scanner
File "src/habluetooth/scanner.py", line 286, in _async_start
File "src/habluetooth/scanner.py", line 373, in _async_start_attempt
habluetooth.scanner.ScannerStartError: hci0 (A8:43:A4:29:16:2D): Failed to start Bluetooth: adapter 'hci0' not found; Try power cycling the Bluetooth hardware.
2024-09-13 13:44:46.778 INFO (MainThread) [habluetooth.scanner] hci0 (A8:43:A4:29:16:2D): Bluetooth scanner has gone quiet for 90s, restarting
dmesg Protocol:
\[\e]0;\u@\h:\w\a\]\W $ dmesg| grep hci0
[321065.635034] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[321065.637003] Bluetooth: hci0: RTL: rom_version status=0 version=1
[321065.637016] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[321065.637625] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[321065.637734] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[321066.240397] Bluetooth: hci0: RTL: fw version 0x75b8f098
[342848.560991] Bluetooth: hci0: Opcode 0x200c failed: -71
[342848.561017] Bluetooth: hci0: Unable to disable scanning: -71
[342848.561514] Bluetooth: hci0: Opcode 0x200c failed: -71
[342848.561534] Bluetooth: hci0: Unable to disable scanning: -71
[342848.561549] Bluetooth: hci0: Unable to disable scanning: -71
[342848.562524] Bluetooth: hci0: Opcode 0x200c failed: -71
[342848.562545] Bluetooth: hci0: Unable to disable scanning: -71
[342848.562560] Bluetooth: hci0: stop background scanning failed: -71
[342859.012217] Bluetooth: hci0: Opcode 0x200c failed: -71
[342859.012238] Bluetooth: hci0: Unable to disable scanning: -71
[342859.012250] Bluetooth: hci0: Unable to disable scanning: -71
[342859.013269] Bluetooth: hci0: Opcode 0x200c failed: -71
[342859.013289] Bluetooth: hci0: Unable to disable scanning: -71
[342859.013305] Bluetooth: hci0: stop background scanning failed: -71
[342869.002932] Bluetooth: hci0: Opcode 0x200c failed: -71
[342869.002958] Bluetooth: hci0: Unable to disable scanning: -71
[342869.002973] Bluetooth: hci0: Unable to disable scanning: -71
[342869.003963] Bluetooth: hci0: Opcode 0x200c failed: -71
[342869.003989] Bluetooth: hci0: Unable to disable scanning: -71
[342869.004004] Bluetooth: hci0: stop background scanning failed: -71
[342879.009641] Bluetooth: hci0: Opcode 0x200c failed: -71
[342879.009667] Bluetooth: hci0: Unable to disable scanning: -71
[342879.009682] Bluetooth: hci0: Unable to disable scanning: -71
[342879.010637] Bluetooth: hci0: Opcode 0x200c failed: -71
[342879.010660] Bluetooth: hci0: Unable to disable scanning: -71
[342879.010675] Bluetooth: hci0: stop background scanning failed: -71
[342889.012366] Bluetooth: hci0: Opcode 0x200c failed: -71
[342889.012392] Bluetooth: hci0: Unable to disable scanning: -71
[342889.012407] Bluetooth: hci0: Unable to disable scanning: -71
[342889.013351] Bluetooth: hci0: Opcode 0x200c failed: -71
[342889.013372] Bluetooth: hci0: Unable to disable scanning: -71
[342889.013387] Bluetooth: hci0: stop background scanning failed: -71
[345023.606440] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[345023.608386] Bluetooth: hci0: RTL: rom_version status=0 version=1
[345023.608396] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[345023.608879] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[345023.608966] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[345024.210450] Bluetooth: hci0: RTL: fw version 0x75b8f098
[353735.638853] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[353735.640833] Bluetooth: hci0: RTL: rom_version status=0 version=1
[353735.640845] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[353735.641134] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[353735.641184] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[353736.242898] Bluetooth: hci0: RTL: fw version 0x75b8f098
[357728.607563] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[357728.609542] Bluetooth: hci0: RTL: rom_version status=0 version=1
[357728.609550] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[357728.609924] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[357728.609991] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[357729.211636] Bluetooth: hci0: RTL: fw version 0x75b8f098
[373216.616103] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[373216.618108] Bluetooth: hci0: RTL: rom_version status=0 version=1
[373216.618117] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[373216.618474] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[373216.618542] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[373217.220154] Bluetooth: hci0: RTL: fw version 0x75b8f098
[395964.610420] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[395964.612408] Bluetooth: hci0: RTL: rom_version status=0 version=1
[395964.612418] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[395964.612892] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[395964.612973] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[395965.214476] Bluetooth: hci0: RTL: fw version 0x75b8f098
[441581.637938] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[441581.639921] Bluetooth: hci0: RTL: rom_version status=0 version=1
[441581.639931] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[441581.640392] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[441581.640482] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[441582.242003] Bluetooth: hci0: RTL: fw version 0x75b8f098
[558951.608594] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[558951.610561] Bluetooth: hci0: RTL: rom_version status=0 version=1
[558951.610566] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[558951.610806] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[558951.610855] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[558952.212644] Bluetooth: hci0: RTL: fw version 0x75b8f098
[568268.609953] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[568268.611935] Bluetooth: hci0: RTL: rom_version status=0 version=1
[568268.611940] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[568268.612167] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[568268.612217] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[568269.215402] Bluetooth: hci0: RTL: fw version 0x75b8f098
[598155.609520] Bluetooth: hci0: RTL: examining hci_ver=08 hci_rev=000c lmp_ver=08 lmp_subver=8821
[598155.611522] Bluetooth: hci0: RTL: rom_version status=0 version=1
[598155.611532] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_fw.bin
[598155.611986] Bluetooth: hci0: RTL: loading rtl_bt/rtl8821c_config.bin
[598155.612060] Bluetooth: hci0: RTL: cfg_sz 10, total sz 34926
[598156.213577] Bluetooth: hci0: RTL: fw version 0x75b8f098
Do you have any idea why my Bluetooth adapter isn’t working?
Greetings from Stefan Harbich