Algorithm for led cube

Discussion in 'Programmer's Corner' started by elimenohpee, Mar 10, 2009.

  1. elimenohpee

    Thread Starter Active Member

    Oct 26, 2008

    This is what I plan to make, on a much smaller scale, maybe a 3x3x3 to start with. My question is I'm having trouble coming up with a really effective algorithm to go about processing cool animations. For the 3x3x3 cube I'm going to build, its only going to require 12 i/o pins, 9 for each column and each row's ground. So basically I ground 1 row and light a specific row, and an led lights.

    So my question how should I go about attacking this. I'm going to be writing the code in C, and I haven't had a lot of programming experience, just a couple college level classes. I was thinking of maybe mapping out somehow which pins will be active and which will be low, throwing that into an array, and then having some kind of loop to filter through each entry and make each individual pin active.

    Any ideas, hints, or tips? Thanks!