"Lucky seven" Lab
Purpose
Components used
Pinouts are attached. Lab ProblemsThis lab focuses on the Arithmetic Logic Unit, or ALU, as described in Chapter 10 of our text. SetupGrab a 181 and hook it up. The ALU interface is a little more complex than we've seen:
To complete the lab, I recommend the following:
The ALU diagram describes the operation of the ALU in active high and active low mode. We will use active high. As a result, ALU values A, B, and F are all active high, and the carry values Cn and Cn+4 are active low. 1. Test the logic functions of the ALULogic functions are activated in the ALU by setting the mode bit, M, to logic 1. With mode set to 1, complete the table exercising the logic mode operations of the ALU. Deliverable: Complete a table exercising all 16 logic functions of the ALU, for select inputs 0000 - 1111, for 3 values of A=0000, A=1111, and A=0010. The value of B in all cases will be 0101. Your table should look like:
2. Test the arithmetic functions of the ALUConnect the mode input, M, to logic 0 to set the ALU in arithmetic mode. Disconnect the carry-in bit, Cn, of the ALU from logic 0, and connect it to one of the pulse buttons, like PB1. Connect the Carry out bit, Cn+4, to an LED to watch for carry-out, i.e. overflow, during your arithmetic operations. Remember that carry-in and carry-out are active low, so you are setting and seeing the complements of these values. Deliverable: Now, complete a similar table for all 16 arithmetic operations. Deliverable: Test your carry-in pulse button on a number of cases and document the effect of carry-in on the function outputs. Deliverable: Test your carry-out bit for a number of different cases, where you expect and don't expect overflow. Note these on your table. |