Thursday, December 12, 2013

Teamwork

As the project nears its close, it is as good a time as any to give credit where credit is due, to acknowledge the work of the individual members.

Evan Brown worked on research, SolidWorks modeling, contributed the gears and battery, helped construct the motor mount and legs, wrote blog posts and edited the final paper.

Benjamin Johnson worked on research, SolidWorks modeling, constructed the frame, wrote blog posts and wrote the final paper.

Forrest Otsuka worked on research, SolidWorks modeling, contributed the Lego bricks and axles, as well as the tools, helped construct the overall robot, wrote the code and wrote blog posts.

And THANK YOU, Professor Daniel Sullivan, who provided instruction on SolidWorks and Arduino, and kindly 3D printed the parts for the leg assemblies and provided the continuous servo for the project.

The DL

Here are some photos dictating the biology of our crab.




The crab has a very simple circuit, utilizing only pins 9-11 and A0-A2, along with the 5V and GND power pins. The photo-sensor is connected to pin A2, and detects the brightness of the environment. The value for the brightness is directly translated into a speed and direction for the servo, connected at pin A0, to rotate.

 


The RGB LED eyes (A and B) light up when the Arduino board is connected to a power supply, and the LEDs change color depending on the brightness to indicate which direction the crab is moving. When the crab is moving left, the LED eyes are green. When the crab is moving right, the LED eyes are blue.The flex sensor (C) was originally incorporated to provide a method to stop the servo to remove the power supply easier, but it was quickly determined that a kill switch (shown below) would be a much simpler method, especially in terms of coding.










 

There are two gear trains in the interior of the crab, one at the front and one at the back. On each of the gear trains are two end gears, and each end gear (for example, D or E) is attached to two leg linkages by an axle to rotate the legs around a fixed point. The fixed point for the crab is an axle (F) that runs through all four legs on either side of the crab. The front and back gear trains are connected with an axle (H) to ensure they run at the same speed.



In order to prevent the wires to get tangled in the legs, a short frame (I) had to be constructed on the undercarriage to hold the wires in place. The undercarriage itself is held in place via pins, which can be observed much clearer at the top of the image below.



The continuous servo (K) is the crab's only mechanical power supply. It is mounted at the bottom of the crab, and the servo arm is attached to a 40-tooth gear (J) which drives the gear train that rotates the leg linkages. The top 36-tooth gear (J) provides structural support, but it also allowed easy access for calibrating the legs during construction before the servo was engaged.

A Crabby Code

The above code controls the crab. It is a very simple code with only two sections. The first section calibrates the photo-sensor to map its output values between the lowest and highest light values it has detected. The second section takes the output values from the photo-sensor and translates them to speed and direction for the servo and color for the RGB LED.

Tuesday, December 3, 2013

Final Week

We have finished designing the body of the crab, small adjustments such as dremel shaving will be made to accommodate for fitting the legs which have been 3D printed. The Arduino code has also been produced and finalized. All that's left is assembly of the legs and mounting the Arduino board.



Having Github probs, code will not be up till later