Friday, December 12, 2014

THE FINAL POST!


Finally, after weeks worth of excitement and fun we had making working this project, it has come to an end. Unfortunately the project didn't end up as we wanted it to be.

The Board and the LEDs (Assembly #2) which were suppose to go on top of the laser - cutted plate and 3D printed motor cylinder (Assembly #1), didn't end up as a stable assembly, the board was just too heavy for the cardboard plate which was originally supposed to be made out of 1/8inch acrylic. Due to the heavy weight and a small motor, when the board with the LEDs were placed on top of the plate, motor didn't move.

This was a partially successful project, we got two parts of the project working correctly but the assembly couldn't be complete because the entire object wasn't in a "static equilibrium."

Miscellaneous: -
The box was unable to be 3D printed, because of its design, and after we learned that the setup isn't in a static equilibrium we decided not to make the box.

To make this project working, we would like to do couple things : -

1) Make the motor cylinder, which handles the motor, better adjusted for the wiring thus it isn't bent (as seen in pictures before).
2) Use a better motor which is able to move the entire setup.
3) Use better material than cardboard for plate, which is more rigid.

Special thanks to Professor Sullivan and Jonathan helping us getting parts fabricated in time.

If you have any questions or suggestions for improvements, contact us at teamfrequency1@gmail.com 

Thank you

Team Frequency 


Assembly #2 Sparkfun RedBoard Setup

View of Circuit Setup for Assembly #2


This is the setup that is going to be used to light up the LEDs, the code is already posted. 

This following video shows how the LEDs are blinking.












The final, completed, tested Code!

/* Team Frequency Design Lab 1 Final POV Display final Code 12/12/2014 This code is designed to illuminate the LEDs on an arduino breadboard mounted on a rotating disc spinning at a known RPM. Ideally, the only variable that needs to be modified is the value of period, which represents the period of rotation of the disc. The delay values may also need to be modified slightly, or alternatively, the n value and corrosponding length of the lines of text in the message array may be increased to provide a longer delay if the message is repeating itself or illegibly compact. Requires a separate arduino running the motor attachment. */ //-----------------------Variable Declaration---------------------------------------------------- long period = 400; int ledPins[] = {13, 12, 11, 10, 9, 8, 7}; int n = 128; char *message[7] = { "11111111110001111111111000011111111100011111111110000000000000000000000000000000000000000000000000000000000000000000000000000000", "00001100000001100000000000111000000000000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000", "00001100000001111111000000011111111000000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000", "00001100000001100000000000000000011100000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000", "00001100000001111111111000111111111000000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000", "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" }; /* //This is an attempt to create the team name on the display. Will be completed if the display proves functional. char *messageB[6] = { "1111111111000111111111100000011110000001110000001110000000000000000111111111100011111110000001111111111000011111111000011000000001100011111111110001110000011000000111111100011100001110000000000", "000011000000011000000000000011001100000111110011111000000000000000011000000000001100001100 "000011000000011111110000000110000110000110011110011000000000000000011111110000001100011000 "000011000000011000000000001111111111000110001100011000000000000000011000000000001111110000 "000011000000011111111110001100000011000110000000011000000000000000011000000000001100011000 */ //--------------------------------Setup Function--------------------------------------- void setup() { for (int led = 0; led < 7; led ++) { pinMode(ledPins[led], OUTPUT); } } //--------------------------------Main Loop-------------------------------------------- void loop() { for (int col = 0; col < n; col++) // This code divides the char array message into columns using nested for-loops. { for (int row = 0; row < 7; row++) // The LEDs in each column light for 1/1000th of the period, shown by the delayMicrosecond(period) function, before turning off. { int value = (int)message[row][col]-'0'; if(value == 1){ setLed(row); } } delayMicroseconds(period); // The delay values may need to be adjusted if the timing of the system is too far off. Microseconds may be too short to effectively work. allOff(); delayMicroseconds(period / 16); } /*for( int x=0; x<7; x++){ setLed(x); delay(1000); } allOff(); delay(1000);*/ } //-----------------------------Additional Functions----------------------------------- void setLed(int led) { digitalWrite(ledPins[led], HIGH); // Turns on the LED chosen by the main loop. } void allOff() { for (int led = 0; led < 7; led ++) // Resets all LEDs to the LOW position after the delay. { digitalWrite(ledPins[led], LOW); } }

