Use this table: hw4-1.pdf.
Use this table: hw4-2.pdf.
This display should display the numbers from 1 to 10 and then cycle back to 1. (Note: this is off-by-one from the 0 through 9 stored in the flip flops.)
Use the following table to determine the formulas you should use for each segment of the display: hw5-1.pdf.
Note that you only need 8 output variables, since the 7-segment display for the ten's place either shows 1 or nothing. Use the output variables o1 through o8 as indicated below the truth table. Show how you derived and simplified the Boolean formulas for each output variable. Turn in your table and your work on paper in class.
Implement your counter with 7-segment displays in Logisim. Then, save and submit the circuit file on GL:
In this version of the 2-bit CPU, each register has its own MUX for its input. These are labeled R0MUX and R1MUX. As before, these MUXes will select input from either Reg0 (00), Reg1 (01), Immediate Operand (10) or ALU Output (11). To store the result in one register, its MUX must be enabled. To make sure that the other register holds its current values, the other register's MUX must be disabled.
For example, to direct the ALU output to Register 1, R1MUX must be enabled and its select bits set to 11. Also, R0MUX must be disabled (its select bits can be set to anything.) In the circuit above, the control wires for R0MUX and R1MUX are bundled into 3-bit wide wire bundles. The enable bit is bit 0. Thus, we can set the R0MUX lines to 110 and the R1MUX lines to 111. (Actually, R0MUX can be xx0.) You can test this out in the existing circuit by disconnecting the R0MUX and R1MUX lines from the Instruction Decoder and connect them to the R0MUX Test and R1MUX Test input pins. Then you can manually enter the settings and check the correctness.
With 2 MUXes instead of just one, this version of the 2-bit CPU can implement two instructions that were not possible before:
Use the instruction code 101x xxxx for the EXCHG instruction and 110x xxxx for the RESET instruction. See lecture slides Slides25.pdf for a description of the instruction code format.
Use this table: hw5-2.pdf. Most of the table has been filled out for you. You just have to fill in the table for the EXCHG and RESET instructions. Then, use the table to derive formulas for the settings for R0MUX and R1MUX. Turn in your table and your work on paper in class.
Finally, implement your extension in Logisim. You can start with this circuit: hw5 2-bit CPU.circ.
The only circuitry that you need to modify is the Instruction Decoder. Test your circuit. When you are satisfied that it works correctly, save and submit the circuit file on GL: