DL06 Micro PLC User Manual, 3rd Edition, Rev. E
5-149
Chapter 5: Standard RLL Instructions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
A
B
C
D
NOTE: Status flags are only valid until another instruction that uses the same flags is executed. The
pointer for this instruction starts at 0 and resides in the accumulator.
In the following example, when X1 is on, the constant value (K6) is loaded into the accumulator
using the Load instruction. This value specifies the length of the table and is placed in the first
stack location after the Load Address instruction is executed. The octal address 1400 (V1400)
is the starting location for the table and is loaded into the accumulator. The Greater Than
search value is specified in the Find Greater Than instruction. If a value is found greater than
the search value, the offset (from the starting location of the table) where the value is located
will reside in the accumulator. If there is no value in the table that is greater than the search
value, a zero is stored in the accumulator and SP53 will come ON.
Handheld Programmer Keystrokes
S T R
X(IN)
1
LD
K(C ON)
6
LD
S HF T
A
OC T
1
4
0
0
S HF T
F
D
G
T
S HF T
K(C ON)
8
9
8
9
Direct
S OF T 32 Display
LD
K6
X1
Load the constant value 6
(HE X) into the lower 16 bits
of the accumulator
LDA
O 1400
C onvert octal 1400 to HE X
300 and load the value into
the accumulator.
F DGT
K8989
F ind the value in the table
greater than the specified value
V1400
0
1
2
3
V1401
0
5
0
0
V1402
9
9
9
9
V1403
3
0
7
4
V1404
8
9
8
9
V1405
1
0
1
0
V1406
X
X
X
X
V1407
X
X
X
X
S
S
S
S
Table length
0
0
0
2
Accumulator
V1402 contains the location
where the first value greater
than the search value was
found. 9999 was the 2nd
location after the start of the
specified table.
0
0
0
0
Begin here
0
1
2
3
4
5
Handheld Programmer Keystrokes
STR
$
SHFT
ANDST
L
3
D
SHFT
5
F
3
D
6
G
PREV
MLR
T
1
B
ENT
6
G
0
A
0
A
ENT
SHFT
ANDST
L
3
D
1
B
4
E
0
A
ENT
8
I
9
J
ENT
NEXT
8
I
9
J
Operand Data Type
DL06 Range
A
aaa
V-memory
V
See memory map
Constant
K
0–FF
Discrete Bit Flags
Description
SP53
On if there is no value in the table that is equal to the search value.
Direct
SOFT