dsp56800e Freescale Semiconductor, Inc, dsp56800e Datasheet - Page 224

no-image

dsp56800e

Manufacturer Part Number
dsp56800e
Description
16-bit Digital Signal Controller Core
Manufacturer
Freescale Semiconductor, Inc
Datasheet
Address Generation Unit
Finally, when modulo arithmetic is used while accessing long-word values, any of the following
addressing modes can be used:
Be careful to configure the M01 register properly based on the type of data that is being accessed when
modulo arithmetic has been enabled. See Section 6.8.3, “Configuring Modulo Arithmetic,” for more
information.
6.8.5.3
The DSP56800E address generation unit also supports using modulo address arithmetic with some AGU
instructions. The supported instructions are the following:
For those supported AGU instructions that have more than one operand, modulo arithmetic will be used if
any of the source operands is a register for which modulo arithmetic has been enabled.
6.8.6
Suppose a five-location circular buffer is needed for an application. The application locates this buffer at
X:$800 in memory.
following two pieces of information are needed:
Modulo addressing is enabled for the R0 pointer through writing the size minus one ($0004) to M01[13:0]
and writing 00 to M01[15:14]. See Figure 6-9.
6-30
1. This location is arbitrary—any location in data memory would suffice.
The size of the buffer: 5 words
The location of the buffer: X:$0800–X:$0804
Simple Circular Buffer Example
(Rn)
(Rn)–
ADDA
DECA
TSTDECA.W
Modulo Addressing for AGU Arithmetic Instructions
Refer to Section 6.8.4.3, “Special Case - ADDA Instructions in Modulo
Arithmetic,” on page 6-28 for special considerations on the ADDA
instruction.
*
1
In order for the AGU to be configured correctly to manage this circular buffer, the
DSP56800E Core Reference Manual
(Rn+N)
(Rn+xxxx)
ADDA.L
DECA.L
NOTE:
(Rn)+
(Rn+xxxxxx)
SUBA
DECTSTA
Freescale Semiconductor

Related parts for dsp56800e