I am trying to bring up a custom ARM machine (similar to Raspberry Pi) to connect to a Bluetooth keyboard using a UART HCI interface (as opposed to a USB Bluetooth dongle).
The device appears to pair correctly but no HID device is created (or at least input is not passed to Xorg -- I looked for device in /dev/input also but did not see anything. Is BT HID device created somewhere else?).
- Debian Jessie distribution
- Linux kernel 3.14
- bluez 5.43 (built natively)
I do have the same Bluetooth host controller connecting to peripheral keyboard with a Ubuntu 16.04 host (bluez 5.37), also over HCI UART 3-wire, so believe it should be limited to some kernel/bluez configuration on this new ARM device. Keyboard works immediately after pairing on the Ubuntu 16.04 host.
Note that the controller and peripheral are about Bluetooth LE only (not dual).
Here in problem device
bluetoothctl you can see the controller sees a HID service on the BT peripheral when asking
info [MAC ADDRESS], however it does not appear to register the HID service or am I missing something? (Only registers Battery Service, Device Information, and Generic Attribute Profile)
(already paired previously) root@df666c9893549d4:~# bluetoothctl [NEW] Controller D5:C0:BF:19:C4:AD BlueZ 5.43 [default] [NEW] Device FA:D8:12:DD:86:72 AST61-Keyboard [NEW] Primary Service /org/bluez/hci0/dev_FA_D8_12_DD_86_72/service000e 0000180f-0000-1000-8000-00805f9b34fb Battery Service [NEW] Primary Service /org/bluez/hci0/dev_FA_D8_12_DD_86_72/service0009 0000180a-0000-1000-8000-00805f9b34fb Device Information [NEW] Primary Service /org/bluez/hci0/dev_FA_D8_12_DD_86_72/service0008 00001801-0000-1000-8000-00805f9b34fb Generic Attribute Profile [AST61-Keyboard]# info FA:D8:12:DD:86:72 Device FA:D8:12:DD:86:72 Name: AST61-Keyboard Alias: AST61-Keyboard Appearance: 0x03c1 Icon: input-keyboard Paired: yes Trusted: yes Blocked: no Connected: yes LegacyPairing: no UUID: Generic Access Profile (00001800-0000-1000-8000-00805f9b34fb) UUID: Generic Attribute Profile (00001801-0000-1000-8000-00805f9b34fb) UUID: Device Information (0000180a-0000-1000-8000-00805f9b34fb) UUID: Battery Service (0000180f-0000-1000-8000-00805f9b34fb) UUID: Human Interface Device (00001812-0000-1000-8000-00805f9b34fb) Modalias: usb:v1915pEEEEd0001 RSSI: 84 [CHG] Device FA:D8:12:DD:86:72 ServicesResolved: no [CHG] Device FA:D8:12:DD:86:72 Connected: no [CHG] Device FA:D8:12:DD:86:72 Connected: yes [CHG] Device FA:D8:12:DD:86:72 ServicesResolved: yes
The device/kernel normally connects with a USB keyboard peripheral. I have added these Bluetooth-related defconfigs to add Bluetooth support:
# Bluetooth CONFIG_BT=y CONFIG_BT_RFCOMM=y CONFIG_BT_RFCOMM_TTY=y CONFIG_BT_BNEP_MC_FILTER=y CONFIG_BT_BNEP_PROTO_FILTER=y CONFIG_BT_HIDP=y # Bluetooth userspace HID CONFIG_UHID=y # Bluetooth extra (may not be necessary) CONFIG_BT_L2CAP=y CONFIG_BT_SCI=y CONFIG_BT_HCIUSB=y CONFIG_BT_HCIUSB_SCI=y CONFIG_BT_BNEP=y # Bluetooth drivers CONFIG_BT_HCIUART=y CONFIG_BT_HCIUART_H4=y CONFIG_BT_HCIUART_3WIRE=y CONFIG_BT_HCIVHCI=y CONFIG_BT_HCIUART_BCM=y CONFIG_BT_HCIUART_INTEL=y CONFIG_BT_HCIUART_BCSP=y CONFIG_BT_HCIUART_LL=y
Are there other HID related configs needed to drive the BT keyboard?
Finally, here is a the verbose
bluetoothd -n -d output which suggests HoG (HID over GATT) is trying to load the HID keyboard (I can't tell if output suggests successful or error honestly):