Professional Documents
Culture Documents
x1
x1 . x 2 x 2 .x
x 3 x1 . x 2 x 2 .x
x3
x2 x1 . x 3 x1 .x 3 x 3
x3
x1
x2
x3
y
x1
x2
x3
Much ado about nothing !! Bad Example.
x1
x2
x3
ESc201, Lecture 30: (Digital)
Implementation using only NAND gates
NAND to Inverter x x .x=x
NAND to AND x
y
x.y
x
x.y x
NAND to OR
y
y f = x . y = x+y
I l
Implementation
t ti using
i only
l NOR gates
t
NOR to Inverter x
x x + x=x
NOR to OR
y
x+y x
x+y x
NOR to AND y
y f = x + y = x.y
ESc201, Lecture 30: (Digital) Implementation using only NOR gates
To implement using NOR gates, it is easiest to start with minimized Boolean
expression
i ini POS form.
f f =(a+b).(c+d).(f+g)
(a+b) (c+d) (f+g)
a
b
c AND
d f
g
h
a
b OR
c UNNECESSARY
f
There is a one
one--to
to--one mapping between OR
OR--AND
d
network and NOR network.
g T implement
To i l t SoP
S P expression
i usingi NOR gates,
gates
t , determine
d t i first
fi t the
th
h corresponding PoS expression and then follow the procedure outlined here. OR
x
yz
00 01 11 10
Implement f(x,y,z) = x .z+x .z using NOR gates
x
1 0 0 1 x
0 z
z
1 0 1 1 0 x f x f
f =( x +z).(x + z) z
z
Similarly PoS expression can be implemented as NAND network by first converting it to SoP
expression and then following the procedure outlined earlier
ESc201, Lecture 30: Digital Design Flow
x
System Description
x y z f y system f
z
0 0 0 0
Truth Table
0 0 1 1
0 1 0 0
0 1 1 1
1 0 0 0
Boolean Expression
1 0 1 1 f = x .y.z+x
y z+x . y.z+x
y z+x . y.z+x
y z+x . yy.zz
1 1 0 0
1 1 1 1
Minimized f = x .z+x
z+x .z=z
z=z
Boolean Expression x
y
y
z C
Gate Netlist
Gate Netlist for circuit
for circuit
level description x
z
ESc201, Lecture 30: (Digital: Implementation Hazards)
A hazard or glitch in digital logic is a fault in the logic system due to a change at the input.
C
Causes and
d effects:
ff t
Due to some form of delay caused by logic elements (NOT, AND, OR gates etc.), results in the logic
not performing its function properly. It is a temporary problem, and the logic will finally come to the
desired function,, but the gglitch may
y propagate
p p g and cause pproblems.
Static-1 Hazard: The output should be 1 but goes momentary to 0 as a result of an input change (possible in AND-
Static- AND-
OR circuits) . Hence in SOP implementation with finite Gate delay.
BC00 01 11 10 Assume B=1, C=1, and A changes from 1 to 0
A 0 2 6 4
f =A.C
=A C +A
+A.B
B A
0 0 1 1 0 x
A x
1 3 7 5 B f
1 0 0 1 1 y
C y f
Remedy is to take another term shown by the dotted loop Glitch
t
Static--0 Hazard: The output should be 0 but goes momentary to 1 as a result of an input change
Static
(possible in OR-
OR-AND circuits). Hence POS implementation with finite gate delay.
YZ 00 01 11 10 X=0,Y=0, and Z changes from 0 to 1
Assume X=0,
X 0 2 6 4 f =(Y +Z) (X+ Z) Z
0 1 0 0 0 a a
Z
1 3 7 5 Y f b spike
1 1 1 1 0
X b f
Remedy is to take another factor shown by the dotted loop Glitch
t
Function hazards are non-
non-solvable hazards which occurs when more than one input variable changes
at the same time. Dynamic hazards often occur in larger logic circuits where there are different routes
to the output (from the input).
ESc201, Lecture 30: (Digital) Representing positive and negative binary
One extra bit is required to carry sign information. Sign bit = 0 numbers
represents positive number and Sign bit = 1 represents negative no.
no
decimal Signed decimal Signed decimal Signed 1’s decimal Signed 2’s
Magnitude Magnitude complemen complemen
0 0000 -0 1000 t t
2’ complement off n
2’s n--bit i 2n -x
i number x is