Saturday, June 18, 2016

3D-Printed Robotic Arm Using Hobby Servos

I designed and built the following robotic arm using 3D-printed parts and hobby servos.


Here is more info on the build:
  • Designed the plastic parts using Onshape and 3D-printed them on a Makergear M2.
  • Using a large ball bearing for the base, four standard and two hobby servos for motion, and metal servo horns where available for coupling the servos. 
  • An Arduino Uno drives the hobby servos. An external power supply is used for the servos. 
  • Arduino is connected to a laptop and talks to a Python program over serial.
  • Implemented three control modes:
    • Manual mode using the keyboard to issue commands.
    • Manual mode using a third-party Android app ("Bluetooth Serial Controller") that talks to the Python program over Bluetooth to issue commands. 
    • Replay mode, where the list of instructions recorded in the other modes are replayed to control the arm.
  • Implemented the following controls for both manual modes:
    • UP/DOWN: Moves the gripper up/down vertically with minimal change in the horizontal positioning of the tip of the gripper.
    • IN/OUT: Moves the gripper in/out horizontally with minimal change in the vertical positioning of the tip of the gripper.
    • LFT/RGT: Moves the base left/right.
    • GRB/REL: Grabs/releases an object.
    • WUP/WDN: Moves the wrist up/down.
    • WLT/WRT: Rotates the wrist left/right.
Here's a demo of a task that consists of stacking three plastic cups. In all of the videos below the same task is performed. All videos are played at 1X speed. Note the improvement in speed in each iteration.
  • In the initial iteration the task is performed manually, using the Android app. This is the slowest iteration. The steps are saved in a file to be replayed later.
  • The second iteration performs the task automatically in replay mode using the generated file in the earlier step. Replay mode eliminates the random pauses in the manual mode. Note the shorter time needed for completing the task.
  • In the third iteration, I manually edited the replay file to eliminate unnecessary steps. For example if rotating the wrist involved multiple steps, I removed all but the last instruction in the sequence. I also increased the magnitude of the grip where the cup would not stay in place due to sudden moves. These optimizations were rather basic and performed manually. With more work further optimizations should be possible. Note the additional speed improvement over the previous iteration.

With these out of the way, I will go ahead and wrap up this project for now. It is time to move on to other projects and I would like to revisit drones ...