h1. Bluetooth Audio on Arch Linux
p(meta). 07 Feb 2016 - Austin, TX
h2. Background
My wife and I got an "iLive IKB333s":http://iliveelectronics.com/products/bluetooth/wireless-bluetooth-under-cabinet-music-system.html under-cabinet bluetooth radio for Christmas this year and she said she wanted to be able to stream audio from our Arch Linux laptop in the living room to it.
I decided to blog about what it was like to get this working because it's my first time using bluetooth on Linux, and because it was successful.
h2. TL;DR
The way I got this working was using "pulseaudio-bluetooth":https://www.archlinux.org/packages/?name=pulseaudio-bluetooth
(since we want to stream audio from Spotify, which uses pulse), and set the default sink to the bluetooth sink.
h2. Setting up bluetooth
I had to steal the "USB dongle":http://www.amazon.com/JBtek-Raspberry-Bluetooth-4-0-adapter/dp/B00L08NCPQ/ref=cm_cr_pr_product_top?ie=UTF8 that I bought for my raspberry pi to get bluetooth on my laptop (Toshiba Satellite L645).
After this I installed all the packages recommended "here":https://wiki.archlinux.org/index.php/bluetooth and "here":https://wiki.archlinux.org/index.php/Bluetooth_headset.
I added myself to the lp group since the bluetooth daemon will only give out bnep0 devices to users who are in this group.
After powering up the radio I set the source to Bluetooth, and hit the Pair button.
A blue light on the device starts blinking until you pair with it from another device.
Next I followed the "cli instructions":https://wiki.archlinux.org/index.php/bluetooth#Configuration_via_the_CLI to connect to the radio.
Next all I had to do was start spotify, and voila! I was streaming great-sounding audio to the radio from my Arch laptop.
h2. Conclusion
As always, the "arch wiki":https://wiki.archlinux.org/ was _extremely_ helpful. Because arch maintainers create such good documentation, it was really painless to stream audio from my laptop to the bluetooth radio.
I _have_ experienced loss of quality occasionally. Bringing the laptop closer to the radio fixes it, but I'd like to figure out what I can do to avoid this.