introduction to computer engineering ece 203 - …robertdick.org/eecs203/lectures/ece203-l6.pdflab...

44
Introduction to Computer Engineering ECE 203 Northwestern University Department of Electrical Engineering and Computer Science Teacher: Robert Dick Office: L477 Tech Email: [email protected] Phone: 467–2298 Webpage: http://www.ece.northwestern.edu/˜dickrp/ece203 Teaching Assistants Zh ` eny ˇ uG` u (L470) Debasish Das (M314) 1

Upload: doquynh

Post on 26-Jun-2018

218 views

Category:

Documents


0 download

TRANSCRIPT

Introduction to Computer Engineering

ECE 203

Northwestern University

Department of Electrical Engineering and Computer Science

Teacher: Robert DickOffice: L477 TechEmail: [email protected]: 467–2298Webpage: http://www.ece.northwestern.edu/˜dickrp/ece203Teaching Assistants Zhenyu Gu (L470)

Debasish Das (M314)

1

Homework index

1 Reading assignment . . . . . . . . . . . . . . 42

2

Today’s topics

• Lab and lecture comments

• Review: Minimization overview

• Review: Karnaugh map SOP minimization

• POS using SOP K-map trick

• Quine-McCluskey optimal two-level minimization method

3

Lab and lecture comments

• Anybody falling behind?

• If something isn’t making sense, stop me and I’ll elaborate using

the chalkboard

– I’m glad to do it!

• Lab expectations (lab two and above)

– Complete schematics

– Easy to debug, color-coded wiring

– Terse but clear description

4

Review: Minimization techniques

Advantages and disadvantages?

• Algebraic manipulation

• Karnaugh maps

• Quine-McCluskey

• Advanced topic: Kernel extraction

• Advanced topic: Heuristic minimization, e.g., Espresso

5

Deriving POS

00 11 1001

01

00

11

10

1 1 1

11

11 1

0 0

0

0 0

10

0

f(a,b,c,d)ab

cd

Find SOP form for zeros:

f = ab z + c d + a b d

6

Deriving POS

Apply DeMorgan’s theorem

f = ab d + c d + a b d (1)

f = ab d + c d + a b d (2)

f =(

ab d)

· ( c d) ·(

a b d)

(3)

f =(

a + b +d)(

c+ d)(

a+b+ d)

(4)

• Advanced topic: Read the POS expression directly from the

Karnaugh map

– More difficult

7

Quine-McCluskey two-level logic minimization

• Compute prime implicants with a well-defined algorithm

– Start from minterms

– Merge adjacent implicants until further merging impossible

• Select minimal cover from prime implicants

– Unate covering problem

• What is happening?

– ab+a b = a

8

Computing prime implicants

0000

000100101000

10011010

1111

11011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

9

Computing prime implicants

000X0000

000100101000

10011010

1111

11011110

0000

0001

0000 000X

0001

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

10

Computing prime implicants

000X0000

000100101000

10011010

1111

11011110

0000

0001

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

11

Computing prime implicants

00X0000X0000

000100101000

10011010

1111

11011110

0000

00010010

000000X0

0010

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

12

Computing prime implicants

00X0000X0000

000100101000

10011010

1111

11011110

0000

00010010

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

13

Computing prime implicants

00X0X000

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

0000

X000

1000

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

14

Computing prime implicants

00X0X000

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

15

Computing prime implicants

00X0X000X001

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

1001

X0010001

1001

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

16

Computing prime implicants

00X0X000X001

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

1001

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

17

Computing prime implicants

00X0X000X001X010

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

0010 X010

1010

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

18

Computing prime implicants

00X0X000X001X010

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

19

Computing prime implicants

00X0X000X001X010100X

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

1000 100X

1001

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

20

Computing prime implicants

00X0X000X001X010100X

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

21

Computing prime implicants

00X0X000X001X010100X10X0

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

100010X0

1010

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

22

Computing prime implicants

00X0X000X001X010100X10X0

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

23

Computing prime implicants

00X0X000X001X010100X10X01X01

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

100110101101

1001 1X01

1101

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

24

Computing prime implicants

00X0X000X001X010100X10X01X01

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

100110101101

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

25

Computing prime implicants

00X0X000X001X010100X10X01X011X10

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

1001101011011110

1010 1X10

1110∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

26

Computing prime implicants

00X0X000X001X010100X10X01X011X10

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

1001101011011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

27

Computing prime implicants

00X0X000X001X010100X10X01X011X10111X

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

1111

110111101111

111X1110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

28

Computing prime implicants

00X0X000X001X010100X10X01X011X10111X

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

1111

11011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

29

Computing prime implicants

00X0X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

1111

110111101111

11X11101

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

30

Computing prime implicants

00X0X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000

000100101000

10011010

1111

11011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

31

Computing prime implicants

X00X00X0X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X

000100101000 100X

10011010

1111

11011110

000X

100X

X00X

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

32

Computing prime implicants

X00X00X0X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X

000100101000 100X

10011010

1111

11011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

33

Computing prime implicants

X00XX0X000X0

X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X00X0

000100101000 100X

10X010011010

1111

11011110

00X0

10X0

X0X0

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

34

Computing prime implicants

X00XX0X000X0

X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X00X0

000100101000 100X

10X010011010

1111

11011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

35

Computing prime implicants

X00XX0X000X0

X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X00X0X000X0010001

00101000 100X

10X010011010

1111

11011110

X000X001

X00X

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

36

Computing prime implicants

X00XX0X000X0

X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X00X0X000X0010001

00101000 100X

10X010011010

1111

11011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

37

Computing prime implicants

X00XX0X000X0

X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X00X0X000X0010001

00101000

X010100X10X0

10011010

1111

11011110

X000

X010

X0X0

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

38

Computing prime implicants

X00XX0X000X0

X000X001X010100X10X01X011X10111X11X1

000X0000

000100101000

10011010

1111

11011110

0000 000X00X0X000X0010001

00101000

X010100X10X0

10011010

1111

11011110

∑ = 4

∑ = 0

∑ = 1

∑ = 2

∑ = 3

39

Summary

• Review: Minimization overview

• Review: Karnaugh map SOP minimization

• POS using SOP K-map trick

• Quine-McCluskey optimal two-level minimization method

40

Next lecture – More advanced building blocks

• Encoders and decoders

• MUXs

• Advanced TG techniques

41

Reading assignment

• M. M. Mano and C. R. Kime, Logic and Computer Design

Fundamentals. Prentice-Hall, Englewood Cliffs, NJ, third ed.,

2004

• Sections 2.7–2.10

• Sections 4.1–4.5

• Section 4.6 (decoders and multiplexers only)

• M. M. Mano and C. R. Kime, Web supplements to Logic and

Computer Design Fundamentals. Prentice-Hall, Englewood

Cliffs, NJ, 2004. http://www.writphotec.com/mano/Supplements

handout on tabular method (Quine-McCluskey)

42

Additional references

• If QM doesn’t click, please also see the following references

• R. H. Katz, Contemporary Logic Design. The

Benjamin/Cummings Publishing Company, Inc., 1994: pp. 85–88

• J. P. Hayes, Introduction to Digital Logic Design. Addison-Wesley,

Reading, MA, 1993 pp. 320, 321

• You can get these from me or the library

43

Computer geek culture reference

• http://www.deepchip.com

44