Final Project Review
Final Project Review
Final Project Review
1. Introduction
Line follower is a machine that can follow a path. The path can be visible like a black line
on a white surface. Sensing a line and maneuvering the robot to stay on course, while
constantly correcting wrong moves using feedback from the sensor forms a simple yet
effective system. It can be used in automobile, industrial automation's, guidance, etc .
1.1. Background
1.2. Motivation
How ants always travel in a line, following an invisible route in search of food, or back
home. How on roads the lanes is followed to avoid accidents and traffic jams. Ever
thought about a robot, which follows line? A perfect or near perfect mimic of nature?
After all the purpose of robotics is to recreate in terms of machines what one see around
to solve a problem or fulfill a requirement.
The area will be benefited from the project
Industrial automated equipment carriers
Entertainment and small household applications.
Tour guides in museums and other similar applications.
Second wave reconnaissance operations.
In the industry, carriers are required to carry products from one manufacturing plant to
another that are usually in different buildings or separate blocks. Conventionally, carts or
trucks were used with human drivers. Unreliability and inefficiency in this part of the
assembly line formed the weakest link. The project is to automate this sector, using carts
to follow a line instead of laying railway tracks, which are both costly, and an
inconvenience.
1.4. Objectives
1.5. Methodology
After the detail literature survey through the books, periodical, journal, magazine,
websites. The idea of the project is well defined.
The logic is derived for the intelligence of the robot. It is programmed and burn it
to the Arduino by using the software Arduino® 1.65.
The accuracy and viability of the program and electronic components is tested in
the simulation software Proteus®.
After the successful simulation result, it is implemented in the hardware.
After the finishing the programming, electrical and electronics part, the
stable, reliable and flexible mechanical design and fabrication is completed.
Finally, system is tested and encountered error is omitted.
1.6. Limitations
This report is a documentary delivering the ideas generated, concepts applied, activities
done It contains four chapters. The following is a description of information in this thesis.
Chapter 1 provides a general overview of the project and the use and importance of
autonomous robots in the world. The objectives, scope of project, problem statement are
also described in this chapter.
Chapter 2 describes the hardware development unit in line following robot. This chapter
describes about sensor arrays, Arduino, motor driving system, it also describes the project
methodology and explains hardware development for the design of the robot.
Chapter 3 contains the process explanation with working algorithm, flowchart and sketch
of the Arduino.
Chapter 5 contains all the results obtained from the software experiments that include the
algorithm implemented in a program.
Finally, chapter 5 will summarize the final year project. The conclusion, suggestions or
recommendations for improvements that can be implemented in future are discussed
within this chapter.
1.8. Summary
Line Follower is one of the most important aspects of robotics. A Line Following Robot
is an autonomous robot which is able to follow either a black or white line that is drawn
on the surface consisting of a contrasting color. It is designed to move automatically and
follow the plotted line. It enhances interdisciplinary approach to mechanical, electronic,
electrical and programming skills. The application of the project is range from the
individual domestic appliance to automation and control aspect of large industry. Human
are intelligent natural machine but it has serious limitation of efficiency and reliability.
Robots are made to replace dependency of human force partially. The project is somehow
designed to perform the similar task.
LM324
Comparator
Threshold
Voltage
LCD Sensor
Panel Array
The sensors on the left named as L1, L2 and R1, R2 on the right side. Assumption should
be considered that when a sensor is on the line it reads 0 and when it is off the line it reads
1. The Arduino correspondence to the algorithm given below decides the next movement,
trying to position the robot such that all sensors read 0.
With sensors, robots can react and respond to changes in their environment in ways that
appear intelligent or life-like.
VCC 5V
Inverting(-ve) -
Input Co mparator
Non-Inverting OUTPUT (Vo)
(+ve) Input
GROUND
2.2.1.2. Arduino
Arduino is an open-source computer hardware and software company, project and user
community that designs and manufactures microcontroller-based kits for building digital
devices and interactive objects that can sense and control objects in the physical world.
The heart of Arduino is the microcontroller. For Arduino Uno ATmega328 is used. It has
specification of 8 bit CPU, 16 MHZ clock speed, 2 KB SRAM 32 KB flash Memory, 1
KB EEPROM [2].
Features:-
14 digital input output pins ( 3,5,6,9,10 and 11 pins are able to generate PWM).
IC L293D
This is a motor driver IC that can drive two motor simultaneously. Supply voltage (Vss)
is the voltage at which motor drive. Generally, 6V for dc motor and 6 to 12V for gear
motor are used, depending upon the rating of the motor. Logical Supply Voltage deciding
what value of input voltage should be considered as high or low .So if the logical supply
voltage equals to +5V, then -0.3V to 1.5V will be considered as Input low voltage and
2.3V to 5V is taken into consider as Input High Voltage. The Enable 1 and Enable 2 are
the input pin for the PWM led speed control for the motor L293D has 2 Channels .One
channel is used for one motor.2
Motor is a device that converts any form of energy into mechanical energy or imparts
motion. In constructing a robot, motor usually plays an important role by giving
movement to the robot. In general, motor operating with the effect of conductor with
current and the permanent magnetic field. The conductor with current usually producing
magnetic field that will react with the magnetic field produces by the permanent magnet
to make the motor rotate.There are generally three basic types of motor, DC motor, even
servomotor and stepper motor, which are always being used in building a robot.
DC motors are most easy for controlling. One DC motor has two signals for its
operation. Reversing the polarity of the power supply across it can change the direction
required. Speed can be varied by varying the voltage across motor.
In our project it is used to display the distance travelled by the robot through the output
from the tachometer system.
The combination of IR- LED and Photodiode is used as the reflective optical sensor. It
generate interrupt when the IR-beam is break to the photodiode. To create the IR break-
beam, IR LED is used with a low value resistor so that it shines very bright. The receiver
is Photodiode, which biases 'on' whenever the IR LED's light is detected. A sensor will be
placed adjacent the IR link and turned on to generate a pulse to the Arduino. The Arduino
LCD interface is used to show the covered distance digitally.
2.4. Summary
The system is completed in to the three divison i.e is the Input system, Processing System
and Output system.
Input system comprises of the optical sensor, is an array of 4 IR-LED and Photodiode
pairs arranged in the form straight lines. The output from each sensor is fed into an analog
comparator with the threshold voltage (used to calibrate the intensity level difference of
the line with respect to the surface). These 4 signals(from each photo-reflective sensor) is
given to a priority analog input of the arduino [3].
Processing system is Arduino Uno interface consisting microcontroller Atmega328 which
works on the basic of the logic of the program burn to it.
Output system consist combination L293D and gear-motor The control has 6 modes of
operation, turn left/right, move left/right, and drift left/right. The actual action is caused
by controlling the direction/speed of the two motors (the two back wheels), thus causing a
turn.
3.1. Schematic
The schematic of the “Line Following Robot” is shown in the figure. The main
component is the Arduino Uno. Schematic is drawn by using Proteus.
The main features incorporated into the hardware are given below:
Ardunio Uno.
The IR-LED with IR illuminance, modified to be reflective sensor.
The LM324 quad comparator IC.
A potentiometer to calibrate the reference voltage.
The H-bridge motor control IC (L293D)
Motors, with coupled reduction gears.
Connectors to join the different boards to form one functional device.
A pair of IR-LED and Photodiode is used as proximity sensor for the designing
techometer
Each of the hardware is dissected and was designed/implemented separately for their
functional and later incorporated as one whole application. This helped in the debugging
processes.
CIRCUIT DIAGRAM
Thus totally the microcontroller gets 4 inputs from the sensor circuitry, to the (A3 – A0)
of Arduino to decide what to do when on the line. Below is the complete description
about what each input mean and what needs to be done [4].
Sensor
Path
Turn right for the rightmost condition Sharp turn right for the rightmost condition
and turn left for left most condition. and sharp turn left for left most condition.
3.4.1. Flowchart.
The following chart shows implemented logic.
Mathematical Interpretation:
Rotational power (Pr) is given by:
Pr= Torque (T) X Rotational Speed (ω)
𝑝𝑟
Γ=
𝜔
Pr is constant for DC motor for a constant input electrical power. Thus torque (T) is
inversely proportional speed (ω)
1
Γ≁
𝜔
1 𝑡𝑜𝑛
A= ∫ 12𝑑𝑡
0
𝑡𝑜𝑛
𝐴 = 12
𝑡
𝐴 = 12 × 𝜌
Where ρ is the duty cycle of the PWM control signal; this shows that by varying the duty
cycle of the PWM control, we effectively vary the DC voltage supplied to the motors,
thus controlling their speed. This is generated by the Arduino built-in hardware [9].
4.3.1. Calculation
The system is designed in such way that it updates the distance value in every 5 seconds.
i.e. 12 times per minute.
4.4. Summary
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 spends on versus the time that the
signal spends off. The duration of "on time" is called the pulse width. To get varying
analog values, change or modulate that pulse width.
Since, the build tachometer can be used, as from the analysis the error percentage within
limit, for the maximum rpm is to be measured i.e. 250 rpm.
𝑆𝐿 = 𝑟𝜃
𝑆𝑅 = (𝑟 + 𝑏)𝜃
𝑆𝑀 = (𝑟 + 𝑏) 𝜃
2
Where SL and SR give the displacement for the left and right wheels respectively, r is the
turning radius. b is the distance between wheel, and 𝜃 is the angle of turn. SM is the
speed at the center point as the main axle.
Design of Path
The path consists of three U-turns of different radii. Among three, the system swiftly turn
two U-turn and it goes out of track in one initial U-turn and retrace it’s path.
The diagram in which robot car is making a turn. The situation is show in the figure
above. The wheels are shown shaded in the figure. The front wheel’s center is P and the
rear wheel’s center is Q. Let O be the center of the circle, along whose circumference the
car moves. Let L=PQ be the length of the car and let R be the radius of the circle.
Sharpest turn corresponds to smallest possible value of R. Note that PQ is a chord of the
circle. Let us say that the front wheel can rotate at most by an angle w relative to the
‘straight’ position. For triangle OPQ [11].
u + 2v = 1800 (1)
also , w + v = 900 (2)
From, cosine rule for OPQ:
L2 = R2 + R2 – 2R2 cos(u) (3)
n
From eq (1), (2) and (3)
𝐿
𝑅= 2𝑠𝑖𝑛𝑤
At the maximum value of sin i.e 1 . The turning radius is found to be L/2 = 87.2mm.
Now, the velocity of the automobile is the prime factor to determine the ability to take
turn smoothly or not. So we have to derive the relation between the the turning radius and
The velocity of the robot car.
5.2. Summary
The main criteria of the mechanical design is mainly depends upon the differential
steering mechanism, turning radius. The calculation of turning radius is necessary because
it finds out the mechanical limitation for the types of the curve which is avoded. The
turning radius for the design is found to be 100mm .
So, in case of designing path the maximum turning radius mustn’t be less than 100mm
6.1. Conclusion
The line following robot is automobile system that has ability to recognize its path, move
and change the robot's position toward the line in the best way to remain in track.
This project report presents a photodiode sensor based line follower robot design of
200gm weigh, which always directs along the black line on white surface. The
electromechanically robot dimension is 192×100×70 mm 3 with max rpm 180 at no load
and frictionless condition. The minimum turning radius for the system is 100mm at
velocity of 24.2 cm/s. The robot is able to detect it’s path in case it is out of path.
The line following robot project challenged the group to cooperate, communicate, and
expand understanding of electronics, mechanical systems, and their integration with
programming. The successful completion of every task demonstrated the potential of
mechatronic systems and a positive group dynamic.
[2]J. Warren, J. Adams and H. Molle, "Arduino for Robotics," in Arduino Robotics,
New York, Apress publication, 2014, pp. 51-83.
[5]S. Monk, Programming Arduino Getting Started with Sketches, New Delhi, India: Tata
Macgrawhill, 2012.
[6]Open Source community, " Open Source Sketch," January 2015. [Online]. Available:
https://www.arduino.cc/en/Guide/Introduction. [Accessed 25 November 2015].
[7] A. Parsad, "Line Following Robot,"Dept. Elex. & Comm. Eng., Visvesvaraya
Technological University, Bangalore, India, 2005
[9]S. Deborah and Md. Jinnah, "Digital RPM meter using Arduino,"Dept. Elect.Eng.,
Ahsanullah Univ. of Sci. & Tech., Dhaka, Bangladesh, 2012.
void setup() {
pinMode(in1,OUTPUT);
pinMode(in2,OUTPUT);
pinMode(in3,OUTPUT);
pinMode(in4,OUTPUT);
pinMode(enA,OUTPUT);
pinMode(enB,OUTPUT);
void loop() {
void forward()
{
digitalWrite(in1, HIGH);
digitalWrite(in2, LOW);
digitalWrite(in3, HIGH);
digitalWrite(in4, LOW);
analogWrite(enA, M1_Speed);
analogWrite(enB, M2_Speed);
}
void backward()
{
digitalWrite(in1, LOW);
digitalWrite(in2, HIGH);
digitalWrite(in3, LOW);
digitalWrite(in4, HIGH);
analogWrite(enA, M1_Speed);
void right()
{
digitalWrite(in1, LOW);
digitalWrite(in2, HIGH);
digitalWrite(in3, HIGH);
digitalWrite(in4, LOW);
analogWrite(enA, LeftRotationSpeed);
analogWrite(enB, RightRotationSpeed);
}
void left()
{
digitalWrite(in1, HIGH);
digitalWrite(in2, LOW);
digitalWrite(in3, LOW);
digitalWrite(in4, HIGH);
analogWrite(enA, LeftRotationSpeed);
analogWrite(enB, RightRotationSpeed);
}
void Stop()
{
digitalWrite(in1, LOW);
digitalWrite(in2, LOW);
digitalWrite(in3, LOW);
digitalWrite(in4, LOW);
}