|
slPCMOn is double-buffered from work RAM to sound RAM.
This will always have delays in it because slPCMOn does not force the transfers (and thus, the bitrate) to be aligned with vblank. It does that so you can play any bitrate.
To set up a PCM stream with my driver, you have to manually schedule the transfers to the front buffer according to the playback time __precisely__ on a vblank period. There is no fixed "front buffer", in that case I am specifically referring to the sound RAM address that a PCM slot is working from.
Alternatively, using my driver, you place the entire sound data in sound RAM and schedule cascading playback over the entire chunk of data over multiple PCM slots.
e.g. you set up 7 PCM slots, each 64KB from each other, the second to play exactly after the first one is over, the third after the second, et cetera.
Again, has to be time __exactly__ over a vblank period (so your bytes per blank must be an even divisor of your buffer length -- 256, 512, 1024, 2048, 4096,). But this'll only work for 448KB of data. |