Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Claw:
 We modified the built in servo code to run the servo that opened and closed the claw.  We determined that we needed to open the claw to 155 degrees for best use.  To start the code we opened the claw with a delay so that the operator could load the recyclable into the claw.  Then to claw closed and maintained the fully closed position to keep the recyclable in the claw.  Once the arm moved to the shooter loading position the claw opened and later closed to resume its initial position.

Arm:

The arm was coded to move to the loading position and back to the initial picking position once the bottle was unloaded.

Launcher: 

The motor for the launcher was the only motor ran with position control. Originally, we were not aware of the motor driver's ability to except the servo library code. We used the standard analogWrite() to define the motor speed and direction. For the encoder, a source code from http://www.hobbytronics.co.uk/arduino-tutorial6-rotary-encoder was modified to use the A channel signal to check every time the amplitude of the wave changed. The final revolution, or number of wave changes, to be set to produce the number of turns on the 50-tooth gear. The exact value for 2 full turns was not determined due to complications with motors, encoders, motor controllers and arduino. Thanks to the help of Dr. Deshpande's lab group who worked with us prior to the demonstration, we learned of the servo library and setting on the motor controller. Due to the simplicity of the code and a more precise '2.5 Volts', we chose to modify the code in the available time. 

Release:

The release motor was programmed to move in the reverse direction first to allow it to gain momentum while moving in the forward direction so that the required force to release the launcher was obtained.