2008-11-07 16:27:41

by martin f krafft

[permalink] [raw]
Subject: btusb+sco: unable to install hw params (set_params:979)

Hi folks,

I am trying to get btusb to work with my two SCO headsets (BT250 and BT500v) on
two different machines (i386 and amd64), both running 2.6.26. I am
pretty much following the instructions at
http://wiki.bluez.org/wiki/HOWTO/AudioDevices, which are "valid for
bluez-utils-3.16 or newer". I am using Debian's 3.36-1 on both
machines.

My .asoundrc has this content:

pcm.bt250 {
type bluetooth
device "00:07:A4:01:AB:A3"
profile "sco"
}
ctl.bt250 {
type bluetooth
}

and I put the headset into pairing mode, then ran this command:

$ strace -f -o /tmp/arecord.strace arecord -f S16_LE -D bt250 >/tmp/test.wav
Recording WAVE 'stdin' : Signed 16 bit Little Endian, Rate 8000 Hz, Mono

This caused bluetooth-applet to prompt me for the passkey and
finally to tell me that the bonding had been established, just as
there's a little tone in the headset to acknowledge the connection.

However, /tmp/test.wav won't grow, and after a few seconds, arecord
exits with $?=0 (!!) after spouting to the terminal:

ALSA lib pcm_bluetooth.c:464:(bluetooth_hsp_hw_params) BT_SETCONFIGURATION failed : Input/output error(5)
arecord: set_params:979: Unable to install hw params:
ACCESS: RW_INTERLEAVED
FORMAT: S16_LE
SUBFORMAT: STD
SAMPLE_BITS: 16
FRAME_BITS: 16
CHANNELS: 1
RATE: 8000
PERIOD_TIME: 125000
PERIOD_SIZE: 1000
PERIOD_BYTES: 2000
PERIODS: 4
BUFFER_TIME: 500000
BUFFER_SIZE: 4000
BUFFER_BYTES: 8000
TICK_TIME: [0 0]

/tmp/test.wav is size 0. :(

I see precisely the same behaviour with any combination of the two
machines, the two headsets and three bluetooth dongles. Yes, I tried
them all. Yes, I am somewhat desperate by now.

I have bluez-audio installed, but /etc/bluetooth/audio.conf is
default. No PulseAudio or anything other than plain ALSA here...

Any clues what could be going on?

--
martin | http://madduck.net/ | http://two.sentenc.es/

"i wish i hadn't slept all day, it's really lowered my productivity"
-- robert mcqueen

spamtraps: [email protected]


Attachments:
(No filename) (2.02 kB)
digital_signature_gpg.asc (197.00 B)
Digital signature (see http://martin-krafft.net/gpg/)
Download all attachments

2008-11-13 10:11:42

by martin f krafft

[permalink] [raw]
Subject: Re: btusb+sco: unable to install hw params (set_params:979)

also sprach martin f krafft <[email protected]> [2008.11.07.1727 +0100]:
> $ strace -f -o /tmp/arecord.strace arecord -f S16_LE -D bt250 >/tmp/test.wav
> Recording WAVE 'stdin' : Signed 16 bit Little Endian, Rate 8000 Hz, Mono

On my last try with the voice profile, I found this in the syslog:

hcid[30479]: Audio API: received BT_GETCAPABILITIES_REQ
hcid[30479]: Audio API: sending BT_GETCAPABILITIES_RSP
hcid[30479]: Audio API: received BT_SETCONFIGURATION_REQ
hcid[30479]: config sco - device = 00:1A:45:14:EE:D7 access_mode = 1
hcid[30479]: connect(): Connection timed out (110)
hcid[30479]: Unable to lock headset
hcid[30479]: config failed
hcid[30479]: Audio API: sending BT_SETCONFIGURATION_RSP

If I use the sco profile, I get:

hcid[30479]: Audio API: received BT_GETCAPABILITIES_REQ
hcid[30479]: Audio API: sending BT_GETCAPABILITIES_RSP
hcid[30479]: Audio API: received BT_SETCONFIGURATION_REQ
hcid[30479]: config sco - device = 00:1A:45:14:EE:D7 access_mode = 1
kernel: [600899.137535] hci_scodata_packet: hci0 SCO packet for unknown connection handle 42

This last message comes in at a rate of 100/s while the bluetooth
LED on the headset flashes 1/s, until I remove hci0 or kill hcid.

--
martin | http://madduck.net/ | http://two.sentenc.es/

tempt not a desperate man.
-- william shakespeare

spamtraps: [email protected]


Attachments:
(No filename) (1.40 kB)
digital_signature_gpg.asc (197.00 B)
Digital signature (see http://martin-krafft.net/gpg/)
Download all attachments

2008-11-07 16:37:37

by martin f krafft

[permalink] [raw]
Subject: Re: btusb+sco: unable to install hw params (set_params:979)

also sprach martin f krafft <[email protected]> [2008.11.07.1727 +0100]:
> $ strace -f -o /tmp/arecord.strace arecord -f S16_LE -D bt250 >/tmp/test.wav
> Recording WAVE 'stdin' : Signed 16 bit Little Endian, Rate 8000 Hz, Mono

strace attached, with -tt.

FWIW, I let dbus-monitor run alongside and there was not a single
event between running the above and seeing the error.

--
martin | http://madduck.net/ | http://two.sentenc.es/

. `___
(o- (o- (o- (o- (o- (o- (o- /\/| | |
//\ //\ //\ //\ //\ //\ //\ ` /\/\/l-+-|
v_/_ v_/_ v_/_ v_/_ v_/_ v_/_ v_/_ .` /\/\/|_|_|

spamtraps: [email protected]


Attachments:
(No filename) (0.00 B)
digital_signature_gpg.asc (197.00 B)
Digital signature (see http://martin-krafft.net/gpg/)
Download all attachments