SE-1021 Software Development 2
Lab 5: Reaction Timer

Outcomes

Assignment

You will complete the event handler for a program that randomly displays the names of colors on three different pushbuttons, and instructs the user of the app to push a button containing a specific color of text. The twist is that the buttons are randomly labeled "red" , "green", and "blue", but the color of the button text may be blue, red, and green. This conflict between colors and color names challenges your brain's ability to separate the text-processing from the color-processing in order for you to press the correct button. The program also "times out" after a specified period, after which a new mix of button text and colors appears. Points are scored for correct button presses, and deducted for incorrect presses or timeouts.

After 10 attempts, the program displays your total reaction time; that is, the time it took your brain to process and react to each directive concerning which button to press.

Project Setup

The lab5.zip file includes the following classes:

Details

    Follow the TODO comments in the ReactionTimerUI class. These comments indicate what you have to do to implement the EventHandler inner class and the event handling logic.

Lab Submission (due date in Blackboard)

  1. Demonstrate your Reaction Timer app to your instructor. If you can't do this by the end of class, you must demonstrate it sometime during Office Hours before the following lab. You will not receive a grade until you provide this demonstration. Demonstrations after the due date will be considered a late submission.
     
  2. Upload only your ReactionTimerUI.java file (containing both the ReactionTimerUI outer and EventHandler inner classes)through Blackboard (assignment "Lab 5: Reaction timer"). Be sure to keep copies of all your files, in case something gets lost.

Your grade will be based on the following criteria: