Appendix Programming Information
1250
40.3 Index Registers
Like other registers, index registers are used to read and write 16-bit data. There are seven 16-bit registers (IX,
IY, IZ to ID). Use index registers to indirectly specify a memory area number. Changing an address using an
index register value is called “index modification”.
In FPWIN Pro the user has only access to IX, IY. Indexes IZ through ID are used by the system for array
calculation, for fb indexing, or special implementations of certain FP instructions. (see note)
Possible index modifications include:
Memory areas in addition to data registers (DT).
An index register cannot modify another index register.
In FPWIN Pro, an index register cannot modify a constant value.
Example
Modifying a memory area address.
Address = Base address + value in IX, IY, IZ through ID
Modifying DT11
IXDT11
11
11
11
+
+
+
DT11
DT21
DT1
0
10
-10
=
=
=
Base address
Target addressIX value
When the index register is used as an address modifier, be sure to check that the shifted address does not
exceed its last address. If the shifted address exceeds its last address, an operation error occurs.
When a 32-bit constant is modified, the specified register number and the following register number are used in
combination to handle the data as a 32-bit data. (When modifying a 32-bit constant, do not specify ID.)
It is strongly suggested that you use arrays instead of using index registers to
modify memory areas because a conflict could arise from the user and system using
the same index register. For more detailed information on using index registers, see
“Programmable Controller FP10SH Programming” Manual (ACG-M0081-1).