Bluetooth

= User Space =

The collection of user space tools is maintained by the Bluez project. Note that the tool chain requires D-Bus. For application development the D-Bus API is documented in the Bluez source.

A contemporary short instruction for CLI usage can be found in the Archlinux Wiki.

= Driver specific information =

AP6210
The AMPAK AP6210 combines Broadcom Bluetooth 4.0 and Wifi chips in a single package. The Bluetooth chip is driven over UART, with audio carried over a PCM interface.

Drivers for Sunxi Linux 3.4 kernel:
 * Cubietruck/Bluetooth - notes on this Wiki about the Cubietruck that contains an AP6210
 * "Got bluetooth working on Cubietruck - proof of concept" - Arch Linux forum
 * EddyBeaupre/ap6210 - GitHub, "Wifi and Bluetooth driver for CubieTruck"

Drivers for mainline Linux kernel:
 * User_talk:Sehraf - Sehraf did some research in September 2014 and concluded there was a problem with the set up of the clock
 * "ARM: dts: sun7i: add bluetooth module to CubieTruck DTS" - patch as an example DTS file

8723au
This device has no driver included in the kernel, but you can install it separately. It also supports Wifi functionality.

The Bluetooth functionality is included in the hardware that does the wifi, so you may need to have the wifi drivers described above working to also have this working. However, don't expect it to work particularly well as there appear to be numerous bugs (in either the driver or the hardware or both). There seems to also be an issue where using both wifi and bluetooth at the same time cause severe interference to the point where connections are dropped (this has been seen in the stock Android firmware as well).

check out the code from https://github.com/lwfinger/rtl8723au_bt.git and compile with the following command:

make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- -C ../linux-sunxi/ M=`pwd` modules

NOTE: This command assumes that you checked out the rtl8723au_bt repo into the same directory as the linux-sunxi repo (note the  points to where your local kernel repository is)

copy the *.bin and *.ko files over to the device and run the following on the device (as root) where you have your files:

mkdir -p /lib/firmware/rtk_bt cp rlt8723a_chip_b_cut_bt40_fw_asic_rom_patch-svn8511-0x0020342E-20121105-LINUX_USB.bin /lib/firmware/rtk_bt/rtk8723a.bin install -p -m 644 rtk_btusb.ko /lib/modules/`uname -r`/kernel/drivers/bluetooth/ /sbin/depmod modprobe rtk_btusb

Apparently, the RTL8723AU driver (r8728au) in mainline serves only wifi, though it has an option to coexist with BT. rtl8723au_bt, branch new is the work repository for a current bluetooth driver.