EE203 02 Logic Gates
EE203 02 Logic Gates
EE203 02 Logic Gates
2. Logic Gates
Inverter
AND
OR
NAND AB
NOR A B
X A B AB A B
XOR
EE203 Digital Design 2
Inverter
Input Output
Inversion
Inversion, complementation
Not circuit
Changes 1 to 0 and 0 to 1.
Two-input
AND gate
Application example
Masking. E.g. Clear right four bits.
Mask: 11110000
Input: 10100101
‘Mask’ (bitwise) AND ‘Input’ 10100000
1
1
1
1
Two-input 1
OR gate 1
Application example
Masking. E.g. Setting right four bits.
Mask: 00001111
Input: 10100101
‘Mask’ (bitwise) OR ‘Input’ 10101111
When one of the windows or the door is opened, it then activates and
latches an alarm circuit to warn of the intrusion.
1
1
1
Two-input 1
NAND gate 1
1
1
0
00 1 0 0 1
0 1 1 0 1 1
1 0 1 1 0 1
1 1 0 11 0
A B
1
0
0
Two-input 0
0
NOR gate
0
0
0
EE203 Digital Design 20
Negative-AND is equal to NOR
0 0 1 00 1
0 1 0 01 0
1 0 0 10 0
11 0 11 0
X A B AB A B
X A B AB A B
A = f(O, B, S)
L = f(A, B, C)
ANY QUESTIONS?