Standard
RLL
Instructions
5--70
Standard RLL Instructions
Bit Operation Instructions
DL105 PLC User Manual, 3rd Edition
DECO
The Decode instruction decodes a 5 bit
binary value of 0--31 (0--1F HEX) in the
accumulator by setting the appropriate bit
position to a 1. If the accumulator contains
the value F (HEX), bit 15 will be set in the
accumulator. If the value to be decoded is
greater than 31, the number is divided by
32 until the value is less than 32 and then
the value is decoded.
In the following example when X1 is on, the value formed by discrete locations
X10--X14 is loaded into the accumulator using the Load Formatted instruction. The
five bit binary pattern in the accumulator is decoded by setting the corresponding bit
position to a “1” using the Decode instruction.
Handheld Programmer Keystrokes
Direct
SOFT
LDF
X10
K5
X1
Load the value in
represented by discrete
locations X10--X14 into the
accumulator
DECO
Decode the five bit binary
pattern in the accumulator
and set the corresponding
bit position to a “1”
X10
X11
X12
X13
ON
ON
OFF
ON
X14
OFF
0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 1
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
Acc.
0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
Acc.
The binary vlaue
is converted to
bit position 11.
STR
$
ENT
SHFT
ANDST
L
3
D
5
F
1
B
1
B
0
A
ENT
5
F
SHFT
2
C
INST#
O
ENT
3
D
4
E
Decode
(DECO)
Summary of Contents for DL105
Page 2: ...DL105 PLC User Manual Manual Number D1 USER M...
Page 308: ...1B DL105 Error Codes In This Appendix Error Code Table...
Page 314: ...1C Instruction Execution Times In This Appendix Introduction Instruction Execution Times...
Page 324: ...1D Special Relays In This Appendix DL105 PLC Special Relays...
Page 327: ...1E PLC Memory In This Appendix DL105 PLC Memory...