Code 21


Code 21 Rules


Additional Support

When working on larger projects it is easier to divide the problem in smaller pieces.  Solving a series of smaller problems often allows for a more efficient problem solution in contrast to tackling the entire problem at once.  I would suggest the completing the following steps to complete this project.

 Run the screen demo code on the proto-type board.  It can be found under Files/Examples/HT1632 menu in the Arduino IDE.  If you are using your own computer, you will need install Arduino.  You will also need to install the drivers for the 16x24 LED board.  Information on the display can be found at:


Aurduino Libraries

You need download two Arduino libraries for the display from Github:

Initially, you should build off the "matrixshapes" demo code using the matrix.drawpixel command.


Arudino Help

Using the search box on the homepage will be very beneficial.  


Implement and test the pushbutton. 

When attaching a pushbutton to a microcontroller it is important to prevent shorting your power supplied to the button directly to ground.  It is also important to prevent a "floating".  To do this you can either use a pull-up or pull-down resistor in your button circuit.  The following tutorial explains pull-up and pull-down resistors:

You will need to use the digital read statement to read the input pin on the Arduino.  The following tutorial explains how to implement the digital read statement on an Arduino:

To test and troubleshoot your circuit, it may be beneficial to use the serial monitor.  This will allow you to print values to your computer screen.  The following tutorial demonstrates how to use a pushbutton circuit and print the value to the serial monitor:


Implement and test the joystick

The joystick on the board is a Parallax 2-axis joystick.  Documentation can be found at the following link:

You will need to use the analog read statement to read the input pin on the Arduino.  The following tutorial explains how to implement the analog read statement on an Arduino:

It is also suggested that you use the serial monitor to verify the functionality of the joystick.


Screen Graphics

You should only write or update the screen at the end of the void loop function in Arudino.  Include a delay after the screen write to control the framerate of you video game.  It is suggested that your update the screen at roughly 30 frames per second.  This would be a delay of 33 ms.  



You may use a single pizeo element.  The following code will help you implement a buzzer. Sample Code.  Download the .txt file and paste into the Arduino editor.

Also the following tutorial may be helpful.