Creative SB0350 Hardware Programming Guide - Page 57
Creative SB0350 Manual
View all Creative SB0350 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 57 highlights
3-28 Digitized Sound I/O Programming 8-bit or 16-bit Auto-initialize Transfer The following are the steps needed to perform 8-bit or 16-bit and mono or stereo PCM auto-initialize DMA mode transfer on DSP version 4.xx: 1. Allocate a DMA buffer in contiguous memory without straddling a 64KB physical page boundary. Use an 8KB buffer as an example. Set up the DSP interrupt service routine. Enable the interrupt used. Program the DMA controller for 8-bit or 16-bit auto-initialize DMA mode transfer. Set the DSP transfer sampling rate. outp(wSBCBaseAddx+0xC, bCommand) outp(wSBCBaseAddx+0xC, wSamplingRate.HighByte) outp(wSBCBaseAddx+0xC, wSamplingRate.LowByte) 2. 3. 4. 5. bCommand is one of the following: bCommand 42h 41h Description Input Output Contrast the sampling rate with the DSP transfer Time Constant. For example, at a 44100 Hz sampling rate, wSamplingRate.HighByte = ACh, and wSamplingRate.LowByte = 44h. 6. Send an I/O command, followed by the transfer mode, and the DSP block transfer size. outp(wSBCBaseAddx+0xC, outp(wSBCBaseAddx+0xC, outp(wSBCBaseAddx+0xC, outp(wSBCBaseAddx+0xC, bCommand) bMode) wBlkSize.LowByte) wBlkSize.HighByte) bCommand is one of the following: bCommand CEh C6h BEh B6h Description 8-bit input 8-bit output 16-bit input 16-bit output