You are not logged in.
Pages: 1
Does anybody know how to marry bluetooth and alsa?
Offline
Does anybody know how to marry bluetooth and alsa?
Check this https://wiki.debian.org/Bluetooth/Alsa
What economists call over-production is but a production that is above the purchasing power of the worker, who is reduced to poverty by capital and state.
----+- Peter Kropotkin -+----
Offline
Check this https://wiki.debian.org/Bluetooth/Alsa
It does not work. This package is not in repo. Tried to install it from devuan ceres repo and from debian sid repo, got the same result n blueman Connection Failed: No audio endpoints registered
Tried to reinstall all other packages like bluetoth, bluez blueman from ceres or sid - did not work.
The output of bluealsa-aplay -L
bluealsa-aplay: W: Couldn't get BlueALSA PCM list: The name org.bluealsa was not provided by any .service files
Offline
Here are some things that can help you:
What economists call over-production is but a production that is above the purchasing power of the worker, who is reduced to poverty by capital and state.
----+- Peter Kropotkin -+----
Offline
Worth a go here as my trusy old Vaio netbook has **** sound (and I don't want pulseaudio).
I got bluealsa working but it was not so simple. For a start packages bluez-alsa-utils libasound2-plugin-bluez (you need both) have only a systemd service file, no sysv script. I needed bluetooth daemon running first and a custom ~/.asoundrc
pcm.SoundCoreMini {
type bluealsa
device "XX:XX:XX:XX:XX:XX"
profile "a2dp"
hint { show on description "Sound Core Mini"}
}
Having already installed blueman I could use those tools to get the device ID. The device can then be manipulated using blueman-manager.
I repackaged it with a custom init script but havent got that quite right as yet. It won't detach from the shell and hangs on bootup. But I can start it manually after disabling the init daemon.
Running chimaera you *might* get away with just a few lib deps from ceres. The original packages will break beowulf. My crude "backport" rebuild from source can run on beowulf.
Here's the offending custom init script, if anyone wants to debug it. More later (if) I get time to revisit this. Or maybe it's better not to have this start automatically..
#!/bin/sh
### BEGIN INIT INFO
# Provides: bluez-alsa
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Required-Start: $syslog $local_fs $remote_fs bluetooth
# Required-Stop: $syslog $local_fs $remote_fs
# Short-Description: Bluealsa daemon
### END INIT INFO
. /lib/lsb/init-functions
prog=bluez-alsa
if test -f -/etc/default/bluez-alsa; then
. -/etc/default/bluez-alsa
fi
PIDFILE=/var/run/$prog.pid
DESC="Bluealsa daemon"
start() {
log_daemon_msg "Starting $DESC" "$prog"
start_daemon -p $PIDFILE /usr/bin/bluealsa $OPTIONS
if [ $? -ne 0 ]; then
log_end_msg 1
exit 1
fi
if [ $? -eq 0 ]; then
log_end_msg 0
fi
exit 0
}
stop() {
log_daemon_msg "Stopping $DESC" "$prog"
killproc -p $PIDFILE /usr/bin/bluealsa
if [ $? -ne 0 ]; then
log_end_msg 1
exit 1
fi
if [ $? -eq 0 ]; then
log_end_msg 0
fi
}
force_reload() {
stop
start
}
case "$1" in
start)
start
;;
stop)
stop
;;
force-reload)
force_reload
;;
restart)
stop
start
;;
*)
echo "$Usage: $prog {start|stop|force-reload|restart}"
exit 2
esac
My installed bluetooth-related packages:
root@vaio:~# dpkg -l|grep blue
ii blueman 2.0.8-1+deb10u1 amd64 Graphical bluetooth manager
ii bluez 5.50-1.2~deb10u2 amd64 Bluetooth tools and daemons
ii bluez-alsa-utils 3.0.0-2 amd64 Bluetooth Audio ALSA Backend (utils)
ii bluez-firmware 1.2-4 all Firmware for Bluetooth devices
ii bluez-obexd 5.50-1.2~deb10u2 amd64 bluez obex daemon
ii libasound2-plugin-bluez:amd64 3.0.0-2 amd64 Bluetooth Audio ALSA Backend (plugins)
ii libbluetooth-dev:amd64 5.50-1.2~deb10u2 amd64 Development files for using the BlueZ Linux Bluetooth library
ii libbluetooth3:amd64 5.50-1.2~deb10u2 amd64 Library to use the BlueZ Linux Bluetooth stack
ii libpam-blue 0.9.0-3 amd64 PAM module for local authenticaction with bluetooth devices
EDIT: example use:
:~$ mpv --audio-device=alsa/SoundCoreMini 'Sweet Georgia Brown 1.m4a'
Or in VLC, pick it from the audio device GUI.
Cheers all (and thanks for chimaera), D
Last edited by dzz (2021-10-26 14:14:42)
Offline
I repackaged it with a custom init script but havent got that quite right as yet. It won't detach from the shell and hangs on bootup. But I can start it manually after disabling the init daemon.
Looks like it's a dbus service so it probably won't work unless you can hook it into that somehow with sysvinit (systemd listens to the bus automatically). But this is just a guess; I don't use Bluetooth.
Here's the offending custom init script, if anyone wants to debug it.
Looks fine to me but you don't have to test for the exit status after starting the daemon — just use the conditional instead, like this:
start() {
log_daemon_msg "Starting $DESC" "$prog"
if start_daemon -p $PIDFILE /usr/bin/bluealsa $OPTIONS ; then
log_end_msg 0
else
log_end_msg 1
fi
}
Oh, and $Usage is referenced but not assigned but I think that's a typo :-)
Brianna Ghey — Rest In Power
Offline
Thanks HoaS!
Looks like it's a dbus service so it probably won't work unless you can hook it into that somehow with sysvinit (systemd listens to the bus automatically). But this is just a guess.
It does here, maybe the dbus bits are built-in. That init script does work from a root shell after boot (although still will not detach, that was the issue)
Now using a simple manual /usr/local/bin start script with sudo permission so it only runs on demand, in preference.
Cable the speaker to the old vaio? The cable is always either lost or broken!
Offline
Pages: 1