Color Sorting Robotic Arm
Color Sorting Robotic Arm
Color Sorting Robotic Arm
A report submitted by
of
BACHELOR OF TECHNOLOGY
in
MECHANICAL ENGINEERING
NOVEMBER 2018
CERTIFICATE
This is to certify that a bonafide record of the design project work titled “Mini Project” done by
fulfillment of the requirement for the award of Degree of Bachelor of Technology in Mechanical
Dept. of ME Dept. of ME
MITS MITS
Place: Varikoli
Date: 26/11/2018
ACKNOWLEDGEMENT
Foremost, I would like to express my sincere gratitude to my project guide, Dr. Kurian Antony for
project work. I appreciate his sincere help in terms of patience, time and ideas so as to make my
My sincere gratitude to Dr. Manoj George, Head of Department during my course period 2018-19.
I would like to acknowledge management of Muthoot Institute of Technology & Science for
providing academic support to complete my course work project. In my daily work I have been
blessed with a friendly and cheerful group of fellow students. I am very much thankful to all the
members of my group.
I would like to express my sincere gratitude to the technical staff of CAD Laboratory, and all the
Besides this, several people have knowingly and unknowingly helped me in the successful
PRAVEEN PREMCHAND
ABSTRACT
Efficiency and automatization can be improved in several ways. The focus in this report has been
working with color identification and creating a smart robot. A simple robotic arm is used to apply the
color sorting to a physical system. This model evaluates how well a robotic arm can sort different
The proposed project is to separate the objects from a set according to their colour. This can be useful
to categories the objects which move on a conveyor. The proposed method of categorization is based
on colour of the object. In this project the system categories balls of six different colours. The detection
of the particular colour is done by a light intensity to frequency converter method. The robotic arm is
1
CONTENTS
1. INTRODUCTION ...................................................................................................................... 5
3. PROBLEM FORMULATION.................................................................................................. 11
6. CONCLUSION ......................................................................................................................... 22
2
TABLE OF FIGURES
3
LIST OF TABLES
4
1. INTRODUCTION
In the era of robotics and automation, all the industries are becoming automated for faster development
and growth. A robot is an electro-mechanical machine which reduces human efforts and increases
efficiency. It is a real time machine which completes its given tasks in given time, with the help of
computer programming. Our project presents the design and development of a robotic arm with the
application of color sorting of spherical objects. Basically the robotic arm is programmed to pick the
spherical object from one place and drop accordingly into the respective colored box.
Here, the color sensor is used to sense the color of the object to be picked and dropped, and the voltage
i.e. the intensity of the color sensed is converted into frequency which is given as input to the
microcontroller. The microcontroller enables motor driver circuit which drives the motors of the
robotic arm to grip the objects and drop them in the specified location according to the color. It reduces
the human effort, labour and cost. It also increases the efficiency since the mechanised sorting is much
An ATmega328P based microcontroller Arduino UNO, is programmed to control the robotic arm. The
TCS3200 light intensity-to-frequency converter senses the colour and produce a square wave with
Four DC servo motors are used in the construction of the robotic arm. The arm of the robot is
constructed using aluminum brackets. Four types of brackets are designed for this purpose, two types
for holding the servos and two types for length extension and interconnections. The ball picking gripper
5
1.3. Motivations & Objectives
Repetitive tasks and high accuracy have become the two contradictory needs of any industrial process.
By introducing autonomous robotic applications, simple repetitive tasks can be accomplished keeping
the demands of the accuracy and speed in mind. Nowadays in this fast growing industrial age every
company needs speed in manufacturing to cope up with the customer’s requirements. For sorting object
in industry optical sorting is very much convenient. Color and size are the most important features for
accurate classification and sorting of product which can be done by using some optical sensors or
analyzing their pictures. Nowadays, in the present state of intense competition, production efficiency
is generally regarded as the key of success. Production efficiency includes the speed at which
production equipment and production line can be lowering material and labor cost of the product,
improving quality and lowering rejects, minimizing downtime of production equipment and low
cost production equipment. Taking this matter. The objective of the paper is to separate the objects
from a set according to their color. This can be used in an industry where the objects moving through
a conveyor belt can be categorized using a color identifying robot. Under consideration the project is
developed which is very useful for industries. The robotic arm has a gripper to hold the object. On
analyzing with the color of the object with the help of color sensing module (tcs230), the object will
be placed in designated location. This process will be repeated and continued till all the materials are
sorted by color.
The working model of the project is divided in to different sections like detection, control section,
mechanical assembly and working. Different mechanisms can be used for detection of the object. For
the final run of the project the colour based detection has been selected. Since the optical sensors are
used without much processing of the input data the sensing is done at a faster rate. The colour sensor
itself provide direct signal to the microcontroller after detecting the object. The main operation of the
microcontroller is limited to servo motor control and the overall response is expected to be better. The
6
TowerPro SG90 Servo is used as DC servo motors. The drivers are fast enough to deliver the pulses
7
2. CASE STUDY
2.1. Product 1:
Functionality
The project deals with the designing and implementation of Synchronized Robotic Arm, which
is used to perform all the basic activities like picking up objects and placing them. In this project, a
robotic arm is designed, synchronized with the working arm and would perform the task as the working
arm does. The work done by the robotic arm would be highly precise, as a digital servo motor is used.
A servo motor of 230 oz-inch is used in the project, but motors with more capacity can also be used as
according to the desired work. This robotic arm can also be used for precision works. For instance
some work has to be done very precisely but the conditions do not suit human beings. In such
conditions, this robotic arm can be used remotely and the task can be accomplished. The programming
is done on ATMEGA-8 Microcontroller using Arduino programming. The potentiometers are also
used to detect the angle of rotation and the signals are then sent to the microcontroller. In
today’s world, this Robotic arm has turned out very benevolent. Besides Robotics and Automation,
Strength
Digital Image Processing.
Weakness
It is a costly approach since a camera is used & no sensors are used.
8
2.2. Product 2:
Susmita Das , Manish Guha , Supravat Roy , Sayantan Mitra , Avipsa Basak , Nishtha Gupta,
Functionality
In this project work the effort of restructuring an automated mechanical arm is depicted with the
utilization of infrared obstruction detection and also relocation of that specific object.
The incorporation of Arduino programming merged with the intelligent design approach of robotic
movement of an artificial hand is the main attraction of the presented work. This gives the idea of a
creation in technical field where hardware and software interfacing is done tactfully.
Strength
IR detection method
2.3. Product 3:
“Automation of Object Sorting System Using Pick & Place Robotic Arm & Image Processing”,
Swarnendu Sarkar
Functionality
The Project deals with an automated material handling system. It aims in classifying the colored objects
by colour, size, character which are coming on the conveyor by picking and placing the objects in its
respective pre-programmed place. Thereby eliminating the monotonous work done by humans,
achieving accuracy and speed in the work. The project involves sensors that senses the object’s colour,
9
The microcontroller sends signal to circuit which drives the various motors of the robotic arm to grip
the object and place it in the specified location. Based upon the detection, the robotic arm moves to
the specified location, releases the object and comes back to the original position
Strength
Sensors are instead of Image processing therefore cost and difficulty in development is less.
10
3. PROBLEM FORMULATION
The main objective of the design project was to develop a fully automatic machine which could sort
1. The product was designed to occupy the least space in its area of application.
3. All the components of the product should also be very easily accessible for the operator so that
Change to a faster 360 degree rotation servo would greatly improve the performance of the
system
A 720 or 1080 degree rotation servo could be used to calculate the shortest distance to the next
cup
Use of Image processing or infrared sensors for colour and material identification
Replacing servos of arm with Stepper motors for picking heavy loads.
Mount a LCD display which could show the current color distribution and other vital system
information
11
3.4. Conclusions
Keeping in mind all the design constraints faced during the design and implementation phases of the
project, an Arduino UNO microcontroller was selected along with the simplest servo motors and a
photodiode colour sensor. The servo motors allowed for a large area to place the sorting boxes for
12
4. DESIGN METHODOLOGY
4.1. Implementation
Colour detection
This section is used for detecting the colour of the balls to be sorted. There are many colour sensing
ICs available today. In different ICs the properties vary such as colour differentiating ability, output
13
The TCS3200 is a programmable light-to-frequency converter that combines configurable silicon
photodiodes and a current to frequency converter on a single monolithic CMOS integrated circuit. The
output is a square wave (50% duty cycle) with frequency directly proportional to light intensity. The
full-scale output frequency can be easily scaled by one of three values via two control input pins.
Digital inputs and digital outputs allow direct interface to a microcontroller or other logic circuitry.
Output enable places the output in the high impedance state for multiple-unit sharing of a
In TCS3200, the light-to-frequency converter reads an 8x8 array of photodiodes. Sixteen photodiodes
have blue filters, sixteen photodiodes have green filters, sixteen photodiodes have red filters, and
sixteen photodiodes are clear with no filters. The four types of photodiodes are interdigitated to
minimize the effect of non-uniformity of incident irradiance. All photodiodes of the same colour are
connected in parallel. Pins S2 and S3 are used to select the group of photodiodes (red, green, blue,
clear) are active. Photodiodes are 110µm x110µm in size and are on 134µm centers. Output frequency
The internal light-to-frequency converter generates a fixed-pulse width train. Scaling is accomplished
by internally connecting the pulse-train output of the converter to a series of frequency dividers.
Divided outputs are 50% duty cycle square waves with relative frequency values of 100%, 20% and
2%. Because division of the output frequency is accomplished by counting pulses of the principal
internal frequency, the final output period represents an average of the multiple periods of the principle
frequency.
Microcontroller
In this project ATMega328P based microcontroller Arduino UNO is used with RISC architecture. It
has 20 I/O lines. The data output from TCS3200 is a waveform with 50% duty cycle and a frequency
proportional to the intensity of the light reflected from object. The frequency proportional to the
intensity of the light reflected from light. The frequency proportional to the of the waveform if
14
calculated using the microcontroller by finding the time elapsed between two successive high pulses
which will give the time period of a pulse. The time thus obtained can be substituted in mathematical
equations which will give the frequency of the waveform. The time period elapsed between two
successive pulses is measured by using external interrupts, when a high pulse is appeared at the
The first interrupt generated will start the timer. The timer value will be inversely proportional to the
frequency of the waveform, with a convenient relation the respective frequency is calculated. Since
the frequency of the waveform is proportional to the intensity if the reflected light from the object
which is very much related to the colour of the object and the colour of the object can be decoded from
Once the colour of the ball is detected, the ball is picked up from the rail and drops it in the right basket
using the robotic arm. The robotic arm movement is anticipated by using servo motors. Rotation of the
servo motors converted to arm movement. That angle of rotation is based on the duty cycle of the
waveform appearing on the control pin of the servo motor and it remains in that position as long as the
waveform continues. The PWM for controlling the servo motors are generated by the microcontroller
according to the colour input to the servo motors are controlled by the different four output pins of the
microcontroller.
15
Robotic arm structure
The robotic arm is controlled using servo motors whose degree of rotation is controlled by the on timer
of the pulse rail appearing at its control input. According to the structure by the robotic arm various
degree of rotation for the servo motor are assigned to carry out the operations. The arm of the robot is
realized using aluminum brackets. Four types of brackets are designed for this propose. Two types of
the brackets are for holding the servo motors and two types for the extensions and interconnections of
4.2. Working
The colour sensor identifies the colour of the ball and it sends the data to a microcontroller which
controls the arm motion according to the colour of the ball. The motion of the servo motors are
controlled in a manner so that each ball is dropped into a respective boxes place in a predetermined
position.
16
The time taken by the robotic arm for a single motion is set to approximately 0.5 seconds. Eight steps
of motion of robotic arm are required for a ball to be picked up and to be dropped in the correct basket.
That includes motion of arm from the default position, picking a ball, motion to the correct basket,
dropping the ball to the basket and return to the default position. The number of steps taken by the arm
to pick the ball and drop the ball counts to seven steps and from there to back to default position needed
one step.
Approximate time needed for the microcontroller to identify colour of the ball is around one second.
Therefore the total time needed for picking and dropping the ball including identifying the colour is
around five seconds. Four motors are used in the robotic arm. One to control the rotational motion of
the base, one to control the angle at the elbow, one to control the wrist movement and last one to
The figure 3 shows the initial position of the robotic arm when power is applied and the robot is ready
for operation. A lever mechanism is used for opening and closing the gripper. So a single motor is
enough for the gripper control. Fingers come closer to pick and hold the ball and move apart when it
drops the ball. Two positions are designed for the fingers by using a single servo motor. One in close
position and the other in open position. Two motions are permitted for the motors at wrist and elbow
that is to move up and down. Then by controlling the finger motion the ball is picked. After picking
the ball arm return back to initial position by rotating motor at the wrist and elbow to default degrees.
Here only one position of servo motor at finger varies from default position and the position of the
motor. The motion of the motor at the base is controlled as per the colour of the ball. The base motor
is made to rotate to four different positions. One is the default position which keeps the arm directly
above the sensor module. Other three motions keep the arm above the appropriate colour boxes. Two
boxes are placed left to the base, one at extreme left and the other one located between extreme left
and default position and one box at the right. Angle of rotation of the base motor for each motion is
described below.
17
4.3. Mathematical calculations
Degree of rotation of different servo motors of the robotic arm for different operations
18
4.1 Move to Correct box (Pink) right 135 80 125 75
side
side
8 Default 85 80 125 40
Consider the colour of the ball is red and ball is to be dropped in the box at the right side. The rotation
of the base motor is based on the colour of the ball picked up. The value of the degree assigned to the
base changes according to the ball colour and the arm position itself above the right box to which the
ball is to be dropped. Now the ball is to be dropped. The ball is dropped in the correct box and now it
has to be return to the initial position to pick up the next ball. Base motor rotates CCW and the arm
19
4.4. CAD Drawings
20
5. RESULTS AND DISCUSSION
This project is about the design, development and construction of a robotic arm, which can pick and
sort objects of different colour. The mechanical structure of the robot was assembled using aluminum
brackets which helped to reduce the weight without losing the mechanical strength. The aim of the
project was to have a fully functional robotic arm which sorts different coloured balls and the target is
achieved successfully. In the final run of the project six coloured balls were successfully sorted.
The colour sensor IC TCS3200 show almost stable response in various sunlight conditions. The system
is working with open loop. A better resolution can be achieved if closed loop control is incorporated.
The system responses are a little bit slower than expected. It can be improved by using a more advanced
colour sensor and microcontroller. User interfaces also can be provided as a modification which will
21
6. CONCLUSION
The aim of the project was to have a fully functional robotic arm which sorts different coloured balls
and the target is achieved successfully. In the final run of the project six coloured balls were
successfully sorted. This robot involves sorting of objects through colour sensors, the future
advancements can be done by increasing the efficiency of the colour sensor. This method is verified
The aim of the project was to have a fully functional robotic arm which sorts different coloured balls
and the target is achieved successfully. In the final run of the six coloured balls were successfully
sorted. The colour sensor IC TCS3200 show almost stable response in various sunlight conditions. The
system is working with open loop. A better resolution can be achieved if closed loop control is
incorporated. The system responses are a little bit slower than expected. It can be improved by using
22