Hi Kevin,
Thanks for the clear info. Here's a follow-up after extensive driver testing on macOS (M1 Max, macOS 27.2).
In normal operation, my 1 ms OUT requests are submitted 13–16 ms ahead of the controller. In the two incidents I've captured in detail, the next audio had already been published about 14 ms early, but the dispatch queue that submits requests wasn't serviced for roughly 8–10 ms (inferred from event timing), and the next request then missed its frame.
For reference, the vendor's own macOS driver on the same Mac (a Core Audio HAL plug-in that uses IOUSBHost, as I mentioned in the other thread) shows 4.58 ms round trip at a 32-frame buffer, 5.92 ms at 64 frames, and 8.58 ms at 128 frames (as reported by the DAW, not verified as true RTL, but certainly in the ballpark), so the hardware isn't the limit.
That leaves me with three questions I haven't been able to resolve through testing and research:
You mentioned the audio system typically writes 2–4 ms ahead of the bus; stalls of 8–10 ms are well beyond that. What determines how long a DriverKit dispatch queue can go unscheduled, and is there a supported way to bound it (for example, a QoS or priority setting)?
Should I expect the same dispatch and scheduling behaviour on iPadOS as on macOS? The iPad Pro (M1) is the eventual product target.
A request whose first USB frame is only 1 frame ahead of the frame number I read from the OUT interface with GetFrameNumber just before submitting is rejected as IsoTooOld, while 2 frames ahead has been accepted. Is there a documented minimum lead for IsochIO, and is GetFrameNumber the right current-frame source to compare against (as opposed to CurrentMicroframe)?
I can share the recorder exports if that would help.
Thanks again,
Luke
Topic:
App & System Services
SubTopic:
Drivers
Tags: