2. Logic Gates
Goal:
To understand how digital a computer can work, at the
lowest level.
To understand what is possible and the limitations of what is
possible for a digital computer.
3. Logic Gates
All digital computers for the past 50 years have
been constructed using the same type of
components.
These components are called logic gates.
Logic gates have been implemented in many
different ways.
Currently, logic gates are most commonly
implemented using electronic VLSI transistor
logic.
4. Logic Gates
All basic logic gates have the ability to accept either one or two input
signals (depending upon the type of gate) and generate one output
signal.
5. Logic Gates
Input and Output signals are binary.
binary:
always in one of two possible states;
typically treated as:
On / Off (electrically)
1 / 0
True / False
The True or False view is most useful for
thinking about the meaning of the basic
logic gates.
6. Logic Gates
The six basic logic gates are:
AND
OR
XOR
NOT
NAND
NOR
Each of these gates may be drawn in either
A generic form; or
An electrical engineering form (more common in text books)
7. Logic Gates : AND
The Output signal from an AND gate is True (on, 1)
if and only if both Input signals are True (on, 1).
The Output signal from an AND gate is False (off,
0), otherwise.
8. Logic Gates : OR
The Output signal from an OR gate is True (on, 1) if
either, or both, Input signals are True (on, 1).
The Output signal from an OR gate is False (off, 0) if and
only if both Input signals are False (off, 0).
9. Logic Gates : XOR
The Output from an XOR (exclusive or) is True
(on, 1) if and only if the Input signals are
different.
The Output from an XOR is False if the Input
signals are either both True or both False.
10. Logic Gates : NOT
The Output signal from a NOT gate is True (on, 1)
if and only if the Input signal is False.
The Output signal from a NOT gate is False (off,
0) if and only if the Input signal is True.
11. Logic Gates : NOT combined with other
gates
Note that in the “classic: electronic
engineering form, it is really the “bubble” that
indicates the NOT activity.
12. Logic Gates : Summary
Truth Tables
0 = False = off
1 = True = on
A B
A B
A B A
AND GATE
OR GATE
X-OR GATE
NOT GATE
13. Logic Gates : Summary
Truth Tables
0 = False = off
1 = True = on
NAND GATE
NOR GATE