Bluetooth connects and disconnects on Nano 2GB

I seem to be having a very similar issue to what is described here - PS4 gamepad will connect then disconnect consistently when running JP 4.5.1 on a Nano 4GB - Where every BT device that I connect to disconnects after 2 seconds, but I’m on the latest L4T. I’ve tried with 3 different USB BT adapters (Panda PBU40, Edimax BT-8500, and Kinivo BTD-400) with the same results. Plugging the adapters into the USB 3.0 port behaves the same as the USB 2.0 ports. I’ve tried pairing to my Pixel XL, Macbook, BT earbuds, and they all behave the same. Any ideas on what’s going on? Let me know what other debug / info I can get. Thanks!

$ uname -a
Linux developer-desktop 4.9.253-tegra #1 SMP PREEMPT Sat Oct 9 07:43:58 UTC 2021 aarch64 aarch64 aarch64 GNU/Linux
$ cat /etc/nv_tegra_release
# R32 (release), REVISION: 6.1, GCID: 27863751, BOARD: t210ref, EABI: aarch64, DATE: Mon Jul 26 19:20:30 UTC 2021
$ cat /var/log/syslog
Oct 14 18:15:42 developer-desktop bluetoothd[4493]: src/adapter.c:connected_callback() hci0 device 38:F9:D3:4F:EC:3C connected eir_len 29
Oct 14 18:15:46 developer-desktop bluetoothd[4493]: src/adapter.c:dev_disconnected() Device 38:F9:D3:4F:EC:3C disconnected, reason 2
Oct 14 18:15:46 developer-desktop bluetoothd[4493]: src/adapter.c:adapter_remove_connection()
Oct 14 18:15:46 developer-desktop bluetoothd[4493]: plugins/policy.c:disconnect_cb() reason 2
Oct 14 18:15:46 developer-desktop bluetoothd[4493]: src/adapter.c:bonding_attempt_complete() hci0 bdaddr 38:F9:D3:4F:EC:3C type 0 status 0xe
Oct 14 18:15:46 developer-desktop bluetoothd[4493]: src/device.c:device_bonding_complete() bonding (nil) status 0x0e
Oct 14 18:15:46 developer-desktop bluetoothd[4493]: src/device.c:device_bonding_failed() status 14
Oct 14 18:15:46 developer-desktop bluetoothd[4493]: src/adapter.c:resume_discovery()
Oct 14 18:15:59 developer-desktop bluetoothd[4493]: src/agent.c:agent_disconnect() Agent :1.24 disconnected
Oct 14 18:15:59 developer-desktop bluetoothd[4493]: src/agent.c:agent_destroy() agent :1.24
Oct 14 18:15:59 developer-desktop bluetoothd[4493]: src/agent.c:agent_unref() 0x55ba5d9bc0: ref=0
[bluetooth]# show
Controller 00:1A:7D:DA:71:13 (public)
	Name: developer-desktop
	Alias: developer-desktop
	Class: 0x00000000
	Powered: yes
	Discoverable: no
	Pairable: yes
	UUID: Generic Attribute Profile (00001801-0000-1000-8000-00805f9b34fb)
	UUID: PnP Information           (00001200-0000-1000-8000-00805f9b34fb)
	UUID: Generic Access Profile    (00001800-0000-1000-8000-00805f9b34fb)
	Modalias: usb:v1D6Bp0246d0530
	Discovering: no

@dustinkerstein,

I initiated the original issue that you referenced in your post above.
I have JP 4.6 running on my Nano 4GB and both my PS4 and PS5 gamepads pair/connect without issue now.
Are you running JP 4.6 on your Nano 2GB?

Thanks for the quick reply. Yeah, I have the latest JP installed via apt (4.6-b199). I’ve also tried the instructions here - Connecting Bluetooth Audio | NVIDIA Developer - but have the same results.

Hi dustinkerstein,

This issue fixed in JP-4.6.
Could you try ac8265 BT module?

Hi Carol, unfortunately I can’t use the ac8265 module on the 2GB Dev Kit as it doesn’t have the M.2 slot. I only can use USB WiFi/BT modules. Do you have any recommended BT USB modules I could try? I have a forth (Asus BT400) arriving Sunday that I can test with, but I haven’t come across any proven working USB BT modules noted for the Jetson platform.

Here’s the btmon output for my earbuds - > HCI Event: Connect Request (0x04) plen 10 - Pastebin.com which try to re-connect. My Macbook and Pixel will just disconnect without retrying.

