Bounding Unicorns

Linux As Bluetooth Audio Sink

This is possible without using pulseaudio thanks to the awesome bluez-alsa project.

Install needed software:

apt-get install bluez alsa-utils bluez-alsa-utils

Verify Bluetooth hardware is present:

dmesg |grep hci

hciconfig

Start bluetoothd:

/etc/init.d/bluetooth start

# For debugging:
bluetoothd -n -d

Start bluealsa:

bluealsa -p a2dp-sink

Note that bluealsa does not daemonize. You'll need to implement your own daemonization solution for it.

Start bluealsa-aplay:

bluealsa-aplay

Troubleshooting

Verify bluetoothd supports a2dp

To verify that bluetoothd supports a2dp, run:

bluetoothd -n -d

If bluetoothd is already running, it must be stopped first.

Look for the following line in the output:

bluetoothd[2657]: src/plugin.c:add_plugin() Loading a2dp plugin                                      

Phone Pairs With PC But Does Not Show Audio Output Option

This is caused by not providing the -p a2dp-sink argument to bluealsa. By default, bluealsa launches itself as a source feeding sound to a Bluetooth receiver. To use the PC as a sink receiving the sound, bluealsa must be instructed to run using the a2dp-sink profile.