Top Banner
Digital Logic Circuits, Digital Component and Data Representation Course: BCA-2 nd Sem Subject: Computer Organization And Architecture Unit-1 1
32

Bca 2nd sem-u-1.6 digital logic circuits, digital component

Aug 07, 2015

Download

Education

RAI UNIVERSITY
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Digital Logic Circuits, Digital Component and Data

Representation

Course: BCA-2nd Sem Subject: Computer Organization

And Architecture Unit-1

1

Page 2: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Basic Logic Gates and Basic Digital Design[1]

• NOT, AND, and OR Gates

• NAND and NOR Gates

• DeMorgan’s Theorem

• Exclusive-OR (XOR) Gate

• Multiple-input Gates

Page 3: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NOT Gate -- Inverter

X Y

01

10

X Y

Y

NOTX Y

Y = ~X

NOT

Page 4: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NOT

• Y = ~X (Verilog)• Y = !X (ABEL)• Y = not X (VHDL)• Y = X’• Y = X• Y = X (textook)• not(Y,X) (Verilog)

Page 5: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NOT

X ~X ~~X = X

X ~X ~~X0 1 01 0 1

Page 6: Bca 2nd sem-u-1.6 digital logic circuits, digital component

AND Gate

AND

X

Y

Z

Z = X & Y

X Y Z0 0 00 1 01 0 01 1 1

Page 7: Bca 2nd sem-u-1.6 digital logic circuits, digital component

AND

• X & Y (Verilog and ABEL)• X and Y (VHDL)• X Y• X Y• X * Y• XY (textbook)• and(Z,X,Y) (Verilog)

U

V

Page 8: Bca 2nd sem-u-1.6 digital logic circuits, digital component

OR Gate

OR

X

YZ

Z = X | Y

X Y Z0 0 00 1 11 0 11 1 1

Page 9: Bca 2nd sem-u-1.6 digital logic circuits, digital component

OR

• X | Y (Verilog)• X # Y (ABEL)• X or Y (VHDL)• X + Y (textbook)• X V Y• X U Y• or(Z,X,Y) (Verilog)

Page 10: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Basic Logic Gates and Basic Digital Design[1]

• NOT, AND, and OR Gates

• NAND and NOR Gates

• DeMorgan’s Theorem

• Exclusive-OR (XOR) Gate

• Multiple-input Gates

Page 11: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NAND Gate

NAND

X

Y

Z

X Y Z0 0 10 1 11 0 11 1 0

Z = ~(X & Y)nand(Z,X,Y)

Page 12: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NAND Gate

NOT-AND

X

Y

Z

W = X & Y

Z = ~W = ~(X & Y)

X Y W Z0 0 0 10 1 0 11 0 0 11 1 1 0

W

Page 13: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NOR Gate

NOR

X

YZ

X Y Z0 0 10 1 01 0 01 1 0

Z = ~(X | Y)nor(Z,X,Y)

Page 14: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NOR Gate

NOT-OR

X

Y

W = X | Y

Z = ~W = ~(X | Y)

X Y W Z0 0 0 10 1 1 01 0 1 01 1 1 0

ZW

Page 15: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Basic Logic Gates and Basic Digital Design

• NOT, AND, and OR Gates

• NAND and NOR Gates

• DeMorgan’s Theorem

• Exclusive-OR (XOR) Gate

• Multiple-input Gates

Page 16: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NAND Gate

X

Y

X

Y

Z Z

Z = ~(X & Y) Z = ~X | ~Y

=

X Y W Z0 0 0 10 1 0 11 0 0 11 1 1 0

X Y ~X ~Y Z0 0 1 1 10 1 1 0 11 0 0 1 11 1 0 0 0

Page 17: Bca 2nd sem-u-1.6 digital logic circuits, digital component

De Morgan’s Theorem-1

~(X & Y) = ~X | ~Y

• NOT all variables• Change & to | and | to &• NOT the result

Page 18: Bca 2nd sem-u-1.6 digital logic circuits, digital component

NOR Gate

X

YZ

Z = ~(X | Y)

X Y Z0 0 10 1 01 0 01 1 0

X

YZ

Z = ~X & ~Y

X Y ~X ~Y Z0 0 1 1 10 1 1 0 01 0 0 1 01 1 0 0 0

Page 19: Bca 2nd sem-u-1.6 digital logic circuits, digital component

De Morgan’s Theorem-2

~(X | Y) = ~X & ~Y

• NOT all variables• Change & to | and | to &• NOT the result

Page 20: Bca 2nd sem-u-1.6 digital logic circuits, digital component

De Morgan’s Theorem

• NOT all variables

• Change & to | and | to &

• NOT the result

• --------------------------------------------

• ~X | ~Y = ~(~~X & ~~Y) = ~(X & Y)

• ~(X & Y) = ~~(~X | ~Y) = ~X | ~Y

• ~X & !Y = ~(~~X | ~~Y) = ~(X | Y)

• ~(X | Y) = ~~(~X & ~Y) = ~X & ~Y

Page 21: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Basic Logic Gates and Basic Digital Design[1]

• NOT, AND, and OR Gates

• NAND and NOR Gates

• DeMorgan’s Theorem

• Exclusive-OR (XOR) Gate

• Multiple-input Gates

Page 22: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Exclusive-OR Gate

X Y ZXOR

X

YZ 0 0 0

0 1 11 0 11 1 0

Z = X ^ Yxor(Z,X,Y)

Page 23: Bca 2nd sem-u-1.6 digital logic circuits, digital component

XOR

• X ^ Y (Verilog)• X $ Y (ABEL)• X @ Y

• xor(Z,X,Y) (Verilog)

X Y (textbook)

Page 24: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Exclusive-NOR Gate

X Y ZXNOR

X

YZ 0 0 1

0 1 01 0 01 1 1

Z = ~(X ^ Y)Z = X ~^ Yxnor(Z,X,Y)

Page 25: Bca 2nd sem-u-1.6 digital logic circuits, digital component

XNOR

• X ~^ Y (Verilog)• !(X $ Y) (ABEL)• X @ Y

• xnor(Z,X,Y) (Verilog)

X Y

Page 26: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Basic Logic Gates and Basic Digital Design[1]

• NOT, AND, and OR Gates

• NAND and NOR Gates

• DeMorgan’s Theorem

• Exclusive-OR (XOR) Gate

• Multiple-input Gates

Page 27: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Multiple-input Gates[2]

Z 1 2

3 4 Z Z

Z

Page 28: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Multiple-input AND Gate

Z 1

Output is HIGH only if all inputs are HIGHZ 1

An open input will float HIGH

Page 29: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Multiple-input OR Gate

Output is LOW only if all inputs are LOWZ 2

2 Z

Page 30: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Multiple-input NAND Gate

Output is LOW only if all inputs are HIGHZ 3

3 Z

Page 31: Bca 2nd sem-u-1.6 digital logic circuits, digital component

Multiple-input NOR Gate

Output is HIGH only if all inputs are LOWZ 4

4 Z

Page 32: Bca 2nd sem-u-1.6 digital logic circuits, digital component

References

1. Computer Organization and Architecture, Designing for performance by William Stallings, Prentice Hall of India.

2. Modern Computer Architecture, by Morris Mano, Prentice Hall of India.

3. Computer Architecture and Organization by John P. Hayes, McGraw Hill Publishing Company.

4. Computer Organization by V. Carl Hamacher, Zvonko G. Vranesic, Safwat G. Zaky, McGraw Hill Publishing Company.