I’ve also tried manually compiling the latest bluez and see the same results. Will post results with the Asus adapter on Sunday.

Quick update - Fedora 34 on a VM seems to work with all three of the USB BT adapters I’ve tried. Will post further updates when the Asus adapter arrives.

Could you try with some simple device like bt mouse/keyboard first?

Also, can you try with jetpack4.5.1 and see if such issue?

Same behavior on 4.5.1 (before and after apt upgrade) with all four USB BT adapters I have (now also including the Asus BT400).

However, I did manage to connect to a bluetooth pulse oximeter without it disconnecting, so that’s promising. I don’t have any bluetooth mice/keyboards to test, but none of the devices that I actually need are working (Macbook + Pixel for serial comms). Here’s a log from my Macbook during the connect/disconnect - default 15:33:47.358330-0400 bluetoothd ***** Temporarily stopping all scans *** - Pastebin.com

Any ideas on how to further debug this? Thanks.

It also likes to connect to my Nvidia Shield. I do notice that for devices that do connect, it shows the services upon connection:

[NEW] Primary Service
	/org/bluez/hci0/dev_6F_58_AD_C8_65_C4/service0001
	00001801-0000-1000-8000-00805f9b34fb
	Generic Attribute Profile
[NEW] Characteristic
	/org/bluez/hci0/dev_6F_58_AD_C8_65_C4/service0001/char0002
	00002a05-0000-1000-8000-00805f9b34fb
	Service Changed
[NEW] Primary Service
	/org/bluez/hci0/dev_6F_58_AD_C8_65_C4/service0028
	00009999-0000-1000-8000-00805f9b34fb
	Unknown
[NEW] Characteristic
	/org/bluez/hci0/dev_6F_58_AD_C8_65_C4/service0028/char0029
	00009997-0000-1000-8000-00805f9b34fb
	Unknown
[NEW] Characteristic
	/org/bluez/hci0/dev_6F_58_AD_C8_65_C4/service0028/char002b
	00009996-0000-1000-8000-00805f9b34fb
	Unknown
[NEW] Descriptor
	/org/bluez/hci0/dev_6F_58_AD_C8_65_C4/service0028/char002b/desc002d
	00002902-0000-1000-8000-00805f9b34fb
	Client Characteristic Configuration
[NEW] Descriptor
	/org/bluez/hci0/dev_6F_58_AD_C8_65_C4/service0028/char002b/desc002e
	00002901-0000-1000-8000-00805f9b34fb
	Characteristic User Description

Update - I spoke too soon. The Shield also disconnects. Only the pulse oximeter seems to connect, and stay connected.

Not sure how, but following this guide - Raspberry Pi Bluetooth setup and running Rfcomm server - YouTube - got everything working the way I need it.

Thanks a million, dustinkerstein! I had been experiencing the same issue (plugins/policy.c:disconnect_cb() reason 2src/device.c:device_bonding_failed() status 14) after my last upgrade, only with an a2dp audio device. I had spent countless hours trying to figure out what had caused this regression. The video you linked to finally gave me the clue I needed! I managed to isolate the specific problem, so here it is for the record:

The configuration file which changed and caused this is /lib/systemd/system/bluetooth.service.d/nv-bluetooth-service.conf, owned by nvidia-l4t-firmware. Apparently the maintainer of this package decided that probably nobody would want to use high-fidelity bluetooth audio or an A/V remote control, so they added the argument --noplugin=audio,a2dp,avrcp to the end of the bluetoothd daemon command. 🙄

I don’t personally need avrcp, so I left that, but removing audio,a2dp from the blacklist, then running sudo systemctl daemon-reload; sudo systemctl restart bluetooth did the trick for me! I have never used a bluetooth gamepad before, but I suspect the avrcp plugin may have been the one you needed for that, as it is described by wikipedia as “provid[ing] a standard interface to control TVs, Hi-fi equipment, etc.” This page on the DualShock 4 controller mentions both a2dp and avrcp, though I don’t really understand the details of the context, so you may need both for that device.

Glad I could help. FYI, that suggestion is also in the Nvidia docs - Connecting Bluetooth Audio | NVIDIA Developer - The thing that got it working for me was actually advertising a service that my other device was interested in. Though I still don’t know if my BT headphones would connect. I have since returned all the BT USD adapters and picked up a Adafruit Bluefruit LE Friend USB which provide a pure serial interface and solves my use-case (UART/Serial comms) perfectly.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.