Digitized Sound I/O Programming
3-29
bMode
is one of the following:
bMode
Description
00h
8-bit mono unsigned PCM
20h
8-bit stereo unsigned PCM
10h
16-bit mono signed PCM
30h
16-bit stereo signed PCM
wBlkSize
is one less than the actual number of samples to be transferred.
If an 8KB DMA buffer is used, the DSP block transfer size should be set to
4K of 8-bit samples for 8-bit data transfer, or 2K of 16-bit samples for 16-
bit data transfer. At the end of every block transfer, the DSP will generate
an interrupt to the application.
Upon receiving an interrupt from the DSP, the following steps should be done in the
interrupt service routine:
1.
Transfer data between the DMA buffer and the storage buffer.
To stop auto-initialize DMA mode, you can either send the exit auto-initialize
DMA mode command or program the DSP for single-cycle DMA mode transfer.
2a.
Send the exit auto-initialize DMA mode command.
outp(wSBCB0xC, 0xDA)
for 8-bit transfer
outp(wSBCB0xC, 0xD9)
for 16-bit transfer
Upon receiving the exit auto-initialize DMA mode command, the DSP will
exit auto-initialize DMA mode immediately at the end of the current block
transfer.
2b.
Program the DSP for single-cycle DMA mode transfer.
outp(wSBCB0xC, bCommand)
outp(wSBCB0xC, bMode)
outp(wSBCB0xC, wBlkSize.LowByte)
outp(wSBCB0xC, wBlkSize.HighByte)
At the end of data transfer:
1
Disable the interrupt used.
2
Restore the original interrupt service routine.
3.
Release the allocated DMA buffer.
Содержание SB0350
Страница 29: ......
Страница 71: ...Mixer Chip Programming 4 13 Figure 4 4 Logical Schematic of the Output Mixing Paths ...
Страница 72: ...4 14 Mixer Chip Programming Figure 4 5 Logical Schematic of the Input Mixing Paths ...
Страница 141: ...Index3 ...