EasyManuals Logo
Home>Allen-Bradley>Controller>PLC-5

Allen-Bradley PLC-5 User Manual

Allen-Bradley PLC-5
388 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #314 background imageLoading...
Page #314 background image
Publication 1785-UM012D-EN-P - July 2005
D-14 Instruction Set Quick Reference
Logical Instructions
Instruction Description
AND
NOT Operation
OR
Exclusive OR
XOR
AND
BITWISE AND
Source A
Source B
Dest
D9:3
D9:4
D9:5
3F37
00FF
0037
When the input conditions are true, the controller performs a
n
AND operation (bit-by-bit) between Source A (D9:3) and Sour
c
B (D9:4) and stores the result in the Destination (D9:5). The
truth table for an AND operation is:
Source ASource BResult
000
100
010
111
NOT
NOT
Source A
Dest
D9:3
D9:5
00FF
FF00
Wh
en t
h
e
i
nput con
di
t
i
ons are true, t
h
e contro
ll
er per
f
orms a
NOT (takes the opposite of) operation (bit-by-bit) on the Sourc
(D9:3) and stores the result in the Destination (D9:5). The trut
table for a NOT operation is:
SourceDestination
01
10
OR
BITWISE INCLUSIVE OR
Source A
Source B
Dest
D9:3
D9:4
D9:5
3F37
00FF
3FFF
When the input conditions are true, the controller performs a
n
OR operation (bit-by-bit) between Source A (D9:3) and Source
(D9:4) and stores the result in the Destination (D9:5). The trut
table for an OR operation is:
Source ASource BResult
000
101
011
111
XOR
BITWISE EXCLUSIVE OR
Source A
Source B
Dest
D9:4
D9:5
3F37
3F37
0000
D9:3
When the input conditions are true, the controller performs a
n
exclusive OR operation (bit-by-bit) between Source A (D9:3) a
n
Source B (D9:4) and stores the result in the Destination (D9:5)
The truth table for an XOR operation is:
Source ASource BResult
000
101
011
110
Status
Bit
Descriptio
C
V
Z
S
always
always
sets if the result is zero; otherwise
sets if the most significant bit (bit 15 for decimal or bit 17 for
octal) is set (1); otherwise resets

Table of Contents

Other manuals for Allen-Bradley PLC-5

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Allen-Bradley PLC-5 and is the answer not in the manual?

Allen-Bradley PLC-5 Specifications

General IconGeneral
BrandAllen-Bradley
ModelPLC-5
CategoryController
LanguageEnglish

Related product manuals