579
Table Data Processing Instructions Section 3-16
Operand Specifications
Description DIM(631) registers the words from TB to TB+LR
×NR–1 as table number N.
Table number N has NR records and each record is LR words long. The data
within this region cannot be changed once the region has been declared as
records.
Use DIM(631) in combination with SETR(635) (SET RECORD NUMBER) or
GETR(636) (GET RECORD NUMBER) to simplify the calculation of
addresses in data tables. Use DIM(631) to divide data into records and then
use SETR(635) to store the first address of the desired record in an Index
Register. The Index Register can then be used as a pointer in other instruc-
tions, such as read, write, search, or compare instructions.
As an example, if temperatures, pressures, or other set values are stored as
records and the records for various models are combined into a table, it is
easy to read the set values for each models for any particular conditions.
The two record-table instructions associated with DIM(631) are SETR(635)
and GETR(636). SETR(635) sets the leading PLC memory address of the
specified record number in the specified Index Register. GETR(636) outputs
the record number of the record that includes the specified Index Register
value (PLC memory address).
Area NLRNRTB
CIO Area --- CIO 0 to CIO 6143
Work Area --- W0 to W511
Holding Bit Area --- H0 to H511
Auxiliary Bit Area --- A0 to A959 A448 to A959
Timer Area --- T0000 to T4095
Counter Area --- C0000 to C4095
DM Area --- D0 to D32767
Indirect DM addresses
in binary
--- @ D0 to @ D32767
Indirect DM addresses
in BCD
--- *D0 to *D32767
Constants 0 to 15 #0001 to #FFFF (binary) or &1
to &65,535
---
Data Registers --- DR0 to DR15 ---
Index Registers --- ---
Indirect addressing
using Index Registers
--- ,IR0 to ,IR15
–2048 to +2047 ,IR0 to –2048 to +2047 ,IR15
DR0 to DR15, IR0 to IR15 ,IR0+(++) to
,IR15+(++)
,–(– –)IR0 to, –(– –)IR15
Number of records
Table number (N)
Record 0
Record 1
Record NR–1
LR
× NR words