[wdmaudiodev] Re: firewire audio at low latency

  • From: "Stephan Kappertz" <stephan@xxxxxxxxxx>
  • To: <wdmaudiodev@xxxxxxxxxxxxx>
  • Date: Tue, 9 Sep 2003 11:26:33 +0200

> I still wonder if there is a technical reason why the isoch listen
callbacks are
> not spaced equidistantly @50 sample. I think hardware interrupts should
not be
> delayed for about 1.1ms
Your isoch callback is not called directly from the interrupt service
routine of the firewire controller driver. Instead a DPC is requested for
every interrupt. Your callback is then called from within this DPC. Since
DPCs from other drivers get queued in the same queue, your DPC might be
delayed until these DPCs are done.

    Stephan

----- Original Message ----- 
From: "Uwe Kirst" <u.kirst@xxxxxx>
To: <wdmaudiodev@xxxxxxxxxxxxx>
Sent: Tuesday, September 09, 2003 1:50 PM
Subject: [wdmaudiodev] Re: firewire audio at low latency


> Hi,
> We gave the preference to firewire, because we thought that it would be
possible
> to attain low latencies. Form usb everyone knows that the minimum latency
is
> about 1ms because of the usb frames. The firewire ohci controller does not
have
> such a limitiation. Please notice that a buffers setting of 50 samples is
not
> the whole latency of the system. To attain 50 sample latency the buffer
setting
> must be << 50. To calculate the latency we found that you must add at
least 2
> buffers (the buffer that is actually tranfered on the bus + another buffer
for
> security reasons, to be able to detect a missing interrupt). For a PCI
card this
> huge latency would be not exceptable.
>
> I still wonder if there is a technical reason why the isoch listen
callbacks are
> not spaced equidistantly @50 sample. I think hardware interrupts should
not be
> delayed for about 1.1ms (The system is doing nothing else than processing
the
> firewire interrupts). This really a long time in that context.
> The spuriouse callback is not delayed compared to the other callbacks but
is
> coming to early. The buffer is not finished yet, but I'm getting a
callback.
> Thats why the recorded data is corrupt.
>
> Uwe
>
> Evert van der Poll schrieb:
>
> > Hi,
> >
> > I'm no expert on drivers for audio devices but I work with them. I would
say
> > that a latency of 200 samples is not great but it's a decent score. The
> > minimum latency that can be attained depends on your system setup as
well as
> > on the driver code. There are some Windows settings that can be tweaked
to
> > get better performance.
> >
> > For instance this link gives some tips for Windows 98 setup:
> > http://www.rme-audio.com/english/techinfo/lola.htm
> >
> > There are others but it all depend on your OS.
> > My own soundcard offers me a minimum latency of 128 samples which is
> > perfectly workable for anything I want to do with it.
> > There are soundcards around that offer even smaller buffersizes like 64
> > samples. Yet I think that 50 samples is a pretty ambitious goal and I'm
not
> > sure if that is at all within reach for a firewire device. Is it really
> > necessary to have these low latencies?
> >
> > Evert
> >
> > -----Original Message-----
> > From: wdmaudiodev-bounce@xxxxxxxxxxxxx
> > [mailto:wdmaudiodev-bounce@xxxxxxxxxxxxx]On Behalf Of Uwe Kirst
> > Sent: Monday, September 08, 2003 5:04 PM
> > To: wdmaudiodev@xxxxxxxxxxxxx
> > Subject: [wdmaudiodev] firewire audio at low latency
> >
> > Hello,
> > I'm having some trouble getting low latencies with our firewire
> > minidriver. It comunicates directly with the 1394 stack by attaching
> > buffers of the same size using stream based dma.
> >
> > i) attaching 200 or more samples / buffer @44100kHz works fine.
> > ii) attaching 100 samples / buffer:
> > The isoch listen callbacks are not spaced equidistantly any more. From
> > time to time two callbacks are coming at the same time. In that case one
> >
> > of the next listen callbacks is missing. The avarage number of listen
> > callbacks seem to be still ok.
> > iii) attach 50 samples / buffer:
> > sometimes, depending on the cpu load, an isoch talk callback is missing.
> >
> > I'm wondering if someone has similar experince or can explain how they
> > are working around this issue.
> > Thanks in advance!
> > Uwe
> >
> > ******************
> >
> > WDMAUDIODEV addresses:
> > Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
> > Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
> > Unsubscribe:
mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
> > Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx
> >
> > URL to WDMAUDIODEV page:
> > http://www.wdmaudiodev.de/
> >
> > ******************
> >
> > WDMAUDIODEV addresses:
> > Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
> > Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
> > Unsubscribe:
mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
> > Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx
> >
> > URL to WDMAUDIODEV page:
> > http://www.wdmaudiodev.de/
>
> ******************
>
> WDMAUDIODEV addresses:
> Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
> Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
> Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
> Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx
>
> URL to WDMAUDIODEV page:
> http://www.wdmaudiodev.de/
>

******************

WDMAUDIODEV addresses:
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx

URL to WDMAUDIODEV page:
http://www.wdmaudiodev.de/

Other related posts: