CSSE 232 - Computer Architecture I
Rose-Hulman Institute of Technology
Computer Science and Software Engineering Department

Exercise 5 -- Exploring Xilinx

A 1-bit ALU

  1. Download alu.zip .

  2. Create a folder named alu in your projects folder and extract alu.zip into it.

  3. Start the Xilinx Project Navigator and open the alu project.

    1. Double-click on alu (alu.sch).

    2. In the schematic tool, select the part labeled alu1b.

    3. ``Push'' into the part using the

      button.

    4. ``Push'' into the part labeled add1b.

  4. Go back to the Project Navigator and double-click on alutest (alutest.tbw). Adjust the wave form as necessary to fully test the ALU.

  5. Go back to the Project Navigator. With alutest (alutest.tbw) still highlighted, go down to the lower left pane and expand the $+$ next to Modelsim Simulator. Double-click on Simulate Behavioral Model.

  6. Are the outputs correct?

Adding Subtraction to the ALU

  1. Modify the 1-bit ALU so that it is capable of subtraction.

    1. Modify the schematic alu1b.sch as necessary to support subtraction. You will need to add a new control signal (use an I/O marker) to the 1-bit ALU. Call it binv. Save your changes.

    2. In the schematic alu.sch select the part labeled alu1b, right-click and select Symbol$\rightarrow$Edit Symbol. Edit the symbol using Add$\rightarrow$Pin and Add$\rightarrow$Line to include the new control signal. Save your changes.

    3. Back in the schematic alu.sch select Edit$\rightarrow$Update Obsolete Symbols and add an I/O marker for the new pin. Save your changes.

  2. Test your new 1-bit ALU.

Adding Overflow to the ALU

  1. Copy alu1b.sch to alu1bmsb.sch and add it to your project.

  2. Modify the 1-bit ALU for the most significant bit (MSB) to include an overflow detector. You will need to add an overflow output.

  3. Test your overflow detector.

A 4-bit ALU

  1. Modify alu.sch so that it contains a 4-bit ALU.

  2. Test your 4-bit ALU.



J.P. Mellor 2004-09-22