On Fri, 3 Jan 2003, Anders Torger wrote:

> I'm doing a maintenance update on the rme96 driver, and I wonder if 
> there are any conventions to follow in the driver concerning digital 
> sound cards.
> 
> The specific questions are how to handle sample rates and sound formats 
> on the input.
> 
> The sound card supports several sample rates and formats. What should 
> happen if the user tries to open the input with 48000 kHz ADAT, but the 
> format is actually 44100 kHz and SPDIF? I can allow it if I want to, 
> the user will get data, but at 48000 kHz of course.
> 
> What should happen when there is no input signal at all? The hardware 
> supports opening the input, but should I do so in the driver?
> 
> The signal can of course change in runtime as well...
> 
> I'm thinking of allowing it all, but I don't know if that is the right 
> way to go.

This part of PCM API has not been discussed. I think that we should follow
the most easy way: It is - allow only sample rate given by application, if
the master clock is using another sample rate - in trigger() callback -
driver will fail. Also it will fail, when sample rate is changed during
operation. We probably need to add a new PCM state -
SNDRV_PCM_STATE_STREAM_CHANGED (equal to DRAINING, but informative for
applications). The notification of master clock / sample rate (or other
parameter) changes should be implemented using the control API.

                                                Jaroslav

-----
Jaroslav Kysela <[EMAIL PROTECTED]>
Linux Kernel Sound Maintainer
ALSA Project, SuSE Labs



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Alsa-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/alsa-devel

Reply via email to