+ All Categories
Home > Documents > Digital Logic Chapter 2 Basics - eca.cs.purdue.edueca.cs.purdue.edu/CS250/ir/lec/Chap2.pdf ·...

Digital Logic Chapter 2 Basics - eca.cs.purdue.edueca.cs.purdue.edu/CS250/ir/lec/Chap2.pdf ·...

Date post: 04-Apr-2018
Category:
Upload: trannhi
View: 216 times
Download: 0 times
Share this document with a friend
29
Basics Chapter 2 Digital Logic CS250 -- Part 1 1 Dr. Rajesh Subramanyan, 2005
Transcript

Basics

Chapter 2

Digital L

ogic

CS250 -- Part 1

1D

r.Rajesh Subram

anyan, 2005

Topics

•V

oltage And C

urrent

•T

ransistor

•L

ogic Gates

•Sym

bols Used For G

ates

•Interconnection O

f Gates

•IC

Chips

•C

ombinatorial C

ircuits

•Flip-Flops

•B

inary Counters

•C

locks

CS250 -- Part 1

2D

r.Rajesh Subram

anyan, 2005

Topics

•D

emultiplexor

•Feedback C

oncepts

•Iteration vs R

eplication

•C

hip Engineering A

spects

−G

ate & chip m

inimization

−Spare gate utilization

−Pow

er & heat dissipation

−C

lock Skew

•Process Technologies

•Physical Size O

f IC’s

CS250 -- Part 1

3D

r.Rajesh Subram

anyan, 2005

Voltage A

nd Current

•V

oltage

−potential force m

easured between tw

opoints

−units is volts

−m

easuring device is voltmeter

•C

urrent

−flow

ofelectrons along a path

−units is

amps

•G

round

−point that is assum

ed to be 0 volts

CS250 -- Part 1

4D

r.Rajesh Subram

anyan, 2005

Transistor

•A

semiconductor device that is used to control flow

ofelectrical current; a m

iniature switch

•3

connections in a transistor

−2

for current flow

−1

for controlling flowB

CE

small current flow

sfrom

hereto

point E

large current flows

from point C

to point E

Symbol

•W

hat do you do with a transistor in digital circuits and

computer architecture?

CS250 -- Part 1

5D

r.Rajesh Subram

anyan, 2005

Logic G

ates

•B

asic boolean functions

−and, or,not

•T

ruth tables

AB

Aan

d B

0011

0101

0001

AB

Ao

rB

0011

0101

0111

An

ot A

0110

Atable consisting of output result for each possible set of

inputs

CS250 -- Part 1

6D

r.Rajesh Subram

anyan, 2005

Logic G

ates

•W

hat do you do with a transistor in digital circuits and

computer architecture?

−T

ransistors can be used to implem

ent boolean functions.

−B

oolean functions are used in building digital circuits

•A

ll digital systems at low

est levelcomposed of transistors

•0

isfalse,1

istrue.

•In

transistor voltage, 0V is boolean 0 and

5V is boolean 1

CS250 -- Part 1

7D

r.Rajesh Subram

anyan, 2005

Exam

ple Of H

owT

ransistors Can B

e Used To

Build B

oolean Gates

inp

ut

ou

tpu

t

+5 volts

0vo

lts

resistor

Not gate im

plementation using a transistor and a resistor

•B

oolean circuits are called logic gates.

•M

anufacturers sell IC chips that contain all circuitry for gates

CS250 -- Part 1

8D

r.Rajesh Subram

anyan, 2005

Symbols U

sed For G

ates

nan

d g

aten

or g

ateinver ter

Symbols

AB

An

and

B0011

0101

1110

AB

An

or B

0011

0101

1000

Truth tables for nand and nor

CS250 -- Part 1

9D

r.Rajesh Subram

anyan, 2005

Interconnection Of G

ates

•G

ates can be connected together to obtain a combinatorial

circuit

−T

ransistor output of a gate is connected to inputtransistors in other gates

inp

ut fro

mp

ow

er butto

nin

pu

t from

disk

ou

tpu

t

XYZ

AB

Co

utp

ut

Exam

ple and output values

CS250 -- Part 1

10D

r.Rajesh Subram

anyan, 2005

IC C

hips

•T

TL

: Transistor-T

ransistor logic

−electronics parts that im

plement gates

−allow

s outputs of gate to be connected to gate(s) input.

•M

ultiple gates/IC

−T

TL

7400: 4 AN

D

−T

TL

7402: 4 OR

−T

TL

7404: 6 NO

T

•7400 fam

ily includes more sophisticated circuits as w

ell (flip-flops, counters, m

ultiplexors).

CS250 -- Part 1

11D

r.Rajesh Subram

anyan, 2005

Com

binatorial Circuits

•C

ircuits seen so far are called combinatorial

•H

ere, output changes only when input changes

•B

eyond combinatorial circuits

−H

ow can digital logic perform

a sequence of operationsw

ithout requiring input values to change?

*using m

ore sophisticated circuits discussed soon

−H

ow can a circuit continue to operate even

after inputreverts to original state?

*E

xample, user presses pow

er button once and asequence of operations are perform

ed

*U

sing clockC

S250 -- Part 112

Dr.R

ajesh Subramanyan, 2005

Flip-F

lops

•Flip-flops are

circuits that maintain state

−O

utput depends on present as well as past inputs

Transition diagram

for flip-flop

•O

utput transition may occur on

−leading edge (assum

e for nowas

default)

−falling edge

−both edges

•Som

e flip-flops have additional input calledresetto set

output to 0

CS250 -- Part 1

13D

r.Rajesh Subram

anyan, 2005

Binary C

ounters

•Flip-flop has only tw

ooutputs 0/1

•C

ounter is the alternative

•C

ounter accumulates num

eric total in binary

cou

nter

inp

ut

ou

tpu

ts

(a)

(b)

inp

uto

utp

utsdecim

al

time

increases

001011010101

00

00

00

00

10

01

01

00

10

01

00

11

01

11

00

10

01

01

001122233445. . .

Illustration of binary counter and sequence of input andoutput values

CS250 -- Part 1

14D

r.Rajesh Subram

anyan, 2005

Clocks

•R

ecap: clock allows output to change w

ithout changing input.

•C

locks emits alternate 0 and 1

•U

nits is hertz

•E

xample usage of clock

−H

ow to

perform sequence of operations w

ithout needingchange of inputs in betw

een the operations

CS250 -- Part 1

15D

r.Rajesh Subram

anyan, 2005

Scenario: computer startup

•Test battery

•Pow

er on and test the battery

•Start disk spinning

•Pow

er up the CR

T

•R

ead boot sector from disk into m

emory

•Start C

PU

CS250 -- Part 1

16D

r.Rajesh Subram

anyan, 2005

Scenario: computer startup

clock

cou

nter

dem

ultip

lexorn

ot u

sedtest b

atterytest m

emo

rystar t

disk

state CR

Tread

bo

ot b

lkstar t

CP

Un

ot u

sed

Illustration howa

clock can be used to create a circuit thatperform

s a sequence of six steps without changes to input

CS250 -- Part 1

17D

r.Rajesh Subram

anyan, 2005

Dem

ultiplexor

•Takes binary value as input and chooses a single output

•If

input represents valueiin binary,i’th

output is selected

dem

ultip

lexor

xyz

inp

uts

‘‘000’’‘‘001’’‘‘010’’‘‘011’’‘‘100’’‘‘101’’‘‘110’’‘‘111’’

ou

tpu

ts

Dem

ultiplexor with three inputs and eight outputs

CS250 -- Part 1

18D

r.Rajesh Subram

anyan, 2005

Feedback C

oncepts

•C

locks run forever, inprevious exam

ple, same operations

will be repeated after m

aximum

value is reached.

•H

ow do

you control operations?

−start or stop a sequence ?

−use feedback, output affects the w

ay circuit behaves.

CS250 -- Part 1

19D

r.Rajesh Subram

anyan, 2005

Feedback

•Stopping a sequence

−w

hen maxim

um value is reached, feedback enables

circuit to stop.

dem

ultip

lexor

cou

nter

clock

no

t used

test battery

test mem

ory

star td

iskstate C

RT

read b

oo

t blk

star tC

PU

stop

feedback

these two gates perform

the Boolean and function

Illustration of feedback to stop processing after one passthrough each output

CS250 -- Part 1

20D

r.Rajesh Subram

anyan, 2005

Feedback

•Starting a sequence

−use reset button to set output of dem

ultiplexor to 000,feedback inverter provides 1 as input,

CS250 -- Part 1

21D

r.Rajesh Subram

anyan, 2005

Iteration vs Replication

•H

ow do

you handle operations applied to multiple item

s?

−softw

are experts says iteration

−hardw

are experts says replication

•A

fundamental paradigm

/difference !!

•R

eplication

−m

akes hardware m

ore elegant

−sim

ultaneous operations speeds up execution

•Iteration

−sm

aller code, example

forloops

CS250 -- Part 1

22D

r.Rajesh Subram

anyan, 2005

Chip E

ngineering Aspects

•G

ate & chip m

inimization

−m

inimizing gates

*reduce boolean equations m

athematically

*exam

plex

and 1 = x; x or 0 =

x

−m

inimize IC

*4

nandgates better than 2

nandgates and 1

notgates

*reason, 2 IC

chips vs 1

CS250 -- Part 1

23D

r.Rajesh Subram

anyan, 2005

Chip E

ngineering Aspects

•Spare gate utilization

−assum

e need 1nand

and 1not,note 7400 has 4

nandgates

−use a spare

nandgate, avoid need for IC

7402notchip

−1

nandx

=notx

•Pow

er & heat dissipation

−less chips is better,low

er power used, so less heat

generated

−heat dissipation, prim

ary concern in industry

CS250 -- Part 1

24D

r.Rajesh Subram

anyan, 2005

Chip E

ngineering Aspects

•T

iming

−gate takes tim

e to settle

−signals take

time to propagate

−clock skew

*clock signal reaches different parts of a large circuit atdifferent tim

es due to propagation delay

*delay ˜1ns/feet

*solution: use several clocks instead of single globalclock

*dow

nside: clock synchronization

CS250 -- Part 1

25D

r.Rajesh Subram

anyan, 2005

Process Technologies

•M

ultiple gates/IC

−SSI

booleangates

−M

SI counters

−L

SI sm

allprocessors

−V

LSI

complex

processors

•A

SIC: A

pplication Specific Integrated Circuit A

SIC

CS250 -- Part 1

26D

r.Rajesh Subram

anyan, 2005

Physical Size O

f IC’s

•M

oore’sL

aw (G

ordon Moore, Intel)

−D

ensity of silicon circuits (transistors/inch 2)doubles

ev ery year (revises to 18 months in 70’s).

CS250 -- Part 1

27D

r.Rajesh Subram

anyan, 2005

Class E

xercises

•B

asic laws: com

mutative,associative,distributive,A

ND

-OR

duality

•W

riting a truth table for a circuit

•D

rawing a circuit for a boolean expression

•W

riting a boolean expression from a circuit

•Sim

plifying expressions

CS250 -- Part 1

28D

r.Rajesh Subram

anyan, 2005

CS250 -- Part 1

29D

r.Rajesh Subram

anyan, 2005


Recommended