★ PROGRAMMER'S GUIDE ★ PCM / ADPCM playback libraryItem | specification | remarks |
|---|---|---|
Sampling frequency | Up to 44.1kHz | |
Number of quantization bits | 8bit, 16bit | |
Number of channels | Monaural, stereo | |
file format | AIFF format specification ADPCM format 1) | PCM uncompressed ADPCM compression ADPCM compression PCM uncompressed |
CD-ROM format | For CD-ROM XA Audio format | |
Playback mode | Memory playback mode (play back data in memory) | Four) Use file system Use stream system |
function | Branch playback, continuous playback, loop playback 5) | Only one ADPCM |
Continuous playback time | Up to 1 hour | |
Library used | File system, stream system, DMA library, | Link these at the same time as this library 6) |
CPU timer | This library uses the CPU timer (FRT) with a frequency division of 128. Initialize only once in the PCM_Init function. FRT initialization and settings on the user side are prohibited. | It is possible to get the value with TIM_FRT_GET_16 etc. |
Use of DMA | CPU-DMA (channel 1), or | 7) |
Sound driver | The user makes the initial settings (68000 reset, sound driver transfer, etc.) in advance. This library issues commands related to PCM playback (PCM start, stop, parameter change). All commands to the sound driver are issued using the sound I / F library. | See Sega Saturn Sound Driver 2.20 Programmer's Guide. |
Securing buffer | Work buffer: Work structure (approx. 530 bytes) | Fixed size |
CPU load | PCM uncompressed 44kHz stereo 16bit: 10% | This is the measured value of all processing time including decompression processing in the case of ADPCM, such as data transfer of CD → work memory → sound memory. |
PCM_Task (task function) specifications | · V blank interrupt frequency (once / 16ms) to call in equal or greater frequency. ・Maximum processing time of one task function PCM uncompressed stereo 16bit: 15ms PCM uncompressed monaural 16bit: 8ms ADPCM compression stereo 16bit: 34ms ADPCM compression monaural 16bit: 15ms | If you call it at a reasonable frequency, the processing time will be long once every few times. |
R = (100 × Ttask) / Tplay ┌ ┐ │ R: CPU load [%] │ │ Ttask: Total processing time of PCM_Task from the start of playback to the end of playback │ │ Tplay: Playback time │ └ ┘
★ PROGRAMMER'S GUIDE ★ PCM / ADPCM playback library