CS31 Weekly Lab Week 3

logisim
Log in and create a cs31/weeklylab/week03 subdirectory and copy over some files from my public/cs31/week03/ directory into your subdirectory:
    cd
    cd cs31
    cd weeklylab
    mkdir week03
    cd week03
    pwd
    cp ~newhall/public/cs31/week03/* .
    ls
    decoder.circ firstcircuit.circ  

Goals for this week:

  1. Learn how to use logisim, and start the tutorial
  2. Introduction to lab 3
Logisim
I suggest working in the CS labs on logisim rather than logging in remotely. Logisim will run very slowly if you are remotely logged in due to X forwarding events (use ssh -Y on Mac or Linux to enable X-forwarding, on Windows you need to install an X server to run logisim remotely). Alternatively, you can install logisim on your own computer, and scp your .circ file to/from your computer to your CS account. We are using version 2.7. Make sure to install the same version. Also, if you do this, you need to ensure that your circuit file works on logisim running on our system.

The Logisim simulator

This week we will start using the Logisim simulator to create circuits and to see what the does given different input. We will learn more Logisim in class, but today I want to step through a few examples using it.

The Logisim web page has user documentation that will be very helpful for the next lab assignment. We are using version 2.7.

$ logisim    # start new project

$ logisim  proj_file.circ  # edit an existing project
We will start with firstcircuit.circ, and try builiding a simple AND circuit and some tester circuitry around it:
$ logisim  firstcircuit.circ  
Next, we are going to build a 2-to-4 1 bit decoder (2 1 bit inputs, 4 1 bit outputs).
       A --------o
           |       AND ---------  1 if both A and B are 0
       B --------o
           |  |
           *--|--o
           |  |     AND ---------  1 if A is 0 and B is 1
           ---*---
           |  |
           *--|--
           |  |     AND ---------  1 if A is 1 and B is 0
           ---*--o
           |  |
           *--|--
           |  |     AND ---------  1 if A is 1 and B is 1
           ---*--
This we will build as a circuit in logisim (Project:Add Circuit). Then we will incorporate this into some tester circuitry in the main circuit:
$ logisim  decoder.circ  
Next, step through the Beginner's tutorial and try building the XOR circuit.
Lab 3 Intro
Click on the lab 3 link off the class schedule for week 3. We will go over the lab 3 assignment and requirements.