by
Varun Agrawal
Nipun Virmani
This project involved creating a game called Snake which was driven using a Nintendo 8 controller and displayed on an LCD screen. The snake seen on the screen was driven automatically with its speed increasing after collecting three dots. The user controlled the direction of the snake using the Nintendo controller and had to avoid running into walls or the snake’s body itself.
Major Components –
· LCD Module which was driven by the controller on board the MPC823. This was a major component of the project as the LCD controller had never been completely utilized to its potential in the 373 lab. It involved programming the device registers and setting up timing signals so that data could be displayed correctly.
· Nintendo 8 Controller which was used to control movements of the snake. The major task here was to setup the hardware to generate the signals required and to store the data returned by the controller. We set it up as a memory mapped device which we read from at a rate of 20 times a second.
· Serial Communication which was used to show the game as well. It was mainly used as a debugging tool until the LCD was ready for display
· Interrupts and Timers. Most of the software was implemented as interrupt handler routines. We used two timers, one to poll the controller and one to refresh the screen at a set rate.
The most challenging component in this project was the LCD controller. A number of different settings had to be made about which we were not very certain. Hence a lot of what we did involved a good amount of testing and experimenting with. Also the user manual was not very clear on explaining some of the parameters that need to be set which made our task much harder.