close
KnowledgeBase

Controlling 4DOF Robotic Arm Claw Kit with 16 channel PWM/Servo Shield using analog input.

Overview

This Robotic Arm Claw kit is an Arduino based system which comes with 4 degrees of freedom. This project aims to interface an Arduino Uno with a 16 channel PWM/Servo shield and using potentiometer to control the Robotic arm movements. The shield uses I2C Communication.

Hardware Used

Software Used

Library used

Hardware Set-up

We are using the 16 channel 12-bits PWM servo shield.

The 16-Channel 12-bit PWM/Servo Driver Shield will drive up to 16 servos over I2C with only 2 pins. The on-board PWM controller will drive all 16 channels simultaneously with no additional Arduino processing overhead.

Up to 16 servos can be attached to one board. If you need to control more than 16 servos, additional boards can be stacked.

What is PWM?

Pulse Width Modulation, or PWM, is a technique for getting analog results with digital means. Digital control is used to create a square wave, a signal switched between on and off. This on-off pattern can simulate voltages in between full on (5 Volts) and off (0 Volts) by changing the portion of the time the signal is in the ON state versus the time that the signal is in the OFF state. The duration of “ON time” is called the pulse width. To get varying analog values, you change, or modulate, the pulse width.

Here are the steps on how to assemble your Robotic arm kit:

Remove the components protection paper and Arrange according to its uses.

In preparing the base use

4 x M3 nuts

4 x M3 * 30 mm screws

Fasten the 4 pieces M3*30mm screws and nuts to secure the base

Attach the 4 pieces M3*10mm screws and nuts to secure your Arduino uno board.

This is now your Base must look like

Use the ff:
2 pieces M3*8mm screw
Black servo rack
Black servo holder

Mount the servo through the holder and carefully pull the wires so that the servo will fit.

Now attach the servo rack to the servo and screw both side from the servo holder.

This is now how it looks like.

Now mount your servo as this serves as your base.

Prepare these items to build Forearm of the Robot use the M3*8mm screws.

Mount the base and the bracket then screw both side to secure the servo.

Attach the horn in the main acrylic arm using the M2.5 taping screw.

Attach the arm to the servo and secure it with self- tapping screw that is included in the servo package.

Note: Make sure to calibrate the arm properly or else a problem may occur later as you continue.

Using the M2.5 tapping screw Attach the servo horn to the acrylic arm joint.

Use the 2 M3*8mm screw to build the other forearm of the robot and use M3*6 attach the long Acrylic arm to the arm joint as shown in the image.

NOTE: Make sure to calibrate properly the arm to avoid problems later on.

Use 2 tapping screw and attach the servo horn into the servo rack base.

Connect the two joints using the M3*8mm screw. Do not over tighten the screw so that it can rotate freely.

Now attach the two Acrylic clapboard in the corresponding wing slot.

attach the two active joints in the corresponding slot as well as the rack base and secure both side using the 4 M3*10mm screw

Attach the backbone between the forearm and the main arm of the robot using 2 M3*10mm screw and secure it on both side.

Use the long acrylic arm as well as the M3*6mm screw and screw it on the bottom right side

It should look like this.

Then use the another long acrylic arm with three active joints using M3*8mm screw and connect it to the two forearm joints.

use the ff:
2 M3*8mm screw
1 Black Circular spacer
1 Black Support arm
1 Black Triangle support connector

Fix the screw as shown in the first image where the spacer is also attached in between.


Then fix the other end of the support arm. as you can see there is still has three free dangling ends which are eventually connected to secure the claw part.

To assemble the claw use ff:
2 square brackets
4 M3*8mm screw
2 connector accessories

Place the square bracket in the bottom and pull the cables out as required to connect to Robot Extension Board.

Now place the rectangle bracket on the top of the Servo and secure the Servo with four M3*8mm screws.

Fix the two claws on the rectangle servo bracket with two M3*6mm screws.

use the ff:
4 M3*8mm screw
1 short connector
1 circular spacer

Secure it on the left-hand side of the claw as shown on the left.

Remember to put the spacer in between

Prepare the following to connect Claw and Triangle support connector:
      Two M3*8mm screws
      One spacer
     One support arm

Then secure the Support arm into the Triangle connector.

Then the entire Claw part can be secured with the three free dangling Forearm ends

Prepare the tapping screw in the Servo package and servo horn.

Secure the horn with tapping screw as shown on image.

Pull the claws widely open and then insert the short arm we created in the last step and screw it firmly.

This now the final output of our Robotic arm .

NOTE:
Make sure that the screws are not over tightened so that the joints can move freely and the holes of the joints will not worn out.

Schematic Diagram

The battery represents the external power supply. You can use any external 5-6V power supply: (1) adjustable power supply, (2) switched mode power supply, or (3) 4- AA battery.
This is the actual circuit.
NOTE : An External power of 5V is required for the servo shield.

Code

This is the code for the entire system.

This calls the library for I2C which is the Wire.h and for the PWM servo driver which is  Adafruit_PWMServoDriver.h.

This function can be used to adjust the PWM frequency, which determines how many full ‘pulses’ per second are generated by the IC.

 

The setPWM function sets the start (transition from OFF to ON) and end (transition from ON to OFF) of the HIGH state of the PWM pulse on a specific channel.  You specify the ‘tick’ value between 0 to 4095 when the signal will turn on, and when it will turn off.  servo1 indicates which of the 16 PWM outputs should be updated with the new values.

The video shows the robotic arm lifting and moving around small objects.

Conclusion

The system is not limited to what is described above as it only illustrates basic functionality using analog input. You can always change and improve with your desired output. You can even add additional sensors or wireless/remote control to make the robotic arm kit even more interesting.

References

Tags : 16 channel 12-bit PWM Servo Shieldarduinoarduino unoi2cPWMrobot armRobotic arm Claw Kit 4DOFroboticsservo

Leave a Response


Warning: Cannot assign an empty string to a string offset in /home/createl1/public_html/community/wp-includes/class.wp-scripts.php on line 454

Warning: Cannot assign an empty string to a string offset in /home/createl1/public_html/community/wp-includes/class.wp-scripts.php on line 454