Hello All,

This is my first post and I am happy to be using Arduino!!!

I recently built an 8x8x8 rgb led cube. Well almost done, I have two 8x8 towers going and I am having some fun turning independent LEDs on and off. Now I am trying to write some more advanced graphic routines to turn on more then single LEDs. For example lines and circles. I just can’t seem to get the line rountine to work. Any help would be appreciated.

// set all the points on a line to a color

void Line(float xa, float ya, float za, float xb, float yb, float zb, int color)

{

float x,y,z;

// calculate the legnth

float xl = xa-xb;

float yl = ya-yb;

float zl = za-zb;

for (float t=0; t<8.0f; t++)

{

x = xa + ((xl/8.0f) * t);

y = ya + ((yl/8.0f) * t);

z = za + ((zl/8.0f) * t);

Point(x,y,z,6);

}

}