Thursday, December 11, 2014

Pretty close to the final code for the LED display!

This is an adaptation of the code that was posted on the blog earlier, that has been made to work for our setup. it should work for us, but it hasn't been tested yet and will need some minor tweaks.

/*
Team Frequency
Design Lab 1 Final
POV Display final Code
12/12/2014

This code is designed to illuminate the LEDs on an arduino breadboard mounted on a rotating disc spinning at a known RPM. Ideally, the
only variable that needs to be modified is the value of period, which represents the period of rotation of the disc. The delay values may
also need to be modified slightly, or alternatively, the n value and corrosponding length of the lines of text in the message array may be
increased to provide a longer delay if the message is repeating itself or illegibly compact. Requires a separate arduino running the motor
attachment.

*/

//-----------------------Variable Declaration----------------------------------------------------
long period = 400;
int ledPins[] = {12, 11, 10, 9, 8, 7};
int n = 128;
char *message[6] = {
"11111111110001111111111000011111111100011111111110000000000000000000000000000000000000000000000000000000000000000000000000000000",
"00001100000001100000000000111000000000000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"00001100000001111111000000011111111000000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"00001100000001100000000000000000011100000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"00001100000001111111111000111111111000000001100000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
};


/*
//This is an attempt to create the team name on the display. Will be completed if the display proves functional.

char *messageB[6] = {
"1111111111000111111111100000011110000001110000001110000000000000000111111111100011111110000001111111111000011111111000011000000001100011111111110001110000011000000111111100011100001110000000000",
"000011000000011000000000000011001100000111110011111000000000000000011000000000001100001100
"000011000000011111110000000110000110000110011110011000000000000000011111110000001100011000
"000011000000011000000000001111111111000110001100011000000000000000011000000000001111110000
"000011000000011111111110001100000011000110000000011000000000000000011000000000001100011000
*/

//--------------------------------Setup Function---------------------------------------
void setup()
{
 for (int led = 0; led < 6; led ++)
 {
   pinMode(ledPins[led], OUTPUT);
 }
}

//--------------------------------Main Loop--------------------------------------------

void loop()
{
  for (int col = 0; col < n; col++)                // This code divides the char array message into columns using nested for-loops.
  {
    for (int row = 0; row < 6; row++)              // The LEDs in each column light for 1/1000th of the period, shown by the delayMicrosecond(period) function, before turning off.
    {
      if(message[5-row][col] != 0){
        setLed(row);
      }
    }
    delayMicroseconds(period);                     // The delay values may need to be adjusted if the timing of the system is too far off. Microseconds may be too short to effectively work.
    allOff();
    delayMicroseconds(period / 16);
  }
}

//-----------------------------Additional Functions-----------------------------------

void setLed(int led)
{
 digitalWrite(ledPins[led], HIGH);                  // Turns on the LED chosen by the main loop.

}

void allOff()
{
   for (int led = 0; led < 6; led ++)                // Resets all LEDs to the LOW position after the delay.
 {
    digitalWrite(ledPins[led], LOW);
 }
}

Circuit Setup for Motor

Circuit Diagram



Key for the Circuit Pictures

This pictures from the SIK guide that came with the spark fun inventors kit, helped setup the circuit necessary for the motor to operate.

Priyank



Video! @60fps


This shows how the bottom section rotates, as you can also see it rotates on an angle which is a small problem and can be fixed by making the next part considering the fact that extra space needed for the motor. 

Priyank


Bottom Setup Complete



Priyank