Professional Documents
Culture Documents
Programmable Logic Controllers: Frank D. Petruzella
Programmable Logic Controllers: Frank D. Petruzella
Logic Controllers
Third Edition
Frank D. Petruzella
McGraw-Hill
Chapter 4
Fundamentals
of Logic
Binary
Signal
Light Switch
High Beam Switch
AND
Gate
High Beam
Light
OR
Gate
Dome
Light
AND Function
OR Function
NOT Function
The NOT function has only one input and one output.
The NOT output is 1 if the input is 0.
The NOT output is 0 if the input is 1.
Since the output is always the reverse of the input
it is called an inverter.
NAND Function
NOR Function
c. data
b. output status
d. truth
Gate
A
B
A
B
AND
Y= AB
OR
Y= A+ B
NOT
Y=A
AB
Y = AB + C
A+ B
Y = (A + B) C
A+ B
Y = (A + B) C
Logic equation: Y = AB + AB
Ladder rail
Ladder rung
Control scheme is drawn
between two vertical
supply lines.
Programmed OR Instruction
There is a 1 at
B3:20 when
either or both
the Source
A or B bits are 1
(c)
(b)
(d)
a. Y = A B C D
b. Y = ( AB ) + ( CD )
c. Y = ( A + B ) ( C + D )
d. Y = ( AB ) + ( CD )
a. Y = ( A + B + C ) D
c. Y = ( AB + C ) D
b. Y = ( A + B ) ( C + D )
d. Y = ( ABC ) D
a. Y = A B C
c. Y = A + B + C
b. Y = ( A B ) C
d. Y = ( AB ) + ( BC )
a. Y = (A B) + (CD)
c. Y = A + B + C + D
b. Y = (A+B ) (C+D)
d. Y = ABCD
a. Y = (A B) + (CD)
c. Y = A + B + C + D
b. Y = AB (C+D)
d. Y = ABC + D
c. XOR
b. OR
d. NOT
c. XOR
b. OR
d. NOT