Sei sulla pagina 1di 14

ECE 450:DIGITAL SIGNAL

PROCESSORS AND APPLICATIONS

Lecture 17
Addressing Modes of TMS320c54x

Amrita School of Engineering, Bangalore

Last Session

MAC unit
ALU
Barrel Shifter
CSSU
Exponent encoder

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Todays Session
Addressing Modes

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Data Addressing Modes


Provide various ways to access operands to
execute instructions and place results in the
memory or the registers.
C54x has 7 addressing modes

24/ 02/ 14

Immediate Addressing
Absolute Addressing
Accumulator Addressing
Direct Addressing
Indirect Addressing
Memory-Mapped Register Addressing
Stack Addressing
Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Immediate addressing
Value encoded in the instruction.
Two types of values:
Short immediate (3/5/8/9 bits)
Long immediate (16 bits)
# indicates immediate.

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Example

24/ 02/ 14

LD

#5, ARP ; 3-bit constant

LD

#143h, DP ; 9-bit constant

LD

#80h, A

LD

#1000h, A ; 16-bit constant

; 8-bit constant

Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Absolute Addressing
Complete address is specified
Address is always of 16-bits
So, instruction is of 2 words
4 types:
dmad addressing
pmad addressing
PA addressing
*(lk) addressing
24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Example
MVKD SAMPLE, *AR5 ;dmad addr
MVDK *AR3, DATA1 ; dmad addr
MVPD COEFF, *AR7 ; pmad addr
PORTR FIFO, *AR5 ; PA addr
LD

24/ 02/ 14

*(BUFFER), A; *(lk) addr

Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Accumulator Addressing
Use Acc (A/B) contents as address.
Used to address program memory as data.
Two instructions:
READA Smem
WRITA Smem

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

Amrita School of Engineering, Bangalore

Direct Addressing
Lower 7-bit dma is an address offset
CPL in ST1 used for selection.
Types:
DP-Referenced Direct addressing
Can access upto 128 locations (7 bits) of 512 pages(9 bits
of DP) in DMA

SP-Referenced Direct addressing

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

10

Amrita School of Engineering, Bangalore


24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

11

Amrita School of Engineering, Bangalore

Next Session
Addressing Modes Cont..

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

12

Amrita School of Engineering, Bangalore

Thank You

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

13

Amrita School of Engineering, Bangalore

Thank You

24/ 02/ 14

Dr.Shikha Tripathi,ASE, Bangalore

14

Potrebbero piacerti anche