Friday, December 12, 2014










Project Conclusion

During our last team meeting before the Design Expo, we worked to finalize the code to run the motors and the IR sensor. We were unable to create a code that would make the motors that run the drivetrain move. From the research that we did, the most likely reason for the motors not functioning was that it is difficult to make stepper motors step at the same time, because stepping is considered a "blocking function".

Though the motors weren't going to function properly, we did move forward with modifications to the body of the tank to allow for the motors to fit into the central compartment. After acquiring the 3D printed drive shafts from Professor Sullivan and the gears we needed from K'nex, we could move forward on the final construction of the drivetrain.


When I had the acrylic bulkheads laser cut, I had been unsure what motors we would end up being able to use. for this reason I didn't laser cut the mounting holes for the motors. When I was ready to drill the holes for the motors I went to the machine shop to ask for help drilling the holes, but upon arrival i was informed that the shop was closed all day and the machinists all had meetings so there would be no machining done today. Being stuck without mounting holes on the day before the Design Expo, I decided to take a chance and see if the maintenance shop would be able to help me. I explained what I was doing, and that the machine shops were all closed, and they were willing to help me. It wasn't until I was almost entirely done with the construction of the drivetrain, that I realized that the motors would not be able to be attached because the holes were slightly off from where they were supposed to be. I knew there was a chance the holes wouldn't end up lining up because the tolerances of the holes on the motor are so low, and the drill bit we needed to use was so small, it would flex due to the rotation of the chuck.

Given the opportunity, I would avoid making the drive shafts out of 3D print material in the future. Instead I would look into milling out the shape of the axle and built in gears on a lathe and then using a drill press and a circular vice to mill out the teeth on the gears. Then I would drill out the hole for the motor shaft to be press fit into the drive shafts. I would make this change because one of the 3D print shafts slip in half during drivetrain construction, before we were able to put any force from the motor onto it.

Tough this has only been one prototype project, I feel like we have gone through six or seven prototypes in order to get to where we have now.





























































We are attaching LED's to the front of the tank. The code that will make the LED's flash is;

int led0 = 8;
int led1 = 9;
int led2 = 10;
int led3 = 11;
int led4 = 12;
int led5 = 13;

void setup() {

pinMode(led0, OUTPUT) ;
pinMode(led1, OUTPUT) ;
pinMode(led2, OUTPUT) ;
pinMode(led3, OUTPUT) ;
pinMode(led4, OUTPUT) ;
pinMode(led5, OUTPUT) ;
}


void loop()  {

digitalWrite(led0, HIGH) ;
delay(50) ;
digitalWrite(led0, LOW) ;
delay(100) ;

digitalWrite(led1, HIGH) ;
delay(50) ;
digitalWrite(led1, LOW) ;
delay(100) ;

digitalWrite(led2, HIGH) ;
delay(50) ;
digitalWrite(led2, LOW) ;
delay(100) ;

digitalWrite(led3, HIGH) ;
delay(50) ;
digitalWrite(led3, LOW) ;
delay(100) ;

digitalWrite(led4, HIGH) ;
delay(50) ;
digitalWrite(led4, LOW) ;
delay(100) ;

digitalWrite(led5, HIGH) ;
delay(50) ;
digitalWrite(led5, LOW) ;
delay(100) ;

digitalWrite(led4, HIGH) ;
delay(50) ;
digitalWrite(led4, LOW) ;
delay(100) ;

digitalWrite(led3, HIGH) ;
delay(50) ;
digitalWrite(led3, LOW) ;
delay(100) ;

digitalWrite(led2, HIGH) ;
delay(50) ;
digitalWrite(led2, LOW) ;
delay(100) ;

digitalWrite(led1, HIGH) ;
delay(50) ;
digitalWrite(led1, LOW) ;
delay(100) ;

}

Thursday, December 11, 2014

Today we are putting all the pieces together. We have properly attached a KeyesIR sensor to our tank and we have successfully detected output signals from the sensor if an object is placed 15 cm in front of it. If an object is detected in front of the tank the sensor will sent an output signal to the motor shield. The signal is then used as an input for the stepper motor code which tells the tank to turn or not. The tank is programed to turn to the right, only,  if an object is detected and will continue to turn until the sensor stops sending a signal saying somethings in front of it. here is the code:

int leftmotor = 1;
int rightmotor = 2;
int sensor = A0;

void setup()
{
  pinMode(A0, INPUT);
  pinMode(1,OUTPUT);
  pinMode(2,OUTPUT);
  
}

void right()
{
  digitalWrite(leftmotor, HIGH);
  digitalWrite(rightmotor, LOW);
}

void straight()
{
  digitalWrite(leftmotor, HIGH);
  digitalWrite(rightmotor, HIGH);
}

void loop()
{
  digitalWrite(13, HIGH);
  delay(1000);
  digitalWrite(13, LOW);
  if( analogRead(1))
  {
    straight();
  }
  else if( analogRead(0))
  {
    right();
  }
}

Wednesday, December 10, 2014

Tomorrow is the last day before the design expo. In the past few days we have gotten a motorshield and two stepper motors. Due to the extra weight the drivetrain added on the outside of the tank body, I have laser cut a support bracket to stop the separation of the body panels. Today Kevin and I went to the lab and have arranged to have the drive shafts 3d printed. Kevin received the sensor in the mail today, and has written the code for the operation of the tank. The final parts that we're waiting on, the gears to support the tank tracks, arrived at an East Boston sorting facility late this evening. If all goes as planned, we will have the drivetrain built, the code completed, and the body panels back in place by early tomorrow evening. We plan to meet as a group tomorrow to make the sprint towards the final project deadline.

Wednesday, December 3, 2014


I received the completed prototype drivetrain files from Kevin today. I then used the dimensions of the K'Nex as a starting point for the design of the acrylic bulkheads.

Fully constructed tank body






Sunday, November 23, 2014

Foam Core Body and K'Nex Drivetrain







I would like to prototype the drivetrain with K'Nex pieces, but then I would like to use the K'Nex dimensions to laser cut solid acrylic side plates to support the drivetrain. A K'Nex track system would still be used but solid acrylic side plates would replace the K'Nex supports. 

Monday, November 17, 2014

The materials required to make the vehicle we desire are:
  1. 3 arduino kits
  2. Three motors
  3. 8 wheels of equal diameter
  4. Arduino object sensor
  5. A strong plastic/wood base
These are the materials that are required for our design as of now but it is subject to change as we continue into the building process.