Beruflich Dokumente
Kultur Dokumente
Hai Zhou
EECS 303
Advanced Digital Design
Fall 2011
Implementation
Debug
Design
Initial concept: what is the function performed by the object?
Constraints: How fast? How much area? How much cost?
Refine abstract functional blocks into more concrete realizations
Implementation
Assemble primitives into more complex building blocks
Composition via wiring
Choose among alternatives to improve the design
Debug
Faulty systems: design flaws, composition flaws, component flaws
Design to make debugging easier
Hypothesis formation and troubleshooting skills
EECS 303 Lecture 1 8
Digital Systems
Digital vs. Analog Waveforms
+5 +5
1 0 1
V V
Time Ti me
–5 –5
Digital: Analog:
only assumes discrete values values vary over a broad range
continuously
Combinational logic
no feedback among inputs and outputs
outputs are a pure function of the inputs
e.g., full adder circuit:
(A, B, Carry In) mapped into (Sum, Carry Out)
A
B Full Sum
Cin Adder Cout
EECS 303 Lecture 1 11
Digital Hardware Systems
Sequential logic
output and new state is a function of the inputs and the old state
i.e., the fed back inputs are the state!
Synchronous systems
period reference signal, the clock, causes the storage elements to
accept new values and to change state
Asynchronous systems
no single indication of when to change state
EECS 303 Lecture 1 12
Case Study of a Simple Logic Design:
Seven Segment Display
• Chip to drive digital display
L1 B3 B2 B1 B0 Val
0 0 0 0 0
L L 0 0 0 1 1
4 6 0 0 1 0 2
0 0 1 1 3
L2 0 1 0 0 4
0 1 0 1 5
L L 0 1 1 0 6
5 7 0 1 1 1 7
1 0 0 0 8
L3 1 0 0 1 9
Case Study (cont.)
L1 B3 B2 B1 B0 Val L1 L2 L3 L4 L5 L6 L7
0 0 0 0 0 1 0 1 1 1 1 1
L L 0 0 0 1 1 0 0 0 0 0 1 1
4 6 0 0 1 0 2 1 1 1 0 1 1 0
0 0 1 1 3 1 1 1 0 0 1 1
L2 0 1 0 0 4 0 1 0 1 0 1 1
0 1 0 1 5 1 1 1 1 0 0 1
L L 0 1 1 0 6 1 1 1 1 1 0 1
5 7 0 1 1 1 7 1 0 0 0 0 1 1
1 0 0 0 8 1 1 1 1 1 1 1
L3 1 0 0 1 9 1 1 1 1 0 1 1
Case Study (cont.)
• Implement L4:
B3 B2 B1 B0 L4
0 0 0 0 1
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 1
0 1 0 1 1
0 1 1 0 1
0 1 1 1 0
1 0 0 0 1
1 0 0 1 1 Some gate level implementation
of the Boolean function for L4
Representations of Digital Design:
Switches
A switch connects two points under control signal.
Normally Open when the control signal is 0 (false), the switch is open
Fal se Fal se
Normally Open Normally Clos ed
Switch Switch
Open Closed
Switch EECS 303 Lecture 1 Switch 16
Switch Representations
Examples: routing inputs to outputs through a maze
EXAMPLE:
Car in Garage Car
IF car in garage garage door open running
AND garage door open
AND car running Car can
True
THEN back out car back out
A B A B
Fals e Fals e
output output
True True
Truth Tables
tabulate all possible input combinations and their associated
output values
NOT X is written as X
X AND Y is written as X & Y, or sometimes X Y
X OR Y is written as X + Y
Sum = A B + A B
A B Sum Carry
OR'd together product terms
0 0 0 0 for each truth table
0 1 1 0 row where the function is 1
1 0 1 0
1 1 0 1 if input variable is 0, it appears in
complemented form;
if 1, it appears uncomplemented
EECS 303 Lecture 1 20
Carry = A B
Representations of a Digital
Design: Boolean Algebra
Another example:
0 0 0 0 0
0 0 1 1 0
0 1 0 1 0
0 1 1 0 1
1 0 0 1 0
1 0 1 0 1
1 1 0 0 1
1 1 1 1 1
B
OR
Net 2
CARRY
SUM
Cin
A
B
Cout B Cout
Cin
A
Cin
sum sum
propagation propagation
delay delay
circuit hazard: 1 plus 0 is 1, not 0!
Sum A Sum
A A Sum A Sum A Sum
HA HA B
B B Carry B Carry B FA
Cout
Cin Cout
Ci n Cin Cout