蓝牙无法发现耳机或其他设备 - Ubuntu 22.04.3 LTS

蓝牙无法发现耳机或其他设备 - Ubuntu 22.04.3 LTS

我认为我的蓝牙驱动程序存在一些问题。运行了以下命令:

hciconfig-a

hci0:   Type: Primary  Bus: USB
    BD Address: CC:47:40:81:CD:37  ACL MTU: 1021:6  SCO MTU: 255:12
    UP RUNNING 
    RX bytes:8857 acl:0 sco:0 events:929 errors:0
    TX bytes:15739 acl:0 sco:0 commands:861 errors:0
    Features: 0xff 0xff 0xff 0xfe 0xdb 0xfd 0x7b 0x87
    Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3 
    Link policy: RSWITCH HOLD SNIFF PARK 
    Link mode: PERIPHERAL ACCEPT 
    Name: '....'
    Class: 0x7c010c
    Service Classes: Rendering, Capturing, Object Transfer, Audio, Telephony
    Device Class: Computer, Laptop
    HCI Version: 5.2 (0xb)  Revision: 0xb
    LMP Version: 5.2 (0xb)  Subversion: 0x8852
    Manufacturer: Realtek Semiconductor Corporation (93)

btmgmt信息

Index list with 1 item
hci0:   Primary controller
    addr CC:47:40:81:CD:37 version 11 manufacturer 93 class 0x7c010c
    supported settings: powered connectable fast-connectable discoverable bondable link-security ssp br/edr hs le advertising secure-conn debug-keys privacy static-addr phy-configuration 
    current settings: powered bondable ssp br/edr le secure-conn 
    name ...
    short name 

sudo dmesg | grep Blue

[    1.439357] usb 3-2: Product: Bluetooth Radio
[    2.466820] Bluetooth: Core ver 2.22
[    2.466856] Bluetooth: HCI device and connection manager initialized
[    2.466863] Bluetooth: HCI socket layer initialized
[    2.466866] Bluetooth: L2CAP socket layer initialized
[    2.466873] Bluetooth: SCO socket layer initialized
[    2.711766] Bluetooth: hci0: Failed to read codec capabilities (-22)
[    3.910378] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[    3.910383] Bluetooth: BNEP filters: protocol multicast
[    3.910387] Bluetooth: BNEP socket layer initialized
[    3.961186] Bluetooth: MGMT ver 1.22
[  124.898809] Bluetooth: RFCOMM TTY layer initialized
[  124.898818] Bluetooth: RFCOMM socket layer initialized
[  124.898823] Bluetooth: RFCOMM ver 1.11
[  140.331849] Bluetooth: hci0: Failed to read codec capabilities (-22)
[  151.009819] Bluetooth: hci0: Ignoring error of Inquiry Cancel command
[  847.176089] Bluetooth: hci0: Failed to read codec capabilities (-22)
[ 1010.620553] Bluetooth: hci0: Failed to read codec capabilities (-22)
[ 1241.507602] Bluetooth: hci0: Failed to read codec capabilities (-22)
[ 9991.967864] Bluetooth: hci0: Failed to read codec capabilities (-22)

mesg | egrep -i'blue|firm'; mokutil--sb-state

SecureBoot disabled 
Platform is in Setup Mode

uname -r

6.2.0-36-generic

我最后尝试的是来自这个链接:蓝牙(rtl8723be)在联想 Ideapad 100-14iby 上找不到设备

但是我被困在这里,我不知道该如何继续(菜鸟在这里): 制作

make -C /lib/modules/6.2.0-36-generic/build M=/home/.../bluetooth-5.4 modules
make[1]: Entering directory '/usr/src/linux-headers-6.2.0-36-generic'

  ERROR: Kernel configuration is invalid.
         include/generated/autoconf.h or include/config/auto.conf are missing.
         Run 'make oldconfig && make prepare' on kernel src to fix it.

make[1]: *** [Makefile:820: include/config/auto.conf] Error 1
make[1]: Leaving directory '/usr/src/linux-headers-6.2.0-36-generic'
make: *** [Makefile:7: all] Error 2

左:我稍微改变了方向,现在我正在尝试这个:

https://github.com/HRex39/rtl8852be_bt#3-save-and-build 从这里未找到蓝牙设备 | Ubuntu 20.04.5

但是现在我遇到了以下问题:

sudo apt install --reinstall linux-headers-6.2.0-36-generic

制作

make -C /lib/modules/6.2.0-36-generic/build M=/home/.../new_attempt/rtl8852be_bt modules
make[1]: Entering directory '/usr/src/linux-headers-6.2.0-36-generic'
warning: the compiler differs from the one used to build the kernel
  The kernel was built by: x86_64-linux-gnu-gcc-11 (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
  You are using:           gcc-11 (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
  CC [M]  /home/.../new_attempt/rtl8852be_bt/btusb.o
/home/.../new_attempt/rtl8852be_bt/btusb.c: In function ‘btusb_probe’:
/home/.../new_attempt/rtl8852be_bt/btusb.c:3819:13: error: ‘struct hci_dev’ has no member named ‘prevent_wake’
 3819 |         hdev->prevent_wake = btusb_prevent_wake;
      |             ^~
make[2]: *** [scripts/Makefile.build:260: /home/.../new_attempt/rtl8852be_bt/btusb.o] Error 1
make[1]: *** [Makefile:2026: /home/.../new_attempt/rtl8852be_bt] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-6.2.0-36-generic'
make: *** [Makefile:17: all] Error 2

有人能帮我解决这个问题吗?请注意,在 Ubuntu Cinnamon 中,设备会被发现,尤其是我的耳机,我可以从命令行或某些蓝牙管理器配对,但声音卡顿很多,无论我如何“努力”尝试从其他可用资源解决问题,都无法播放。如果需要更多信息,请告诉我。谢谢!

相关内容