Skip to contentSkip to conversation

alsaplayer and jackd faild on snd_pcm_hw_params_set_period_size(...) call

DISCUSSION Benny Sjostrand 2 participants 2 messages Aug 11, 2002 – Aug 12, 2002

lore
Share & tools
lore
#0 lore raw

Hi!

Trying some native ALSA applications I got some problems, "alsaplayer" and the "jackd" both seems to fail on the same call: snd_pcm_hw_params_set_period_size(...) in alsa-lib

the jackd:
[gorm@cactus alsa-driver]$ jackd -d alsa -p 1024 -d pcm.cs46xx jackd 0.34.0
Copyright 2001-2002 Paul Davis and others.
jackd comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it under certain conditions; see the file COPYING for details

creating alsa driver ... pcm.cs46xx|1024|2|48000|swmon
ALSA: cannot set period size to 1024 frames for capture
ALSA: cannot configure capture channel
cannot load driver module alsa
jack main caught signal 15
[gorm@cactus alsa-driver]$

the alsaplayer output:
error on set_period_size (1024)
Unavailable hw params:

ACCESS:  RW_INTERLEAVED
FORMAT:  S16_LE
SUBFORMAT:  STD
SAMPLE_BITS: 16
FRAME_BITS: 32
CHANNELS: 2
RATE: 44100
PERIOD_TIME: (11609 11610)
PERIOD_SIZE: 512
PERIOD_BYTES: 2048
PERIODS: [2 32]
BUFFER_TIME: (23219 371520)
BUFFER_SIZE: [1024 16384]
BUFFER_BYTES: [4096 65536]
TICK_TIME: 10000

failed to configure output device...trying OSS

(I just hate to mess around with the user mode stuffs ....)

As you probably can guess I'm using the latest CVS with my recently patched cs46xx driver, what I dont understand is how is the snd_pcm_hw_params_set_period_size(..) function is mapped down to the HW driver ??????

The other thing is that all OSS application works without any problems, like XMMS, etc.

I've been looking around in the alsa-lib, well,.. probably you can give some hints about this, I'm still a newbie to the ALSA architecture.

/Benny

-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf

#1 lore raw
Quoted 14 lines · Benny Sjostrand

Hi!

Trying some native ALSA applications I got some problems, "alsaplayer" and the "jackd" both seems to fail
on the same call: snd_pcm_hw_params_set_period_size(...) in alsa-lib

the jackd:
[gorm@cactus alsa-driver]$ jackd -d alsa -p 1024 -d pcm.cs46xx jackd 0.34.0
Copyright 2001-2002 Paul Davis and others.
jackd comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it under certain conditions; see the file COPYING for details

Quoted 3 lines

creating alsa driver ... pcm.cs46xx|1024|2|48000|swmon
ALSA: cannot set period size to 1024 frames for capture
ALSA: cannot configure capture channel

Use 512 frames for period size. The period size is hardwired in the driver. Maybe, your firmware changes allow different period sizes. If it's true, it would be nice to change the driver code.

Jaroslav

-----
Jaroslav Kysela <[email protected]>
Linux Kernel Sound Maintainer
ALSA Project http://www.alsa-project.org
SuSE Linux http://www.suse.com

-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf