Skip to content

Bluetooth Headset and Linux

Last updated on 2007-04-12

The [Alsa-Bluetooth project]( http://sourceforge.net/projects/bluetooth-alsa/) project provides a way to use a bluetooth headset with Linux.They do this currently by making an alsa kernel driver which uses bluez to reach the headset.

I Wrote a [KDE](http://kde.org/) based user space daemon wich works as drop in replacement for the btsco daemon from the [Alsa-Bluetooth]( http://sourceforge.net/projects/bluetooth-alsa/) package. The Programm is in early beta stage. Just start it from the Console and you will have a small kicker applet in your Systray. **KBtsco** has a function to discover the BAddr of your Headset. Once you did the pairing via e.g. [KBluetoothd](ttp://kde-bluetooth.sourceforge.net/) package, you can click the headset icon in the Systray to connect to the headset. All actions get visualized via On-Screen-Display in the right corner of your monitor. After connecting you can push your connect button on the headset wich actually opens the sco socket. I used this tool on daily basis with [Skype](http://www.skype.com/). Sometimes snd_bt_sco seems to crash and eats all CPU time,it’s still beta i think.

![Snes](http://optixx.org/images/kbtsco/kbtsco_s01.png)
![Snes](http://optixx.org/images/kbtsco/kbtsco_s02.png)

[Picture 1](http://optixx.org/images/kbtsco/kbtsco01.png)

[Picture 2](http://optixx.org/images/kbtsco/kbtsco02.png)

[Download](http://optixx.org/download/kbtsco-0.1.tar.gz)

4 Comments

  1. sirkus sirkus

    Hello, good job, KBtsco found my (paired) headset, but…
    i can’t connect to the headset, what’s wrong

    KBtsco: KBtscoWorker::run cmd=1
    KBtsco: KBtscoWorker::btscoOpen
    KBtsco: KBtscoWorker::findDevice hwdep next device (hw:0): Operation not permitted
    KBtsco: KBtscoWorker::findDevice control open (hw:1): Permission denied
    Can’t find device. Bail: Permission denied
    KBtsco: KBtscoWorker::run no cmd going to sleep

    anyway this program is a very good idea for a simplier life.

  2. Administrator Administrator

    I this call fails.

    err = snd_ctl_open(ctl_handle, card_id, 0))

    This is something ALSA related. Iam not an ALSA Expert, but i would suggest to test this.

    o Is the snd_bt_sco module loaded
    hunter david # lsmod | grep snd_bt_sco
    o Have a correct Alsa setup for it.
    o Does Alsa subsystem init the card ?
    hunter david # cat /proc/asound/cards
    0 [ICH6 ]: ICH4 – Intel ICH6
    Intel ICH6 with AD1986 at 0xdffffe00, irq 23
    1 [Headset ]: Bluetooth SCO – BT Headset
    BT Headset 1
    o Is There a Sound device for the BTsco card ?
    o Do the Sound Device have prober Permission ?
    o Does Alsamixer work on the BTsco card.
    david@hunter ~ $ alsamixer -c 1

  3. Whoopie Whoopie

    @sirkus: You need to compile the emu10k1 module into the kernel. Then you don’t have the hwdep problem anymore.

    But I’ve also a problem: the kbtsco doesn’t use the right rfcomm channel. It selects “/x01” as channel. That’s the output on the console. I’m using a Jabra BT250v headset.
    DO you have any hints?

    Thanks a lot for your help (and of course your program),
    Whoopie

  4. Administrator Administrator

    DO you run the SDP server? If not the KBtscoWorker::detectChannel(bdaddr_t * bdaddr) will fail and the default channel 1 is taken. If this isn’t suitable for you, just change the default channel in this method.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.