DSPIC30F2012 Microchip Technology Inc., DSPIC30F2012 Datasheet - Page 45

no-image

DSPIC30F2012

Manufacturer Part Number
DSPIC30F2012
Description
Dspic30f2011/2012/3012/3013 High-performance Digital Signal Controllers
Manufacturer
Microchip Technology Inc.
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
DSPIC30F2012-20E/ML
Manufacturer:
MICROCHIP/微芯
Quantity:
20 000
Part Number:
DSPIC30F2012-20E/SO
Manufacturer:
MICROCHIP/微芯
Quantity:
20 000
Part Number:
DSPIC30F2012-20I/ML
Manufacturer:
MICROCHIP/微芯
Quantity:
20 000
Part Number:
DSPIC30F2012-20I/SO
Manufacturer:
MICROCHI
Quantity:
20 000
Part Number:
DSPIC30F2012-20I/SO
0
Part Number:
DSPIC30F2012-20I/SP
Manufacturer:
Microchip Technology
Quantity:
135
Part Number:
DSPIC30F2012-20I/SP
Manufacturer:
MICROCHIP/微芯
Quantity:
20 000
4.2.1
The Modulo Addressing scheme requires that a start-
ing and an ending address be specified and loaded
into the 16-bit
XMODSRT, XMODEND, YMODSRT and YMODEND
(see Table 3-3).
The length of a circular buffer is not directly specified. It
is determined by the difference between the corre-
sponding Start and end addresses. The maximum pos-
sible length of the circular buffer is 32K words
(64 Kbytes).
FIGURE 4-1:
© 2006 Microchip Technology Inc.
Note:
Byte
Address
0x1100
0x1163
START AND END ADDRESS
Y space Modulo Addressing EA calcula-
tions assume word-sized data (LSb of
every EA is always clear).
Start Addr = 0x1100
End Addr = 0x1163
Length = 0x0032 words
Modulo
MODULO ADDRESSING OPERATION EXAMPLE
Buffer
Address
dsPIC30F2011/2012/3012/3013
registers:
MOV
MOV
MOV
MOV
MOV
MOV
MOV
MOV
DO
MOV
AGAIN: INC
#0x1100,W0
W0,XMODSRT
#0x1163,W0
W0,MODEND
#0x8001,W0
W0,MODCON
#0x0000,W0
#0x1110,W1
AGAIN,#0x31
W0,[W1++]
W0,W0
4.2.2
The Modulo and Bit-Reversed Addressing Control reg-
ister, MODCON<15:0>, contains enable flags as well
as a W register field to specify the W address registers.
The XWM and YWM fields select which registers oper-
ate with Modulo Addressing. If XWM = 15, X RAGU
and X WAGU Modulo Addressing is disabled. Similarly,
if YWM = 15, Y AGU Modulo Addressing is disabled.
The X Address Space Pointer W register (XWM), to
which Modulo Addressing is to be applied, is stored in
MODCON<3:0> (see Table 3-3). Modulo Addressing is
enabled for X data space when XWM is set to any value
other than ‘15’ and the XMODEN bit is set at
MODCON<15>.
The Y Address Space Pointer W register (YWM), to
which Modulo Addressing is to be applied, is stored in
MODCON<7:4>. Modulo Addressing is enabled for Y
data space when YWM is set to any value other than
‘15’ and the YMODEN bit is set at MODCON<14>.
;set modulo start address
;set modulo end address
;enable W1, X AGU for modulo
;W0 holds buffer fill value
;point W1 to buffer
;fill the 50 buffer locations
;fill the next location
;increment the fill value
W ADDRESS REGISTER
SELECTION
DS70139E-page 43

Related parts for DSPIC30F2012