Configuring bluetooth stereo headphones in Ubuntu Linux (8.04 & 7.10)

    Hello!
    I decided to write a little instruction to help those who need to set up bluetooth headphones for Linux. The described method is guaranteed to work in Ubuntu 7.10 and 8.04. Other systems should not have any special problems if they have all the necessary components (bluez, alsa, python).


    Last year I bought a Plantronics 590A bluetooth stereo headset (+ headset) . Great headphones - good sound quality and complete freedom from wires. After switching from Windows XP to Ubuntu, the question arose of using headphones, both as ordinary headphones for audio output, and a full-fledged headset for communicating in games and on Skype.

    Although the standard Ubuntu bluetooth manager, it seems, implies the use of the Audio Servicefor the corresponding bt-devices, but I could not quickly find clear instructions on how to organize the sound output to the headphones.



    Soon I came across a wonderful program BlueMan bluetooth manager ( screenshots ). This program is worthy of a separate article, since it has a lot of features and it makes life much easier for anyone who needs to work with various devices via the bluetooth protocol. The program runs "on top" of the standard Ubuntu-ov bt-stack bluez and practically does not draw any dependencies (the program is written in python`e).
    I will not list all the features of the program, I will limit myself only to the fact that the program supports bt-devices with the A2DP profile



    All you need to do in BlueMan is to “pair” your bt-headphones with the program. After "sparing" I additionally activated the use of the sound service in the program parameters.



    In the settings for the sound service, I activated using the Headset, Sink, Control services for my headphones. For normal audio output, the Headset service is sufficient. Other services are present, I think, to support the work of the AVRCP bt-profile . I did not check the profile in any program in Ubuntu, so I can not say anything about its performance.

    The last step is to fix the ~ / .asoundrc file . I am not a big Coppenhagen in the ALSA configuration file , all edits were spied from articles:
    1. http://alfa2linux.blogspot.com/2008/03/my-jabra-finally-working-with-bluez.html
    2. http://wiki.bluez.org/wiki/HOWTO/AudioDevices
    Я не ставил никаких дополнительных пакетов, которые были упомянуты в статьях — bluetooth-alsa, btsco и др.

    В файл .asoundrc я добавил такие строки:

    pcm.bluetooth {
       type bluetooth
    }

    После редактирования файла у вас появляется возможность указывать в необходимых программах новое звуковое устройство — bluetooth. In article No. 2, from the list I have given, it is shown how to configure many popular programs for working with bt-headphones. Now I successfully work with bt-headphones SMPlayer and Pidgin. I also successfully managed to use my headphones as a headset for communicating via Skype. A new audio device, bluetooth, appears in Skype’s audio settings. Having set up Skype to work with the new device, I was able to successfully talk through the bt-headset.



    The only annoying moment- for some reason, after the first conversation on Skype or when listening to music from Pidgin, the second time Skype does not allow you to start a conversation, referring to "problems with sound capture." There was a half solution - turning off / on the headphones (pairing again) allows you to use Skype again. This problem is seen only with Skype, perhaps in the future it will be fixed. I'm not sure that the problem is in Skype itself, most likely the dog is buried in the bowels of bluez and is connected with the operation of the headset microphone, because sound output always works fine.
    Summary: Although the initial setup of the headphones may seem long, but having passed it you get the full opportunity to work with bt-headphones. The only problem that remains unresolved is how to force ALSA to use bluetooth headphones as the main source for audio output in the system when the headphones are paired with a computer. At the moment, you have to keep two shortcuts to the same programs, each of the shortcuts reconfigures the sound output / input to the necessary device. So far, I have not found a more beautiful solution. PS This is my first post on the hub, do not kick too much, if you missed something :)




    Also popular now: