public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: Wolfgang Wershofen <wolfgang@wershofen.de>
To: bluez-users@lists.sourceforge.net
Subject: Re: [Bluez-users] plugz: snd_pcm_hw_params_set_rate(8287) failed: Invalid argument
Date: Thu, 22 Feb 2007 00:27:28 +0100	[thread overview]
Message-ID: <200702220027.28783.wolfgang@wershofen.de> (raw)
In-Reply-To: <45DAC336.1080806@wershofen.de>

Am Dienstag, 20. Februar 2007 schrieb Wolfgang Wershofen:
> Hi,
>
> I'm rather new to using bluetooth devices but I successfully managed to
> get my headset running using plugz. I use it for telephony purposes with
> twinkle (http://www.twinklephone.com).
>
> I am able to hear people and talk to them during the phone call without
> problems, but I can't hear the ringtone created by twinkle on my
> headset. In the log files, I find the following error message:
>
> snd_pcm_hw_params_set_rate(8287) failed: Invalid argument
>
(...)
> I don't know, if this is a plugz issue or a twinkle issue and I didn't
> find anything related on the net.

Meanwhile, I got an answer from the author of twinkle as follows:

---- < snip > -----------------------------------------------------------
This error shows that setting the soundcard to an exact sample
rate of 8287 fails (this sample rate comes from ringback.wav).
Twinkle uses this call to set an exact rate:

err =3D snd_pcm_hw_params_set_rate (pcm_ptr, hw_params, sample_rate, 0)

This happens on some soundcard and is not fatal, as Twinkle
next instructs the soundcard to pick a lower sampe rate
that it can suppor with this call:

err =3D snd_pcm_hw_params_set_rate (pcm_ptr, hw_params, sample_rate, -1)

The -1 argument indicates that =A0the soundcard may pick a lower
sample rate. It seems that your alsa does not accept this parameter.
---- < snap > -----------------------------------------------------------

I got around this problem by supplying twinkle with a wav audio file with =

exactly 8000 Hz sample rate and now it works.

But the question still remains: Why is the setting of a sample rate not =

possible with plugz?

cu
Wolfgang

-- =

Geek by nature - Linux by choice

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3DDE=
VDEV
_______________________________________________
Bluez-users mailing list
Bluez-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-users

      reply	other threads:[~2007-02-21 23:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-20  9:45 [Bluez-users] plugz: snd_pcm_hw_params_set_rate(8287) failed: Invalid argument Wolfgang Wershofen
2007-02-21 23:27 ` Wolfgang Wershofen [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200702220027.28783.wolfgang@wershofen.de \
    --to=wolfgang@wershofen.de \
    --cc=bluez-users@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox