2. Programming Concepts

2.14 E, F Index Registers

Index registers are used as modifiers to indicate a specified device (word, double word) by defining an offset. Devices can be modified includes byte device (KnX, KnY, KnM, KnS, T, C, D) and bit device (X, Y, M, S). E, F registers cannot be used for modifying constant (K, H) Index registers not used as a modifier can be used as general purpose register.

Index register [E], [F]

Index registers are 16-bit registers which can be read and written. There are 16 points indicated as E0~E7 and F0~F7. If you need a 32-bit register, you have to designate E. In this case, F will be covered up by E and cannot be used. It is recommended to use instruction DMOVP K0 E to reset E (including F) at power-on.

16-bit

 

 

16-bit

F0

 

 

E0

 

32-bit

F0

E0

High word Low word

The combinations of E and F when designating a 32-bit register are:

(E0, F0) , (E1, F1) (E2, F2) (E3, F3) (E4, F4) , (E5, F5) (E6, F6) (E7, F7)

Example:

When X0 = ON and E0 = 8, F0 = 14, D5E0 = D(5+8) = D13, D10F0 = D(10+14) = D24, the content in D13 will be moved to D24.

X0

MOV K8 E0

MOV K14 F0

MOV D5E0 D10F0

2.15 Nest Level Pointer[N], Pointer[P], Interrupt Pointer [I]

 

N

Master control nested

N0~N7, 8 points

The control point of

 

master control nested

 

 

 

 

Pointer

 

 

 

 

P

For CJ, CALL instructions

P0~P255, 256 points

The location point of CJ,

 

 

CALL

 

 

 

 

 

 

 

 

 

2 - 5 1

Page 83
Image 83
Delta DVP-ES2/EX2/SS2/SA2/SX2/SE manual 14 E, F Index Registers, Nest Level PointerN, PointerP, Interrupt Pointer, Call