Forum

Full Version: [How To] RPi Bluetooth Audio Receiver on latest Xbian [30/05/2016]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi All,

After A LOT of trial and error, I have simplified the process of getting RPi to work as a Bluetooth Audio receiver on the latest release of Xbian with Raspberry Pi 3 using the built-in bluetooth module. I hope this can be helpful to someone.

Open up ssh/terminal and run the following commands:

Install Packages
Terminal
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install pulseaudio-module-bluetooth bluez-tools
Notes: Fairly straightforward step. Preferably do a clean install to avoid any configuration issues.

Add users to groups
Terminal
sudo gpasswd -a xbian pulse
sudo gpasswd -a xbian lp
sudo gpasswd -a pulse lp
sudo gpasswd -a xbian audio
sudo gpasswd -a pulse audio

Setup PulseAudio & Bluetooth Device
Terminal
sudo sh -c "echo 'extra-arguments = --exit-idle-time=-1 --log-target=syslog' >> /etc/pulse/client.conf"
sudo hciconfig hci0 up
sudo hciconfig hci0 class 0x200420
sudo reboot

Add Bluetooth Device
Terminal
sudo bluetoothctl
The following commands inside bluetoothctl only needs to run once only when setting up:
Terminal
agent KeyboardOnly
default-agent
The following commands inside bluetoothctl needs to run every time you need to add a new device:
Terminal
scan on
pair xx:xx:xx:...
trust xx:xx:xx:...
exit
Notes: Make your phone/tablet's Bluetooth discoverable before executing `scan on`. Wait for a minute until your device is discovered and MAC address is displayed. Use the MAC address in the pair & trust steps.
After exiting bluetoothctl, initiate the connection from the paired phone/tablet, and play some music Smile

Let me know if this works out for you.
That's an awesome first post.
(30th May, 2016 03:33 PM)f1vefour Wrote: [ -> ]That's an awesome first post.

Thank you Wink I have been using Xbian on my Pi2 since last year with no issues so thank you and the Xbian Team for that. Just upgraded to Pi3 and I have more ideas Idea I will be working on over weekends. Will post them as they get completed and simplified Smile
(30th May, 2016 05:29 PM)abdulmueid Wrote: [ -> ]
(30th May, 2016 03:33 PM)f1vefour Wrote: [ -> ]That's an awesome first post.

Thank you Wink I have been using Xbian on my Pi2 since last year with no issues so thank you and the Xbian Team for that. Just upgraded to Pi3 and I have more ideas Idea I will be working on over weekends. Will post them as they get completed and simplified Smile

Nice one. Thank you for collaboration

Thread title edited.
@abdulmueid

Yeah, it's really good having more inputs. I'm already working with bluetooth (still in learning phase) but I'm missing one command in your sequence:

Terminal

connect xx:xx:xx:...

is not there Huh
(30th May, 2016 10:54 PM)Nachteule Wrote: [ -> ]@abdulmueid

Yeah, it's really good having more inputs. I'm already working with bluetooth (still in learning phase) but I'm missing one command in your sequence:

Terminal

connect xx:xx:xx:...

is not there Huh

No need to connect from Pi. After pair and trust, connection must be initiated from phone/tablet. I'll clean up the instructions little later with more explanations.
Reference URL's