Documente Academic
Documente Profesional
Documente Cultură
FALL 2010
EXAM II
STUDENT INFORMATION
Name ID Number
INSTRUCTIONS
The exam is closed book and notes. A single double-sided cheat sheet is allowed. Print your name and your ID number. There are four problems in the exam. Solve all of them and show your work. If you need more space for your solution, use the back of the sheets.
EXAM GRADE
Problem 1 2 3 4 Total Maximum Points 25 25 25 25 100 Student Score
UC Davis
Hussain Al-Asaad
1.2 Suppose that we have an 8-bit adder (shown below), show how we can implement the function Y = 48 X + 47 .
c8
a7 b7 a6 b6 a5 b5 a4 b4 a3 b3 a2 b2 a1 b1 a0 b0 c s7 s6 s5 s4 s3 s2 s1 s0 0
UC Davis
Hussain Al-Asaad
2. FLIPFLOPS (5 + 6 + 6 + 8 = 25 POINTS)
Consider a new type of a positive edge-triggered flip-flop that we call the AB flip-flop. The + characteristic equation of the AB flip-flop is Q = AQ + B . Moreover, the mode AB = 11 is not allowed. 2.1 Complete the table below.
A A B CLK Q Q 0 0 1 1
B 0 1 0 1
Mode
UC Davis
Hussain Al-Asaad
a
FA
a
FA
a
FA
a
FA
b
0
cout s cin D3
D flip-flop
cout s cin D2
D flip-flop
cout s cin D1
D flip-flop
cout s cin D0
D flip-flop
Q3
Q2
Q1
Q0
UC Davis
Hussain Al-Asaad
3.2 By using four D flip-flops and four full adders only (components shown below), design a 4bit binary counter with two inputs U (up) and D (down) that works as follows: 1. If U = 1, the counter counts up. 2. If D = 1, the counter counts down. 3. If U = 0 and D = 0, the counter hold its state. Assume that the input combination (U = 1, D = 1) is considered a dont care. Moreover, assume that the literals and their complements are available. Show the schematic of your design.
U D
a
FA
D
D flip-flop
cout s cin
UC Davis
Hussain Al-Asaad
f(X,Y,Z)
T1
Q1 Q1
D0
Q0 Q0
Q2
Q1
Q0
Design the combinational circuit C using the minimum number of logic gates, so that the counter produces the largest counting sequence. Also, draw the resulting state diagram of the counter (Use the order of Q2Q1Q0 in labeling the states). Is the resulting counter self starting?
UC Davis
Hussain Al-Asaad