CS-212
Lab 4
Spring 2011

  1. Stack 'em Up... Using the Queue and Stack datatypes you created for Lab 3. Write a Program that will allow the user to input a fully parenthesised expression consisting of the characters 0123456789()+-*/ and evaluate the expression. There should be functions for accepting input, printing output and evaluating the expression. Do this on Linux using GCC.
  2. Studio 4 Input, compile and create a .hex file for the Blink program from the notes. Load the blink.hex file into the Arduino using the AVRDUDE program that was installed with WinAVR. Use this .bat file to run AVRDUDE
  3. Studio 4 Using your solderless breadboard from your digital class, hook up two LEDs (don't forget the current limiting resistors) on port B. Make sure you ground the solderless breadboard to the circuit ground of the Arduino board or you won't be able to operate the LEDs. Modify the blink.c program (give it a new name) so that it will blink the two LEDs alternately at a once second rate. If you make one red and the other one green it will be like a traffic light.

    Create a lab4 directory on the class server using your FTP account and upload the source code of your files. Demonstrate all parts of the lab to your TA (or me if I'm in my office)