Cannot connect to Ubuntu BLE servers
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
bluez (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
I'm on Ubuntu 22.04.1 LTS, using bluez 5.65 (built from sources by this guide: https:/
1. Run `python3 /usr/local/
2. Run `/usr/local/
3. Use nRF Connect app on Android 9 phone to connect to the "TestAdvertisement" device
The outcome is that the phone app tries to connect, but fails, leaving me with a view of the GATT services and characteristics, but with no way of accessing (read/write/notify) it. I have tried many other BLE server implementations, but for the bug reporting I focused on the most trusted reference.
Full logs are attached. The relevant part of the btmon log is here:
@ MGMT Event: Device Connected (0x000b) plen 13 {0x0001} [hci0] 945.575247
LE Address: 4D:2C:9A:88:F1:86 (Resolvable)
Flags: 0x00000000
Data length: 0
< HCI Command: LE Read Remote Used Features (0x08|0x0016) plen 2 #32 [hci0] 945.575351
Handle: 3585 Address: 4D:2C:9A:88:F1:86 (Resolvable)
@ RAW Open: btmon (privileged) version 2.22 {0x0002} 945.575453
@ RAW Close: btmon {0x0002} 945.575462
> HCI Event: LE Meta Event (0x3e) plen 4 #33 [hci0] 945.575984
LE Channel Selection Algorithm (0x14)
Handle: 3585 Address: 4D:2C:9A:88:F1:86 (Resolvable)
Algorithm: #1 (0x00)
> HCI Event: LE Meta Event (0x3e) plen 6 #34 [hci0] 945.576990
LE Advertising Set Terminated (0x12)
Status: Success (0x00)
Handle: 1
Connection handle: 3585
Number of completed extended advertising events: 0
> HCI Event: Command Status (0x0f) plen 4 #35 [hci0] 945.578094
LE Read Remote Used Features (0x08|0x0016) ncmd 1
Status: Unsupported Remote Feature / Unsupported LMP Feature (0x1a)
< HCI Command: Disconnect (0x01|0x0006) plen 3 #36 [hci0] 945.578193
Handle: 3585 Address: 4D:2C:9A:88:F1:86 (Resolvable)
Reason: Remote User Terminated Connection (0x13)
> HCI Event: Command Status (0x0f) plen 4 #37 [hci0] 945.579984
Disconnect (0x01|0x0006) ncmd 1
Status: Success (0x00)
> HCI Event: Disconnect Complete (0x05) plen 4 #38 [hci0] 945.652123
Status: Success (0x00)
Handle: 3585 Address: 4D:2C:9A:88:F1:86 (Resolvable)
Reason: Connection Terminated By Local Host (0x16)
@ MGMT Event: Device Disconnected (0x000c) plen 8 {0x0001} [hci0] 945.652224
LE Address: 4D:2C:9A:88:F1:86 (Resolvable)
Reason: Connection terminated by local host (0x02)
The Additional information:
$ hciconfig -a
hci0: Type: Primary Bus: USB
BD Address: BC:6E:E2:D0:B1:27 ACL MTU: 1021:4 SCO MTU: 96:6
UP RUNNING PSCAN
RX bytes:3074 acl:43 sco:0 events:194 errors:0
TX bytes:7295 acl:42 sco:0 commands:125 errors:0
Features: 0xbf 0xfe 0x0f 0xfe 0xdb 0xff 0x7b 0x87
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: RSWITCH SNIFF
Link mode: PERIPHERAL ACCEPT
Name: 'epitos'
Class: 0x6c010c
Service Classes: Rendering, Capturing, Audio, Telephony
Device Class: Computer, Laptop
HCI Version: (0xc) Revision: 0x3484
LMP Version: (0xc) Subversion: 0x3484
Manufacturer: Intel Corp. (2)
$ bluetoothctl
Agent registered
[CHG] Controller BC:6E:E2:D0:B1:27 Pairable: yes
[bluetooth]# show
Controller BC:6E:E2:D0:B1:27 (public)
Name: epitos
Alias: epitos
Class: 0x006c010c
Powered: yes
Discoverable: no
DiscoverableTi
Pairable: yes
UUID: A/V Remote Control (0000110e-
UUID: Handsfree Audio Gateway (0000111f-
UUID: PnP Information (00001200-
UUID: Audio Sink (0000110b-
UUID: Headset (00001108-
UUID: A/V Remote Control Target (0000110c-
UUID: Generic Access Profile (00001800-
UUID: Audio Source (0000110a-
UUID: Generic Attribute Profile (00001801-
UUID: Vendor specific (12345678-
UUID: Device Information (0000180a-
UUID: Battery Service (0000180f-
UUID: Heart Rate (0000180d-
Modalias: usb:v1D6Bp0246d0540
Discovering: no
Roles: central
Roles: peripheral
Advertising Features:
ActiveInstances: 0x01 (1)
SupportedInsta
SupportedIncludes: tx-power
SupportedIncludes: appearance
SupportedIncludes: local-name
SupportedSecon
SupportedSecon
SupportedSecon
[bluetooth]# devices
Device 90:00:DB:0D:50:8C SM-G800F
[bluetooth]# info 90:00:DB:0D:50:8C
Device 90:00:DB:0D:50:8C (public)
Name: SM-G800F
Alias: SM-G800F
Class: 0x005a020c
Icon: phone
Paired: yes
Trusted: yes
Blocked: no
Connected: no
LegacyPairing: no
UUID: OBEX Object Push (00001105-
UUID: Audio Source (0000110a-
UUID: A/V Remote Control Target (0000110c-
UUID: A/V Remote Control (0000110e-
UUID: Headset AG (00001112-
UUID: PANU (00001115-
UUID: NAP (00001116-
UUID: Handsfree Audio Gateway (0000111f-
UUID: Phonebook Access Server (0000112f-
UUID: Message Access Server (00001132-
UUID: PnP Information (00001200-
UUID: Generic Access Profile (00001800-
UUID: Generic Attribute Profile (00001801-
Modalias: bluetooth:
Thanks for the bug report. Unfortunately we can't support personal builds of BlueZ here. If you experience any issues with BlueZ that you built yourself then please report them upstream at https:/ /github. com/bluez/ bluez/issues