* SNDCTL_DSP_BUSY
@ 1999-10-22 21:22 Jirka Hanika
1999-10-22 23:17 ` SNDCTL_DSP_BUSY Paco
1999-10-25 10:07 ` SNDCTL_DSP_BUSY Thomas Sailer
0 siblings, 2 replies; 3+ messages in thread
From: Jirka Hanika @ 1999-10-22 21:22 UTC (permalink / raw)
To: linux-sound
Hi,
a programming question.
I need an ioctl or some other API to find out whether the sound card
has completely processed the buffers. Something exactly like
ioctl(SNDCTL_DSP_SYNC), but an asynchronous breed.
I have looked at audio.c and there is no such ioctl.
The only solution known to me is to write the neutral sample (silence)
asynchronously to the sound card until a bufferfarmfull bytes is
written, then ioctl(SNDCTL_DSP_RESET). This is however ugly as
12-bit FAT.
In case there is no better approach available, what would you think of a
new ioctl (say SNDCTL_DSP_BUSY)?
Jirka
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: SNDCTL_DSP_BUSY
1999-10-22 21:22 SNDCTL_DSP_BUSY Jirka Hanika
@ 1999-10-22 23:17 ` Paco
1999-10-25 10:07 ` SNDCTL_DSP_BUSY Thomas Sailer
1 sibling, 0 replies; 3+ messages in thread
From: Paco @ 1999-10-22 23:17 UTC (permalink / raw)
To: linux-sound
On Fri, 22 Oct 1999, Jirka Hanika wrote:
> Hi,
>
> a programming question.
>
> I need an ioctl or some other API to find out whether the sound card
> has completely processed the buffers. Something exactly like
> ioctl(SNDCTL_DSP_SYNC), but an asynchronous breed.
> I have looked at audio.c and there is no such ioctl.
>
> The only solution known to me is to write the neutral sample (silence)
> asynchronously to the sound card until a bufferfarmfull bytes is
> written, then ioctl(SNDCTL_DSP_RESET). This is however ugly as
> 12-bit FAT.
>
> In case there is no better approach available, what would you think of a
> new ioctl (say SNDCTL_DSP_BUSY)?
>
> Jirka
>
Hi, Jirka...
I'm slightly confused about what exactly it is that you want, but if you
simply want to wait for the soundcard to finish with the buffers before
your program progresses to the next stage, you can use a SNDCTL_DSP_POST.
Normally, the cards wait until the buffer is full before playing that
audio, but this will force the soundcard to play any data in the buffer,
even if the buffer is only partially filled.
Sorry if this is not the answer you are looking for, but I really wasn't
sure what the question was.
-Paco
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: SNDCTL_DSP_BUSY
1999-10-22 21:22 SNDCTL_DSP_BUSY Jirka Hanika
1999-10-22 23:17 ` SNDCTL_DSP_BUSY Paco
@ 1999-10-25 10:07 ` Thomas Sailer
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Sailer @ 1999-10-25 10:07 UTC (permalink / raw)
To: linux-sound
Jirka Hanika wrote:
> I need an ioctl or some other API to find out whether the sound card
> has completely processed the buffers. Something exactly like
SNDCTL_DSP_ODELAY
Tom
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~1999-10-25 10:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-10-22 21:22 SNDCTL_DSP_BUSY Jirka Hanika
1999-10-22 23:17 ` SNDCTL_DSP_BUSY Paco
1999-10-25 10:07 ` SNDCTL_DSP_BUSY Thomas Sailer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox