AN1836-AN21161 Analog Devices, AN1836-AN21161 Datasheet - Page 39

no-image

AN1836-AN21161

Manufacturer Part Number
AN1836-AN21161
Description
Interfacing the ADSP-21161 SIMD SHARC DSP to the AD1836 (24-bit/96 kHz) Multichannel Codec
Manufacturer
Analog Devices
Datasheet
Notice that the AD1836 reference driver code copies all incoming data from the SPORT receive DMA buffer into temporary
DSP memory locations, or variables. Once audio data is processed by the ADSP-21161, the results are copied into temporary
output variables in DSP memory memory, where it will be read by the SPORT0 interrupt service routine and copied into the
output transmit DMA buffer. Notice that all Analog Devices supplied EZ-KIT assembly and C demos use the same standard
names for input and output audio variables. The following Table 11 shows the definitions for these variables in both assembly
and C and how they are related to the DMA transmit and receive buffer offsets:
Timeslot # SPORT DMA Buffer Timeslot Data
0
1
2
3
4
5
6
7
0
1
2
3
4
5
6
7
Assembly Variable Declarations
.segment /dm
/* AD1836 stereo-channel data holders - used for DSP processing of audio data received from codec */
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.VAR
.endseg;
Left_Channel_In0;
Left_Channel_In1;
Right_Channel_In0;
Right_Channel_In1;
Left_Channel_SPDIF_rx;
Right_Channel_SPDIF_rx;
Left_Channel_Out0;
Left_Channel_Out1;
Left_Channel_Out2;
Right_Channel_Out0;
Right_Channel_Out1;
Right_Channel_Out2;
Left_Channel_AD1852;
Right_Channel_AD1852;
Left_Channel;
Right_Channel;
TABLE11. DMA Buffer relationship to Data Memory Audio Variables
DM(rx_buf0a + Internal_ADC_L0)
DM(rx_buf0a + Internal_ADC_L1)
DM(rx_buf0a + AUX_ADC_L0)
DM(rx_buf0a + AUX_ADC_L1)
DM(rx_buf0a + Internal_ADC_R0)
DM(rx_buf0a + Internal_ADC_R1)
DM(rx_buf0a + AUX_ADC_R0)
DM(rx_buf0a + AUX_ADC_R0)
DM(tx_buf2a + Internal_DAC_L0)
DM(tx_buf2a + Internal_DAC_L1)
DM(tx_buf2a + Internal_DAC_L2)
DM(tx_buf2a + AUX_DAC_L0)
DM(tx_buf2a + Internal_DAC_R0)
DM(tx_buf2a + Internal_DAC_R1)
DM(tx_buf2a + Internal_DAC_R2)
DM(tx_buf2a + AUX_DAC_R0)
dm_codec;
/* Input values from AD1836 ADCs */
/* Output values for AD1836 DACs */
/* can use for intermediate results to next filter stage */
/* can use for intermediate results to next filter stage */
=
DM(Left_Channel_In0)
DM(Left_Channel_In1)
DM(Left_Channel_SPDIF_rx)
X (not used in EZ-KIT Lite)
DM(Right_Channel_In0)
DM(Right_Channel_In1)
DM(Left_Channel_SPDIF_rx)
X (not used in EZ-KIT Lite)
DM(Left_Channel_Out0)
DM(Left_Channel_Out1)
DM(Left_Channel_Out2)
DM(Left_Channel_AD1852)
DM(Right_Channel_Out0)
DM(Right_Channel_Out1)
DM(Right_Channel_Out2)
DM(Right_Channel_AD1852)
Temp Audio Variable Equivalent

Related parts for AN1836-AN21161