The tcDspDac8532McBsp class may be used to provide access to the MityDSP McBSP interface to the DAC8532 dual channel 16 bit digital to analog output device.
For hardware interfaces, the DAC8352 and McBSP should be connected as follows:
McBSP Port | DAC8352 Port | Notes |
---|---|---|
DX | DIN | External 2K Pulldown Resistor recommended |
DR | No Connect | |
CLKX | SCLK | |
CLKR | No Connect | |
FSX | SYNC | |
FSR | No Connect |
This is a simple example of tcDspDac8532McBsp creation and usage:
{ tcDspDac8532McBsp* mpDAC; unsigned short sample1, sample2; SEM_Handle Sem = SEM_create(0,NULL); // new up the 834x core. mpDAC = new tcDspDac8532McBsp(MCBSP_DEV0); mpDAC->SetSamples(SampleA, SampleB, Sem); // output samples as ramp, continuously, forever while(true) { sample1++; sample2++; SEM_pend(Sem, SYS_FOREVER); mpDAC->SetSamples(SampleA, SampleB, Sem); } }