Overall, we believe this project was fairly successful. There were a few bumps in the road, but ultimately our car did what we wanted it to do. The turret was able to swivel around and move up and down as intended. We did not end up attaching a firing gun but managed to wire the lights up through the cardboard gun to the tip and through the arduino causing the lights to have alternating flashing when the button was pressed. The button on the controller that affected the car remotely stopped working after a few re-wirings so the final product did not have that function, rather there was a button on the car that caused flashing lights. Initially, the button was working when we attached a motor to the circuit, but when we attempted to connect the lights, the button would not turn them on. The car could be driven around with a remote that was different than the one used to control the turret. We were able to drive it around the expo and aim it at people, which was fun until we inevitably crashed it. We modeled most of the components in solid works and 3D printed and laser cut some parts, but ended up making some components by hand.
There were a few things we would change if we were to move forward in the design process. The major problem we encountered when running our model was that the wheel that rotated the turret kept slipping out of the rut we made. Thus, instead of having a wheel rotating in a rut here are a few other solutions, we could either add more cardboard rings to increase the surface contact the wheel had with the rut, we could add a lip on the rut so the wheel would not slip out, or (and we believe this is the best option) we could have replaced the wheel with a gear and turn the rut into a gear as well. This way all of the parts would rotate without slipping out.
As noted earlier, on the whole, this project was a success. Although there were some issues along the way, this is ultimately a prototype, and we are aware of the problems that need to be fixed. If we were to (and we may) keep working on it these problems would/will be addressed.
Friday, December 12, 2014
Video of How Arduino Will be Implemented
This video shows how we intend to use the Arduino. When the button is pushed on the Arduino, the two leds blink back and forth. When the button is not pushed, the lights do not blink. We intend to put these lights on the tip of the gun and have them blink back and forth when the button is pushed on the controller.
Work Accomplished on 12/11
Below are a few pictures of the work we accomplished yesterday. We decided to upgrade our original cardboard circle that created the surface for the wheel to turn our entire assembly. We laser cut a new circle out of reinforced cardboard to add some stability. We also laser cut a clean cut outline of a gun. The pictures below show Joe and Rasaq assembling all of the new parts and the other picture shows all of these parts assembled before we reattached it to the car.
Arduino Code and Explaination
Here is the Arduino code we are using in our project:
int led1 = 9;
int led2 = 10;
int button = 2;
int dash = 100;
boolean buttonState = 1;
void setup(){
pinMode(led1, OUTPUT);
pinMode(led2, OUTPUT);
digitalWrite(led1, LOW);
digitalWrite(led2, LOW);
pinMode(button, INPUT_PULLUP);
Serial.begin(9600);
}
void loop(){
boolean buttonState = digitalRead(button);
if(buttonState == 0){
digitalWrite(led1, HIGH);
delay(dash);
digitalWrite(led1, LOW);
digitalWrite(led2, HIGH);
delay(dash);
digitalWrite(led2, LOW);
}
}
The goal of this code is to have two led lights blinking alternatively back and forth when a button on the controller is pressed. The lights will be located at the tip of the gun located on the car. We felt this is a safer option opposed to shooting bbs out of an air soft gun.
The code works by reading a signal from a pin located on one of the circuit boards and using that as an input on the arduino board (the input is the button, in this case). The code then confirms if the button is being pushed or not. If it is pushed, the lights on the tip of the gun light up. If, however, the code registers that the button is not pushed, the circuit (that we have created) is not completed and thus no current flows through the lights and they do not light up.
int led1 = 9;
int led2 = 10;
int button = 2;
int dash = 100;
boolean buttonState = 1;
void setup(){
pinMode(led1, OUTPUT);
pinMode(led2, OUTPUT);
digitalWrite(led1, LOW);
digitalWrite(led2, LOW);
pinMode(button, INPUT_PULLUP);
Serial.begin(9600);
}
void loop(){
boolean buttonState = digitalRead(button);
if(buttonState == 0){
digitalWrite(led1, HIGH);
delay(dash);
digitalWrite(led1, LOW);
digitalWrite(led2, HIGH);
delay(dash);
digitalWrite(led2, LOW);
}
}
The goal of this code is to have two led lights blinking alternatively back and forth when a button on the controller is pressed. The lights will be located at the tip of the gun located on the car. We felt this is a safer option opposed to shooting bbs out of an air soft gun.
The code works by reading a signal from a pin located on one of the circuit boards and using that as an input on the arduino board (the input is the button, in this case). The code then confirms if the button is being pushed or not. If it is pushed, the lights on the tip of the gun light up. If, however, the code registers that the button is not pushed, the circuit (that we have created) is not completed and thus no current flows through the lights and they do not light up.
Thursday, December 11, 2014
Today we met as a group and continued working on the project. We laser cut the base plate, ring, and a cardboard gun. The base plate and ring give the rotating turret something for the wheel that rotates it something to push off of and is essential to its functionality. The cardboard gun replaces the actual airsoft gun. We are trying to get lights to flash simulating firing from the controller but are having trouble with the circuitry. In theory it will work and it sort of does but something is not quite right. We are pretty close to being finished and we don't have much time to spare because the needed parts weren't acquired until very recently. I designed and will 3D print an emblem to attach to the front of the car, and its shown below. As far as fabrication goes this was obviously a prototype so it was not done to an exact science. It was much easier and faster to design and fabricate by hand as well as being way more versatile. Much of the design was done on the computer in solidworks files, but was redesigned or adjusted in the field. The gear ratios were designed to fit the gears that were available (ordered on amazon). Some of the components were made by hand out of cardboard and attached by a combination of nails, tape, and hot glue. It is rudimentary, but functions. If we were to continue on with this project, which I may, we would use the hand crafted parts as inspiration for clean cut computer generated parts. This is exactly how we came to use the base plate and ring pushing against a rotating wheel instead of a gear system for the rotation. Moving forward we will make as many improvements as we can before the expo on Friday(tomorrow in 12 hours).
As shared before here is a link to a fileshare of the solidworks files. http://ge.tt/5TMuul62/v/0?c
As shared before here is a link to a fileshare of the solidworks files. http://ge.tt/5TMuul62/v/0?c
Tuesday, December 9, 2014
Last night (Monday) around 8:00 I competed a viable finished product. I was finally able to get the gears from the mail room Monday morning and then began working on a gear box. The gearbox is shown up close below. I used nails and paperclips to hold them in place and the nails fit thru the holes very nicely. I decided it was not the best idea to have a realistic looking gun mounted on the car that actually shot bbs so I made this cardboard gun instead. The real reason is the motor was having trouble aiming it up and down with weight of the gun on it. I could have set up a counterweight system but I thought this was better for the above reason anyway. I made a solidworks design but I am clearly a tinkerer at heart because I abandoned the design and created a cardboard version from scratch. I ended up changing the rotating mechanism from gear based to a rotating wheel driving against a circle. Upon testing the final product works pretty well, both rotating and aiming up and down on a 27 Hz channel, as well as the car simultaneously driving on a 49 Hz channel. I am getting more parts from amazon wendsday and may or may not begin a whole new design. This one also doesn't incorporate the arduino in any way so I can add that even if i don't start the new project. I could incorporate the arduino by putting the 3rd remote channel I added into an input pin and making it light up lights in a pattern as a replacement for a firing mechanism on the air-soft gun.
Sunday, December 7, 2014
I was able to add a 3rd channel to an rc car remote for the firing mechanism today. I opened the controller and rc car and looked up the inputs and outputs for both chips on google. I also tested them with a motor and two wires before I realized the info would probably be online. There was a "turbo" input and output on the car I had. I connected a button to the turbo input pin and the battery on the controller, so when I pushed the button the chip would send the "turbo" signal out of the antenna for the reciever to pick up on. I then connected a transistor to the turbo out pin on the cars chip and to a motor and a battery. Now when I press the new button on the controller the 3rd (new) motor in the rc car turns. This will be connected to the air soft gun and used as a firing mechanism. Unfortunately there are still parts that won't be here until wendsday(dec 10) and not much more progress can be made until then. Its cutting it a little close but it will be a completed project by the 12th. Despite this success I realized were not even using the arduino so I bought an xbox reciever and a usb shield. Iv all ways thought It would be cool to control an rc robot with an xbox controller and now I can try. Have I bitten off more than I can chew in 2 days? we will see.
Thursday, November 13, 2014
This is today's progress. Its a complete assembly of the aiming fixture that will be mounted on top of our vehicle. Some of the dimensions will be adjusted when we get the other materials such as motors and measure them but the rest of it is ready.
The assembly and supporting components can be downloaded for viewing at http://ge.tt/3McfMm62/v/0?c
Tuesday, November 11, 2014
Monday, November 10, 2014
Today we met face to face for the first time as a group at the library. we decided on a project and began to talk about the logistics of it. We will make it mostly out of laser cut parts and parts of remote control cars. I (Joe) will make the laser drawings and Rasaq is going to find some other materials. We may meet this Thursday as needed. Below is a picture of the group and a sketch of a project idea. Basically we are going to attach a rotating gun turret to a remote control car.
Subscribe to:
Posts (Atom)