






Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
This is a closed book exam for ece 199 course in spring 2004, consisting of 5 problems related to computer engineering, including number systems, logic circuits, finite state machines, memory, and programming. Students are allowed to bring one handwritten 8.5 x 11 sheet of notes.
Typology: Exams
1 / 12
This page cannot be seen from the preview
Don't miss anything!







Problem 1 20 points _______________________________
Problem 2 20 points _______________________________
Problem 3 20 points _______________________________
Problem 4 20 points _______________________________
Problem 5 20 points _______________________________
Total 100 points
Name:
Part A (5 points) : Convert the following numbers.
-15 (from decimal to 8-bit 2’s complement)
11011001 (from 8-bit 2’s complement to decimal)
Part B (5 points): Is the pair of functions ƒ (^) 1, ƒ2 together logically complete? Prove that your answer is correct.
A B ƒ 1 ƒ (^2) 0 0 1 0 0 1 1 0 1 0 0 1 1 1 0 0
Part A (5 points): Fill in the truth table for the circuit below.
A B C F 0 0 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1 1 1
*****Part B** (3 points): The above circuit can be simplified to use fewer transistors without changing the logical function. Draw such a circuit.
Part C (5 points): Use a 3-input decoder and one multi-input gate to implement a majority function, i.e., a 3-input function that outputs a 1 when two or more (the majority) of its inputs are 1’s. Be sure to label all relevant parts of the decoder.
For the following question, refer to the circuit below.
Part A (7 points): Draw the finite state machine transition diagram for the circuit. Be sure to fill in all input transition arcs and state outputs. The state diagram (Q = Q 1 Q 0 ) has been partially filled in to help you get started. Hint: For each value of A, write the next state in terms of the current state, then label the diagram below.
Part B (3 points): Assuming that the circuit is started in state Q 1 Q 0 = 00, are all states reachable? In other words, is it possible for the state of the circuit to take on any given combination of 0s and 1s through some sequence of inputs? Explain your answer.
Part C (5 points): Fill in the table for the new state Qnew (=Q 1 Q 0 ) and the output F after each input transition has completed. Assume that the circuit is initially in state Q 1 Q 0 =00.
A 0 1 1 0 0 1 0 1 1 0 1 1
Q (^) new
Fnew
Part D (5 points): Summarize what this circuit does in one sentence.
Part A (15 points): The code fragment below calculates (R1 × R1) + 6 , leaving the result in R3. First translate the instructions to register transfer language (RTL). For example, the instruction 1001 0000 0111 1111 is “R0 Å NOT R1” in RTL. After translating the instructions, fill in the missing bits to complete the program and update the RTL to reflect your additions.
Address Instruction Bits RTL
x3000 0101 0110 1110 0000 x x3002 0001 0110 1100 0001
x3003 0001 0100 1011 1111 x3004 0000 1011 x3005 0001 0110 1110 0110
Note that we will not grade on RTL syntax, but what you write must convey the action taken by the LC-3 when processing each instruction.
*****Part B** (5 points): If R1 and R3 hold 16-bit 2’s complement numbers, for what values of R1 is the result in R3 correct (i.e., equal to the expression (R1 × R1) + 6 ) after executing the code above? Explain your answer.
Use this page for scratchwork