Forum
[DONE] xbian-package-a2dp - Printable Version

+- Forum (http://forum.xbian.org)
+-- Forum: Software (/forum-6.html)
+--- Forum: Additional Packages (/forum-22.html)
+--- Thread: [DONE] xbian-package-a2dp (/thread-2154.html)

Pages: 1 2 3 4


xbian-package-a2dp - belese - 4th Mar, 2014 10:07 AM

The first version implement a2dp over bluetooth.

it can pair device (always(default) or on demand with timeout)
once a bluetooth connection incoming, it load the alsa loopback module between bt source and output sink.

to start pairing, if pairing on demand :
Terminal
sudo start bluetooth-pairing,

(it should be possible to use keymap, and assign a key to start pairing.)

it is configurable through xbian-config inside xbmc, or via file : /etc/xbian-a2dp.conf

WARNING :
it's an EXPERIMENTAL package, i've installed without problem, but it need a lot of dependencies (alsa, pulseaudio),
so a backup before testing is recommended.

Also, if you have already configured bluettooth adapter, part of your configuration can be modified (backup as .xbian)
theses files will be modified :
/etc/bluetooth/audio.conf
/etc/pulse/daemon.conf
/etc/bluetooth/main.conf

others files will not be touched.

log can be found under
/var/log/upstart/bluetooth-a2dp
/var/log/upstart/bluetooth-pairing

and /var/log/upstart/bluetooth-* more general

to install

i've to manage dependency, it didn't want to install on fresh install,
so install depencies before
sudo apt-get install bluez alsa-base alsa-utils pulseaudio pulseaudio-module-bluetooth pulseaudio-utils python-gobject python-gobject-2 bluez-tools
Terminal
sudo dpkg -i xbian-package-a2dp1.0.deb
sudo apt-get install -f

source can be found here :
https://github.com/belese/xbian-package-a2dp

and the download link
https://github.com/belese/xbian-package-a2dp/blob/master/xbian-package-a2dp1.0.deb?raw=true

belese


Re: xbian-package-a2dp - f1vefour - 4th Mar, 2014 10:31 PM

Great work belese, will this allow XBMC video audio through Bluetooth headphones?


RE: xbian-package-a2dp - belese - 4th Mar, 2014 11:13 PM

no, xbmc on pi didn't use alsa yet, so no possible until that

it let you pair your phone, pc,... and stream music from it to xbian.
it work like this,
http://www.instructables.com/id/Turn-your-Raspberry-Pi-into-a-Portable-Bluetooth-A/?ALLSTEPS

but i've rewrited quite all with upstart script


Re: RE: xbian-package-a2dp - f1vefour - 5th Mar, 2014 12:45 AM

(4th Mar, 2014 11:13 PM)belese Wrote:  no, xbmc on pi didn't use alsa yet, so no possible until that

it let you pair your phone, pc,... and stream music from it to xbian.
it work like this,
http://www.instructables.com/id/Turn-your-Raspberry-Pi-into-a-Portable-Bluetooth-A/?ALLSTEPS

but i've rewrited quite all with upstart script

That's nice as well, lower power usage over using DLNA wifi.


RE: xbian-package-a2dp - belese - 5th Mar, 2014 12:54 AM

Yes, and i don't find the way to stream google music from my android phone with upnp,
quite all my music is there, and now it's easy!

if you know another solution, i'm interested too!!


Re: RE: xbian-package-a2dp - f1vefour - 5th Mar, 2014 06:00 AM

(5th Mar, 2014 12:54 AM)belese Wrote:  Yes, and i don't find the way to stream google music from my android phone with upnp,
quite all my music is there, and now it's easy!

if you know another solution, i'm interested too!!

This app can stream google music over upnp:

https://play.google.com/store/apps/details?id=com.bubblesoft.android.upnpcast


RE: xbian-package-a2dp - mk01 - 16th Mar, 2014 02:06 PM

can we make pulseaudio as optional ?

as with installed pulseaudio xbmc gotham forces it as default (no option to configure - it is hardcoded in xbmc) and having terrible output. 2


RE: xbian-package-a2dp - belese - 16th Mar, 2014 06:07 PM

Not sure,
All test case i've seen use pulse audio,
but seems i've read the bluez doc, and seems it's possible to use only alsa,
but i never play before with this part of linux (alsa,pulseaudio), maybe i'l give a try later to see.


RE: xbian-package-a2dp - mk01 - 16th Mar, 2014 06:10 PM

XBMC 12.x works ok on pulseaudio ?


RE: xbian-package-a2dp - belese - 16th Mar, 2014 06:18 PM

in fact, i don't use xbmc for now,
but small test i've done seems ok, (with hdmi, and test only some music, no video)
as i understand maybe i'm completely wrong,
but xbmc use omx player no? and i believe it shoudn't use alsa or pulseaudio, and use the gpu to output audio.


RE: xbian-package-a2dp - mk01 - 16th Mar, 2014 06:32 PM

@belese

you see how I'm completely mixed up now from Cubox. Cubox is general device support, no specialities, so ALSA, PULSE etc.

the PULSE issue is documented by XBMC team itself, even the fact that if "pulse" binary is found, you can't override this !

nobody from XBMC interested in fix for more than 1Y.

I just wan;t to say, installing this package on Cubox means no sound in XBMC. but you have remote BlueTooth speakers working via any soundcard (spdif, hdmi, USB) Wink

fair trade


RE: xbian-package-a2dp - belese - 16th Mar, 2014 06:51 PM

ok,
this could be interesting as it use only alsa

http://jamesbond3142.no-ip.org/blog/?viewCat=Bluetooth

i'll chek if it compile and work.
i think it need to be pipe to a player, so maybe xbmc can be use, but probably with a bigger lag.


RE: xbian-package-a2dp - belese - 3rd Apr, 2014 11:39 PM

@mk01,

it work now without pulse-audio,
i've installed on a clean rc1, and package work.

maybe it need to be recompiled for cubox, don't know about arm compatibility,

in next version, i'll try to have a integration inside xbmc.

i've no acces on xbianonpi repo, have done a push request


RE: xbian-package-a2dp - mk01 - 4th Apr, 2014 10:48 AM

few minutes ago I opened a discussion on git as I saw the .c source.

and then realised you are almost already finished.
I will take closer look during weekend.


RE: xbian-package-a2dp - belese - 4th Apr, 2014 06:21 PM

ok, continue discussion on git
also,
can you add me on xbian-package-a2dp on github?
i've seen you have add others, but not this one. thks