On Wed, 10 Dec 2003, Paul Davis wrote:
> >I wanted to check my knowledge of something: does an xrun necessarily
> >correspond to a "drop-out" in the audio stream? In other words, could
> >you have a drop-out WITHOUT an xrun, or an xrun WITHOUT a drop-out? Is
> >there a strict one-to-one correspondence between the two?
>
> a dropout occurs when the h/w playback pointer gets ahead of the data
> already written by the s/w (i.e. repeating data already played). its
> therefore a 1:1 correspondence with an xrun, which is defined in the
> same way.
To be 100% correct, in the driver, there is very small window where the
hardware might be in xrun state, but we cannot detect this situation:
disable_interrupts();
pos = get_current_position();
<--- DMA transfer occured here and position (pos) was
on last valid sample -->
if (xrun(pos))
do_xrun_handling();
enable_interrupts();
Jaroslav
-----
Jaroslav Kysela <[EMAIL PROTECTED]>
Linux Kernel Sound Maintainer
ALSA Project, SuSE Labs
-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive? Does it
help you create better code? SHARE THE LOVE, and help us help
YOU! Click Here: http://sourceforge.net/donate/
_______________________________________________
Alsa-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/alsa-devel