Snake 8x8 LED-Matrix Project - Help

Hey Arduino-Community, I'm about to start an arduino project with my friend. He builds up a 8x8 LED-Matrix with Shifting registers and I'm going to programm on this LED-Matrix the game "Snake"( as an example: ). We're using bicolored LED's and now I've some question for the programming part: 1: Which programming knowledge do I must have for this project? I already read some tutorials about shift-registers like this one ( ). In a few days im gonna get the Matrix, but until today i've only programmed a 1x8 LED "Matrix", but I understood how shift registers work. If you have some great tutorials for this project, I would be glad if you could give me some links, or datas. 2: Where are the most complexity parts in this project? 3: How do I handle so many shifting registers?

I would be glad about any kinda help :). Best regards, idl0r P.S: It's a really important project for my friend and me. We're grateful about any help :).

You will need to know how to handle a matrix and refresh it. Have you read this:- You have an array or area of memory that represents the LEDs and your refresh routine puts this out.

Then the game element is simply to program the bits in the array to represent your snake. This separates the hardware talking code from the game element of the code.

Good luck.

Hey Grumpy_Mike, thanks for your fast answer. Do you have maybe a Source-Code example which has used such a 2 dimnesional array to control a Matrix? I hope I understood the part with the array from your page, it is a 2 dimensional array, isnt it? Thanks for your help, idle

There is no need to have a two dimensional array if you only need on / off information. Each byte can represent 8 LEDs with one bit a piece. Then if you have an 8 by 8 matrix you only need a one dimensional array of 8 bytes to define the memory for all the LEDs. Even a 16 by 16 matrix can be defined by a one dimensional int array of 16 values.

Sorry I don't have any examples that are easy to follow. My monome projects use this technique but I would not recommend you look at that because all it does is set bits in response to external commands.

However, this is the technique that virtually everyone uses.