Montana Tech of The University of Montana
Computer Science & Software Engineering

CSCI 255
Introduction to Embedded Systems
Fall 2011


Lab #4 - Push the button v2.0

The goal of this assignment is to gain experience using subroutines, improve your assembly language style, and practice using the integrated debugger in the Keil IDE. You should do this lab individually (even if you submitted as a pair for lab #3).
As assembly language is closer to the hardware, it is also further from being human-readable. Rewrite your program from lab #3 to make it beautiful. This includes: Using the debugger. You should test your modified program using the Keil IDE. After compiling your program, select Debug -> Start/Stop Debug Session You can step the program using F10 and F11. While stepping your program, note you can view changes to registers, the accumulator, etc. in the register window. F10 will step over subroutines while F11 will step into subroutines. Experiment with inserting breakpoints (F9) and then running the program until it encounters the next breakpoint (F5). Open up the appropriate Peripherals -> I/O-ports windows so you can observe output to your LEDs and buzzer, and provide input to your button.
Submission. Submit your program Lost2.asm via Moodle. Be sure your submitted source file has the required header with your name, username, and a description of the program. Your program will be graded on functionality, readability and elegance.

Page last updated: August 16, 2012.  Copyright © 2011 by Keith Vertanen.