Toshiba 6F3B0250 Video Gaming Accessories User Manual


 
6F3B0250
104
T1/T1S User’s Manual
6. Programming Information
6.2 Index modification
When registers are used as operands of instructions, the method of directly designating
the register address as shown in Example 1) below is called ‘direct addressing’.
As opposed to this, the method of indirectly designating the register by combination with
the contents of the index register (I, J, or K) as shown in Example 2) below is called
‘indirect addressing’. In particular, in this case, since the address is modified using an
index register, this is called ‘index modification’.
Example 1)
¾
[ RW10 MOV D1000 ]
¾
Data transfer instruction
Transfer data of RW10 to D1000
Example 2)
I J
¾
[ RW10 MOV D0000 ]
¾
Data transfer instruction (with index modification)
Transfer data of RW(10 + I) to D(0000 + J)
(If I = 3 and J = 200, the data of RW13 is transferred to D0200)
There are 3 types of index register, I, J and K. Each type processes 16-bit integers
(-32768 to 32767). There are no particular differences in function between these 3 types
of index register.
There is no special instruction for substituting values in these index registers. These are
designated as destination of data transfer instructions, etc.
¾
[ 00064 MOV I ]
¾
(substitutes 64 in index register I)
¾
[ D0035 MOV J ]
¾
(substitutes the data of D0035 in index register J)
¾
[ RW20 + 00030
®
K ]
¾
(substitutes the result of addition in index register K)
NOTE
(1) The index modification is available for RW, T, C and D registers.
(2) If index registers are used as a double-length register, only the
combinations J
×
I and K
×
J are allowed.
CTi Automation - Phone: 800.894.0412 - Fax: 208.368.0415 - Web: www.ctiautomation.net - Email: info@ctiautomation.net