S3C84E5/C84E9/P84E9

ADDRESSING MODES

 

 

INDEXED ADDRESSING MODE (Continued)

 

 

 

Program Memory

 

 

 

 

 

 

 

 

OFFSET

4-bit Working

 

 

OFFSET

 

 

dst/src

src

Register Address

 

 

OPCODE

 

 

 

 

 

 

 

 

 

 

 

 

 

Sample Instructions:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Register File

 

MSB Points to

 

 

 

 

 

 

 

 

 

 

 

RP0 or RP1

 

 

 

 

 

 

RP0 or RP1

 

 

Selected

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

RP points

~

~

to start of

working

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

register

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

block

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

NEXT 2 Bits

Point to Working

Register

 

Pair

 

 

Register Pair

 

16-Bit

 

 

 

 

 

 

address

 

 

Program Memory

added to

LSB Selects

offset

or

 

 

+

Data Memory

 

 

 

 

16-Bits

16-Bits

 

 

 

16-Bits

OPERAND

Value used in

 

Instruction

 

 

LDC

R4, #1000H[RR2]

;

The values in the program address (RR2 + 1000H

 

 

 

are loaded into register R4.

LDE

R4,#1000H[RR2]

;

Identical operation to LDC example, except that

 

 

 

external program memory is accessed.

Figure 3-9. Indexed Addressing to Program or Data Memory

3-9

Page 64
Image 64
Samsung S3C84E5 user manual Indexed Addressing to Program or Data Memory