LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 01-08-2020, 02:18 PM   #1
Panagiotis Nik
LQ Newbie
 
Registered: Jul 2014
Distribution: Slackware64-Current, Slackware64-14.2
Posts: 27

Rep: Reputation: Disabled
ALSA and bluetooth audio


Hello,

Recently I received as a gift a bluetooth speaker. My Slackware64-current desktop (Xfce) is pure ALSA and when I first tried to connect with my speaker trough blueman-manager I received a “protocol error”.

Searching for a solution I founded that there's a program called "bluez-alsa" that offers integration between BlueZ >= 5 and ALSA.
There’s already a SlackBuild for "bluez-alsa" buit since it was outdated I tweaked it in order to install the latest version of "bluez-alsa" and then I was able to connect with my speaker.

After some changes in my asound.conf I was able to have sound in my speaker although they're some problems:
When I’m in youtube the only way to switch to an other sound source is to close the tab since to stop the player is not enough (I’m using Firefox as my browser.)
Also I need to add the output line in my xfce4-mixer since now is missing and there’s no option to adjust the sound level.

I’m wondering if somebody else using "bluez-alsa" and can share more information.
 
Old 01-08-2020, 04:18 PM   #2
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2.1.2 on Lenovo Thinkpad W520
Posts: 9,174

Rep: Reputation: Disabled
Caveat emptor: this post is OT as my setting is not pure-alsa.

Last month I received as gifts from my sons an USB sound board and a bluetooth headset.

As soon as I connect one of these devices it appears in the pavucontrol GUI in both Setup and Output devices tabs, so I can do what I want easily, like mute or unmute one of them, set its volume specifically etc.

I have nothing in /etc/asound.conf (no redirection to pulse) but have this setting in /etc/pulse/default.pa:
Code:
load-module module-alsa-sink device=dmix
load-module module-alsa-source device=dsnoop
Just my

EDIT. I almost forgot: I can do also many settings with a right click in the mixer applet of Mate Panel choosing Preferences. It has several tab: sound effects (set a sound alert and its volume), hardware (choose of the profile and test of the channels), input (choice of the device and input volume), output (setting of the volumes of the devices) applications (setting of the volume of the sound produced by each application).

Last edited by Didier Spaier; 01-08-2020 at 04:51 PM. Reason: EDIT added.
 
Old 01-09-2020, 10:00 PM   #3
Panagiotis Nik
LQ Newbie
 
Registered: Jul 2014
Distribution: Slackware64-Current, Slackware64-14.2
Posts: 27

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Didier Spaier View Post
I have nothing in /etc/asound.conf (no redirection to pulse) but have this setting in /etc/pulse/default.pa:
Code:
load-module module-alsa-sink device=dmix
load-module module-alsa-source device=dsnoop
Thanks for the suggestion. I already tried to add dmix in my asoundrc although without luck.

Quote:
Originally Posted by Didier Spaier View Post
EDIT. I almost forgot: I can do also many settings with a right click in the mixer applet of Mate Panel choosing Preferences. It has several tab: sound effects (set a sound alert and its volume), hardware (choose of the profile and test of the channels), input (choice of the device and input volume), output (setting of the volumes of the devices) applications (setting of the volume of the sound produced by each application).
For the moment I made a small script to change from my headphones to the bluetooth speaker and vice versa since xfce audio mixer is missing the output.
Any way I'm very happy that I can have bluetooth audio without to use pulse
 
Old 01-10-2020, 04:02 AM   #4
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2.1.2 on Lenovo Thinkpad W520
Posts: 9,174

Rep: Reputation: Disabled
Quote:
Originally Posted by Panagiotis Nik View Post
Thanks for the suggestion. I already tried to add dmix in my asoundrc although without luck.
The goal of these settings in default.pa is have pulse using the dmix alsa mixer so they only make sense if pulse is installed

Quote:
For the moment I made a small script to change from my headphones to the Bluetooth speaker and vice versa since xfce audio mixer is missing the output.
Any way I'm very happy that I can have Bluetooth audio without to use pulse
I just checked in XFCE 4.14. Same as in Mate 1.22: as soon as I switch on my Bluetooth headset the xfce4 mixer on the panel can handle it.

But feel free to make your life more complicated just to avoid installing pulse.

As an aside, I still didn't find in the many posts from pulse haters in this forum a rationale not to have it installed. I suspect that most just don't know how to properly set alsa + pulseaudio (+ optionally jack) for their use case. To learn it's worthwhile reading PulseAudio under the hood from Victor Gaydov.

Last edited by Didier Spaier; 01-10-2020 at 04:06 AM.
 
Old 01-12-2020, 07:25 AM   #5
Nille_kungen
Member
 
Registered: Jul 2005
Posts: 524

Rep: Reputation: 181Reputation: 181
You need pulse audio for bluetooth audio to work in current.
"bluez-alsa" didn't work with any bluetooth headphone or headsets last time that i tried but maybe it works better now.
I had problems with my computer hanging all the time when i tried to use bluetooth audio without pulse audio.

Bluez5 dropped alsa support.
https://git.kernel.org/pub/scm/bluet...328cb0b1ab0818
https://github.com/Arkq/bluez-alsa

Last edited by Nille_kungen; 01-12-2020 at 10:30 AM.
 
Old 01-12-2020, 09:24 AM   #6
Tonus
Member
 
Registered: Jan 2007
Location: Paris, France
Distribution: Slackware-current
Posts: 585
Blog Entries: 3

Rep: Reputation: 153Reputation: 153
ALSA and bluetooth audio

@Didier :
I have pulse installed.
I find it overall complicated and hard to deal with.
I had lot of work to script the switch speakers/bt/jack. Nothing is simple with it and documentation is a pity.

That said, it works.
 
Old 01-13-2020, 09:12 PM   #7
Panagiotis Nik
LQ Newbie
 
Registered: Jul 2014
Distribution: Slackware64-Current, Slackware64-14.2
Posts: 27

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Nille_kungen View Post
You need pulse audio for bluetooth audio to work in current.
"bluez-alsa" didn't work with any bluetooth headphone or headsets last time that i tried but maybe it works better now.
I had problems with my computer hanging all the time when i tried to use bluetooth audio without pulse audio.

Bluez5 dropped alsa support.
https://git.kernel.org/pub/scm/bluet...328cb0b1ab0818
https://github.com/Arkq/bluez-alsa
In my case bluealsa works with my speakers although there're some small glitches like the xfce audio mixer is missing the output line and I can have sound in Firefox in one tab at the time...

In order to load successfully bluealsa in my system (Slackware64-current) I made a script to start-stop bluealsa and restart rc.alsa at the same time instead an entry in rc.local (/usr/bin/bluealsa &) that was suggested by the SlackBuild.
With that way I can switch the sound between my bluetooth speaker and my headphones without a problem.

I believe that bluez-alsa is a project that needs more attention since after bluez dropped support for alsa one in order to have bluetooth audio in Slackare needs to install pulse audio.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] bluetooth dongle + bluetooth speaker but no sound on the bluetooth speaker vonbiber Slackware 4 05-11-2017 10:53 AM
How to switch my alsa card 0 and alsa card 1 in ALSA? frenchn00b Debian 10 12-11-2009 01:16 PM
integrated hda audio modem bluetooth , (intel hda audio does not work) reggae linux Linux - Laptop and Netbook 1 07-05-2006 11:13 PM
integrated hda audio modem bluetooth , (intel hda audio does not work) reggae linux Linux - Laptop and Netbook 2 07-05-2006 04:38 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 08:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration