loading

This is a very basic robotic system with 2 degrees of freedom (two movable joints). Its two servos can rotate by 180 degrees, just like your elbows and knees. The robotic arm has a capacity to reach any point in its radius and so it can be used to sweep the space around it

Components:

3D printed arm parts: base, mid section and bat (attached here)

Arduino

Servo Shield

2 Metal Gear Servos (I used MG 90)

Rainbow cable

Step 1: Connect Shield and Servos

Place the shield onto the Arduino , it should plug in without any force.

Plug the two servos into the shield mid section (use pins 9 and 10). If necessary use a rainbow cable as an extension chord for one of the servos

Step 2: Plug the 2 Servos Into the Mid-Section

Place the two servos into the slots of the servo holder. You may need to file the slot to make the servo fit!

Step 3: Screw in Servo Bracket

Align the bracket with the slot on the bat and secure with the screw provided (or hot glue if no screw available!) Secure both brackets, one to the base, the other to the bat

Step 4: Secure Base to Table and Upload Code

After you secured the base to the table, you can try uploading some code

The video shows my first try using just a nested loop and one variable (see code below)

#include
Servo servo1; // Define near servo

Servo servo2; // Define far servo


void setup() {

servo1.attach(9); // Set near servo to digital pin 10

servo2.attach(10); // Set far servo to digital pin 9 }

void loop(){ for(int i = 1; i <91; i++){

servo1.write(i);

servo2.write(90-i);

}

}

Step 5: Ultrasonic Control!

Upload attached program into the arduino and control the arm through the Ultrasonic Sensor

<p>Really cool! Thanks for sharing! </p>

About This Instructable

1,813views

22favorites

License:

Bio: I am robotics engineer and a teacher whose passion in life is breaking down the maths and academic jargon of programming and robotics into something ... More »
More by Robotix_au:Memory Trainer in Python LIGHT SABRE GAME in Sratch Button LED Input/Output Circuit 
Add instructable to: