Friday, May 11, 2012

Team E - Rambo

Main design concept
     Team Rambo based its design around the need to build a system that can fire Nerf Balls as consistently and quickly as possible. We decided to use pneumatics because of its high power, which would give a relatively linear trajectory, and the high consistency in firing accuracy. The cannon is equipped with a plastic piston, threaded into a high pressure hose that fires the balls at up to 100 psi. An aluminum tower holds the central pivot point about 7 inches off the turntable. The aluminum barrel is mounted to the acrylic baseplate with hose clamps and the piston has an aluminum clamp that connects it to the linear actuator. This actuator is connected to a three-way valve that exhausts the air in the line once the signal is stopped, thus allowing the piston to re-enter the barrel. The camera gathering the target information is mounted on the front at an 8 degree angle in order to see all of the target board. Figure 1 shows all of the components of our design.


Figure 1: Overall System Components


Team Rambo
David DeGerome-Control, Electronics
Isaac Marx-Machining, Mechanical Design
Neal Seegmiller- Programming, Computer Vision, CAD Design
Jessica Tiu- Software, Circuit Design

Subsystems
Loading System
     The main component of our loading system is an acrylic piston that seals the chamber when a ball is loaded into the barrel. The piston design functioned by pushing a ball forward and closing off the hopper hole, firing, and then retracting, allowing the next ball to drop in as shown in Figure 2.

 Figure 2: Piston retracting(top) and pushing a ball forward into firing position(bottom)

     Other components in the loading subsystem include a hopper, aluminum loading tube, rubber bands, and a 3-Way solenoid valve. The hopper of our loading system is a 22 oz. plastic cup, which is attached to an aluminum loading tube that can hold all 6 Nerf balls. The hopper has no actuators in it, relying on gravity to feed the balls. The rubber bands(B in Figure 3) help retract the piston to its resting position. The time it takes a ball to fall into the barrel from the loading tube is less than 1 second.

Figure 3: Ball Loading System: Piston(A[resting position]), Rubber Bands(B), Hoses and Clamps(C)

     In order to control the solenoids via our microcontroller, we had to create a switching mechanism because the microcontroller did not have the necessary voltage or current to activate the solenoids. We implemented the following circuit using transistors(Figure 4). This allowed us to output a 5V signal from the microcontroller to the transistor. This would “turn on” the transistor and allow 12V to pass to the solenoid. We placed a diode between the pins on the solenoid so that the back emf did not damage the microcontroller.
Figure 4: Solenoid System: Circuit Diagram
Firing System 
     The firing system consists of a 2-Way solenoid valve, barrel, and hoses and clamps(Figure 5).
Figure 5: Firing System: Barrel(A), 2-Way Solenoid Valve(B), Hose and Clamps(C)

     We use a ¾’’ hose as an expansion chamber to fire the ball. Initially, we used a smaller diameter hose and the firing power was lacking. We found that the bigger hose gave us sufficient power. The 2-Way solenoid valve activates and the compressed air releases out of the hose. Inside the barrel, we made a slight indent at the bottom in order to prevent the ball from rolling out when the barrel was pointed downwards. The complete pneumatic layout for both the loading and firing systems is below(Figure 6):
Figure 6: Pneumatic Layout of Firing(Left) and Loading(Right)

System Vision System
     Our original system design was to use a webcam(A on Figure 7) with the Gumstix microprocessor to analyze images and send via serial the positions of the targets to our microcontroller. We were unable to get the Gumstix to run our vision code, so we had to use a laptop in our final system. The laptop was able to read images from the webcam and send current positions of all 3 targets to the microcontroller.
Figure 7: Vision System: Webcam and Mount(A)

Azimuth and Elevation Aiming System
     In order to move the barrel to a desired position, we used 2 high torque motors that actuate the azimuth and elevation angles of our system(Figure 8 and 9 respectively).
Figure 8: Azimuth Rotation Motor

Figure 9: Elevation Rotation Motor(A) with Potentiometer(B), Turntable(C)

     The motors have dual output shaft, so we were able to mount a potentiometer(B on Figure 9) to each motor. These potentiometers are rated for ½ degree precision and a range of 90 degrees. The range of 90 degrees was sufficient for our task because the motors only had to move small angles to track targets on the entire range of the board. The azimuth motor is attached to a turntable(C on Figure 9), which rotates the entire tower. The barrel is rests on an acrylic platform that mounts to piece of aluminum attached to the elevation motor. The motors are powered by Carnegie Mellon motor driver boards which receives a PWM signal as input and outputs the corresponding voltage.

Software Architecture
     Our software architecture consists of two programs: track_targets is written in C++ using the OpenCV library and executes on a processor (e.g. a laptop). It simultaneously tracks all three target locations in webcam images, and converts these locations into azimuth/elevation angle commands. These are sent, along with other information, to the Arduino via serial communication in a 31 digit numerical string (explained in Table 1). multishot_cannon_controller executes on the Arduino. It receives input from all remaining sensors (potentiometers and switches) and controls the motors and valves of the cannon. Software communication is summarized by the flowchart in Figure 10. Note that, no communication from the Arduino to the computer vision program, track_targets, is required; only debugging messages are sent. The state of the cannon (including mode, current target, etc.) is fully managed by the Arduino and is unknown to track_targets.

Table 1: Explanation of numeric string sent to Arduino via Serial communication



Figure 10: Flowchart of software communication

 Video
 

No comments:

Post a Comment