首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >蓝牙耳机不自动连接(Ubuntu)

蓝牙耳机不自动连接(Ubuntu)
EN

Unix & Linux用户
提问于 2020-06-10 20:42:25
回答 1查看 3.7K关注 0票数 4

我的蓝调T4耳机不会在UbuntuLinux20.04LTS中自动连接。

该设备是可信的,并在PulseAudio /etc/脉冲/default.pa中启用。使用Wireshark,我可以看到它很快就连接到控制器上了。然而,几毫秒后,它发送一个断开连接请求,设备相应地断开连接。

代码语言:javascript
运行
复制
$ bluetoothctl info 17:07:11:00:00:00
Device 17:07:11:DD:0D:27 (public)
    Name: Bluedio T
    Alias: Bluedio T
    Class: 0x00240404
    Icon: audio-card
    Paired: yes
    Trusted: yes
    Blocked: no
    Connected: no
    LegacyPairing: no
    UUID: Audio Sink                (0000110b-0000-1000-8000-00805f000000)
    UUID: A/V Remote Control Target (0000110c-0000-1000-8000-00805f000000)
    UUID: A/V Remote Control        (0000110e-0000-1000-8000-00805f000000)
    UUID: Handsfree                 (0000111e-0000-1000-8000-00805f000000)
代码语言:javascript
运行
复制
$ cat /etc/pulse/default.pa | grep -B 1 -A 1 module-switch-on-connect
### Use hot-plugged devices like Bluetooth or USB automatically (LP: #1702794)
.ifexists module-switch-on-connect.so
load-module module-switch-on-connect
.endif
代码语言:javascript
运行
复制
No. Time    Source  Destination Protocol    Length  Info
1   0.000000    controller  host    HCI_EVT 13  Rcvd Connect Request
2   0.000030    host    controller  HCI_CMD 11  Sent Accept Connection Request
3   0.001019    controller  host    HCI_EVT 7   Rcvd Command Status (Accept Connection Request)
4   0.175023    controller  host    HCI_EVT 11  Rcvd Role Change
5   0.195976    controller  host    HCI_EVT 14  Rcvd Connect Complete
6   0.196106    host    controller  HCI_CMD 6   Sent Read Remote Supported Features
...
36  0.311036    localhost ()    17:07:11:dd:0d:27 (Bluedio T)   L2CAP   17  Sent Configure Request (DCID: 0x0040)
37  0.317005    controller  host    HCI_EVT 8   Rcvd Number of Completed Packets
38  0.318999    controller  host    HCI_EVT 8   Rcvd Number of Completed Packets
39  0.364021    17:07:11:dd:0d:27 (Bluedio T)   localhost ()    L2CAP   17  Rcvd Configure Request (DCID: 0x0040)
40  0.364073    localhost ()    17:07:11:dd:0d:27 (Bluedio T)   L2CAP   23  Sent Configure Response - Success (SCID: 0x0040)
41  0.366020    17:07:11:dd:0d:27 (Bluedio T)   localhost ()    L2CAP   23  Rcvd Configure Response - Success (SCID: 0x0040)
42  0.369020    controller  host    HCI_EVT 8   Rcvd Number of Completed Packets
43  0.422020    17:07:11:dd:0d:27 (Bluedio T)   localhost ()    SDP 42  Rcvd Service Search Attribute Request : Handsfree Audio Gateway: L2CAP: RFCOMM: [Protocol Descriptor List 0x0004] [Bluetooth Profile Descriptor List 0x0009] [(HFP AG) Network 0x0301] [(HFP AG) Supported Features 0x0311] 
44  0.422245    localhost ()    17:07:11:dd:0d:27 (Bluedio T)   SDP 19  Sent Service Search Attribute Response 
45  0.427979    controller  host    HCI_EVT 8   Rcvd Number of Completed Packets
46  0.479997    17:07:11:dd:0d:27 (Bluedio T)   localhost ()    L2CAP   17  Rcvd Disconnection Request (SCID: 0x0040, DCID: 0x0040, PSM: 0x0001, Service: SDP)
47  0.480021    localhost ()    17:07:11:dd:0d:27 (Bluedio T)   L2CAP   17  Sent Disconnection Response (SCID: 0x0040, DCID: 0x0040, PSM: 0x0001, Service: SDP)
48  0.483982    controller  host    HCI_EVT 8   Rcvd Number of Completed Packets
49  0.687030    controller  host    HCI_EVT 7   Rcvd Disconnect Complete
50  0.748115    host    controller  HCI_CMD 5   Sent Write Scan Enable
51  0.751010    controller  host    HCI_EVT 7   Rcvd Command Complete (Write Scan Enable)

因为这个设备连接到我的Android设备上没有任何问题,我不知道为什么会发生这种情况。

EN

回答 1

Unix & Linux用户

发布于 2021-03-03 06:55:04

我也有同样的问题(但是对于debian和bluedio t6)。

我尝试将选项FastConnectable更改为true in /etc/bluetooth/main.conf,节[General]

代码语言:javascript
运行
复制
# Permanently enables the Fast Connectable setting for adapters that
# support it. When enabled other devices can connect faster to us,
# however the tradeoff is increased power consumptions. This feature
# will fully work only on kernel version 4.1 and newer. Defaults to
# 'false'.
#FastConnectable = false
FastConnectable = true

然后我重新启动了蓝牙,现在耳机在打开后立即连接起来。

票数 5
EN
页面原文内容由Unix & Linux提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://unix.stackexchange.com/questions/592145

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档