3D POV Display Problems

hey guys, new to the forum but been lurking around here a while. I'm not sure if this is the right place to ask, but any help would be appreciated

I'm trying to make my own 3 dimensional POV display, much like the one pictured here: Arduino Forum
My project is a little less polished though, and I have a couple problems that i've been trying to puzzle out, but cant seem to get working. I am currently using a DC motor powered by 4 nine-volt batteries in a series-parallel setup to deliver 18V at twice the current. The motor is rated at 18V so this is not a problem, but as I am using batteries the motor slows down quickly as it drains the batteries, and it doesnt spin at a constant RPM. I'm not sure how to fix this, though a friend said using an AC to DC power supply might help. so far the only ones i've been able to find are for laptops though.

The second problem is somewhat related to the first. I think i'm in over my head a little bit on the programming side, and I'm having trouble figuring out how to display anything. i got a cylinder working on the display, but that was just lighting the outside and inside LEDS and turning on the motor. For anyone whos wondering, I have five rows of 8 LEDS each controlled with a matrix set up.

Again, any help would be appreciated. I've included below some code that I was trying to make look like what you see here: 3D FAN.mp4 - YouTube

int c1 = 0;
int c2 = 1;
int c3 = 2;
int c4 = 3;
int c5 = 4;
int c6 = 5;
int c7 = 6;
int c8 = 7;
int r1 = 8;
int r2 = 9;
int r3 = 10;
int r4 = 11;
int r5 = 12;


void setup() {                
  pinMode(c1, OUTPUT);
  pinMode(c2, OUTPUT);     
  pinMode(c3, OUTPUT);     
  pinMode(c3, OUTPUT);     
  pinMode(c4, OUTPUT);     
  pinMode(c5, OUTPUT);     
  pinMode(c6, OUTPUT);     
  pinMode(c7, OUTPUT);     
  pinMode(c8, OUTPUT);     
  pinMode(r1, OUTPUT);     
  pinMode(r2, OUTPUT);     
  pinMode(r3, OUTPUT);     
  pinMode(r4, OUTPUT);
  pinMode(r5, OUTPUT);
       
}


void loop() {
  digitalWrite(c1, HIGH);
  digitalWrite(c2, HIGH);
  digitalWrite(c3, HIGH);
  digitalWrite(c4, HIGH);
  digitalWrite(c5, HIGH);
  digitalWrite(c6, HIGH);
  digitalWrite(c7, HIGH);
  digitalWrite(c8, HIGH);
  digitalWrite(r1, LOW);
  digitalWrite(r2, LOW);
  digitalWrite(r3, LOW);
  digitalWrite(r4, LOW);
  digitalWrite(r5, LOW);
  delayMicroseconds(50);
 
  digitalWrite(c1, HIGH);
  digitalWrite(c2, HIGH);
  digitalWrite(c3, LOW);
  digitalWrite(c4, LOW);
  digitalWrite(c5, LOW);
  digitalWrite(c6, LOW);
  digitalWrite(c7, HIGH);
  digitalWrite(c8, HIGH);
  digitalWrite(r1, LOW);
  digitalWrite(r2, LOW);
  digitalWrite(r3, LOW);
  digitalWrite(r4, LOW);
  digitalWrite(r5, LOW);
  delay(20);  
  
  digitalWrite(c1, HIGH);
  digitalWrite(c2, HIGH);
  digitalWrite(c3, HIGH);
  digitalWrite(c4, HIGH);
  digitalWrite(c5, HIGH);
  digitalWrite(c6, HIGH);
  digitalWrite(c7, HIGH);
  digitalWrite(c8, HIGH);
  digitalWrite(r1, LOW);
  digitalWrite(r2, LOW);
  digitalWrite(r3, LOW);
  digitalWrite(r4, LOW);
  digitalWrite(r5, LOW);
  delayMicroseconds(50);
  
  digitalWrite(c1, LOW);
  digitalWrite(c2, LOW);
  digitalWrite(c3, LOW);
  digitalWrite(c4, LOW);
  digitalWrite(c5, LOW);
  digitalWrite(c6, LOW);
  digitalWrite(c7, LOW);
  digitalWrite(c8, LOW);
  digitalWrite(r1, LOW);
  digitalWrite(r2, LOW);
  digitalWrite(r3, LOW);
  digitalWrite(r4, LOW);
  digitalWrite(r5, LOW);
  delay(35);
  
  
}

4 nine-volt batteries in a series-parallel setup to deliver 18V at twice the current.

It is a bad idea to connect batteries in parallel because they discharge / charge each other. Better to isolate them with a diode.
Yes batteries run down quickly with motors a mains power supply is a much better option.

As to the display. You need a trigger to synchronize the display on every rotation. When you see that you just flash the LEDs in the pattern you want.

Like my simple project here:-

thanks for the help about the batteries.

I have one of these left over from a previous project: Hall-Effect Sensor - US1881 (Latching) - COM-09312 - SparkFun Electronics

If i had two magnets at opposite ends of the rotation to latch/unlatch the sensor, would it be fast enough to work as a sensor to synchronize the image?

katarn:
If i had two magnets at opposite ends of the rotation to latch/unlatch the sensor, would it be fast enough to work as a sensor to synchronize the image?

I would have thought so yes.