Autobuffering Enabled - Analog Devices adsp-2100 Manual

Adsp-2100 family programmable single-chip microprocessors
Table of Contents

Advertisement

{ ADSP-21msp58/59 Analog Interface Loopback Example
{
- configures analog interface
{
- copies ADC receive data to DAC transmit buffer}
.MODULE/ABS=0/BOOT=0
#define
codec_tx_data
#define
codec_rx_data
#define
codec_ctrl_reg 0x3FEE
resetv:
JUMP setup; NOP; NOP; NOP;
irq2v:
RTI; NOP; NOP; NOP;
hipwv:
RTI; NOP; NOP; NOP;
hiprv:
RTI; NOP; NOP; NOP;
spt0tv:
RTI; NOP; NOP; NOP;
spt0rv:
RTI; NOP; NOP; NOP;
antv:
RTI; NOP; NOP; NOP;
anrv:
SI = DM(codec_rx_data);
DM(codec_tx_data) = SI;
RTI; NOP;
irq1v:
RTI; NOP; NOP; NOP;
irq0v:
RTI; NOP; NOP; NOP;
timerv:
RTI; NOP; NOP; NOP;
pwrdwnv:
RTI; NOP; NOP; NOP;
setup:
AX1 = 0x0060;
DM(codec_ctrl_reg) = AX1;
IMASK = 0x8;
wait_loop:
IDLE;
JUMP wait_loop;
.ENDMOD;
Listing 8.1 ADSP-21msp58/59 Analog Loopback Program

8.4.3.2 Autobuffering Enabled

In some applications it is advantageous to perform block data transfers
between the analog converters and processor memory. Analog
interface autobuffering allows you to automatically transfer blocks of
data from the ADC to on-chip processor data memory or from on-chip
processor data memory to the DAC.
An interrupt is generated when an entire block transfer is complete (i.e.
when the data buffer is full or empty). Analog interface autobuffering
operates in the same way as SPORT autobuffering, described in
Chapter 5. Note that data can be autobuffered through the analog
converters or through SPORT0 of the ADSP-21msp58/59.
Autobuffering is not available on SPORT1 of the ADSP-21msp58/59.
Analog Interface
talkthru;
0x3FEC
0x3FED
}
}
{interrupt vectors ...}
{read in data from ADC}
{write out data to DAC}
{power up analog interface}
{enable analog receive interrupt}
{wait for interrupt}
8
8 – 13

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents