Example 7−2. Initialization Code for Data Logging With End Address
; Base addresses
ADMA
.set
DEVT
.set
; Offsets
DMA_ADDRL .set
DMA_ADDRH .set
DMA_CNTRL .set
DMA_ID
.set
MASKL
.set
MASKH
.set
REFL
.set
REFH
.set
EVT_CNTRL .set
EVT_ID
.set
EALLOW
MOV
AR5, #DEVT
MOV
AR4, #ADMA
MOV
*+AR5[#EVT_CNTRL],#1
MOV
*+AR4[#DMA_CNTRL],#1
NOP
NOP
NOP
CMP
*+AR5[#EVT_ID],#5002h
B
FAIL, NEQ
CMP
*+AR4[#DMA_ID],#7001h
B
FAIL, NEQ
MOV
*+AR5[#MASKL],#0
MOV
*+AR5[#MASKH],#0
MOV
*+AR5[#REFL],#02FFh
MOV
*+AR5[#REFH],#0
MOV
*+AR5[#EVT_CNTRL],#
MOV
*+AR4[#DMA_ADDRL],#0100h
MOV
*+AR4[DMA_ADDRH],#0
MOV
*+AR4[DMA_CNTRL],#3066h
EDIS
0838h
0848h
0
1
6
7
0
1
2
3
6
7
; AR5 pointing to End Address registers
; AR4 pointing to Start/Control base
; Attempt to claim End Address
; Attempt to claim Start/Control
; Value expected in ID register
; If we don't see the correct ID, FAIL
; Value expected in ID register
; If we don't see the correct ID, FAIL
; Attempt to claim End Address
; Attempt to claim End Address
; Stop data logging at address 0x02FF
; Attempt to claim End Addr
( 2 |
(1<<2)
; Set buffer start address and then the count
|
(1<<12)
|
(1<<13)
Emulation Features
Data Logging
)
7-29
Need help?
Do you have a question about the TMS320C28x and is the answer not in the manual?