Finch as Game Controller

In this assignment, you will create your own game with a GUI. The Finch will be the game controller. Start by writing a program that moves a cursor on the screen based on the Finch accelerometer. For instance, you might make the cursor move to the left as the user tilts the Finch so that the left wing is down. To do this, your program will have at least two parts (which you may want to implement as classes). One will communicate with the Finch and use the accelerometer to determine the current position of the cursor on the screen. Remember, you will need to scale the acceleration values to map them to coordinates in the GUI window. The other part of the program will control the GUI, updating the user's position on the screen and controlling the other graphical elements of your game.

After you can use the Finch to control a cursor, the rest of the game is up to you! You might have the user try to hit various targets on the screen with the cursor. Alternatively, you can create a treasure hunt game where the user moves the Finch around the screen to find a hidden location. The Finch can even give the user feedback by blinking or beeping more rapidly as the user gets close to the target location.

Assignment Category: