Pokhara University
Nepal Engineering College
A proposal on
Obstacle Avoiding Robot
Submitted by:
Bipul Adhikari(021-404)
Manish Kafle(021-409)
Bijay Poudel(021-421)
Submitted to:
Department of Electronics and Communication Engineering
Nepal engineering college
Bhaktapur,Nepal
Date: 13th december 2023
1
ACKNOWLEDEGMENT
We would like to express our sincere gratitude to our Bijay Shrestha sir for his
help during project work.He has been an excellent advisor demonstrating good
patience and enormous help throughout our project.
We thanks our college Nepal engineering college for supporting us.We would
like to thanks Bijay Shrestha sir for giving us instructions for our project.We
also thankful to the Electronics and communication department for providing us
great ideas and vital comments during and in other discussions. Honestly, their
involvement was so vital to play a significant role in completing this project.
2
ABSTRACT
Development of an obstacle avoiding robot model is required as a fundamental
step towards a bigger goal,for example development of an autonomous vehicle.An
obstacle avoiding robot uses a proximity sensor module,besides other parts. In this
case,this robot uses a proximity sensor developed by ourselves.The robot is
controlled by a program that is embedded into a microcontroller.The logics
produced by the microcontroller are further processed by the interface module,in
this case ,also developed by ourselves. The interface module translates
microcontroller's logics into voltage and current that can practically drive the two
motors.This article provides a report on the project activity,consisting of summary
of the design ,summary of the running test of the robot. Following the test and
program fine-tuning,it has been proven that the robot model operated well just as
programmed.
3
Table of content
Chapter page no
1. Introduction
1.1 Background 7-8
1.2 Statement of problems 9
1.3 Objectives and scope 10
1.4 Application 11
1.5 Overview of proposal 12
1.6 Literature review 13
2. Methodology and implementation
2.1 Basic block diagram and method of working 14-16
2.2 Hardware and software used 16-20
2.3 Expected output16 20
3. Feasibility analysis
3.1 Schedule 21
3.2 Financial plan 21
4. Conclusion 22
5.References 23
4
LIST OF FIGURES
Figure 2.1.1 Circuit Diagram…………………………………………………………………
Figure 2.2.1 Arduino……………………………………………………………………….
Figure 2.2.2 Ultrasonic sensor………………………………………………………………
Figure2.2.3 Motor Driver IC…………………………………………………………………
5
LIST OF TABLES
Table 3.1 Gantt Chart………………………………………………………………..
Table 3.2 Cost Estimation………………………………………………………….
6
CHAPTER 1
INTRODUCTION
1.1 Background
Robot are often employed to deal with activities that are dangerous and
activities that involve in an uncomfortable environment. Robot are
applicable in various industries such as aerospace, chemical, construction,
manufacturing and others. High temperature environment in manufacturing
processes are one of the example that require robot. Obstacle avoidance
strategy is an algorithm of the robot’s action when detecting an obstacle.
The purpose of the obstacle avoidance strategy is to prevent the robot from
any collision with any object or obstacle which may cause damage to the
obstacles and the mobile robot itself. In aerospace industry, numerous robot
are used in an unknown place which does not have information of the
obstacle around the place while in manufacturing or chemical industries,
raw materials, machines, parts and products are the examples of the
obstacles robot. Thus, it is also important to prevent any damage on the
component.
In obstacle avoidance, obstacle detection are important element to
decide the motion and direction of the mobile robot. For example, a mobile
robot will accelerating until optimum speed if obstacle are far from the
mobile robot while mobile robot will decelerate if obstacle are close to it
and make a turn. There was difference of sensor or process that used for
obstacle detection such as sonar sensor, image processing and others. 2
Sonar sensor is one of the common sensor that is used to detect the obstacle.
The sensor detects the range between the sensor and obstacle by
transmitting ultrasound wave with constant wavelength which will be
reflected by the obstacle. The transmitter are used to send the transmitted
wave and the receiver are used to receive the reflected wave. Sonar sensor
does not depend on the colour of the object. There are a few disadvantages
of sonar sensor. Sonar sensor have a range of sensing range. Other than that,
7
the change of environment will affect the accuracy of the sonar sensor such
as humidity and temperature.
8
1.2Statements of problem
Numerous field of industry have use robot or each application and other
industries are start to consider robot in their applications since the improvement
of technology lately. Obstacle avoidance system provides safety for both robot
and obstacles around. This would prevent any costing for repair and without
increase the cost of maintenance or repair of the robot. robot without obstacle
avoidance will be unsafe for both obstacles and mobile robot. In critical situation,
it may cause accident that causes major losses.
Development of obstacle avoidance system have a number of
complication with difficulties in algorithm design. The difficulties included
unseen environment and to avoid contact or collide with objects within a
field. The algorithm are developed that can evade more than one obstacle
and which will decide the direction of mobile robot to heading. Simulation
of an obstacle avoidance mobile robot to avoid collision are depend on the
direction of x-axis and y-axis heading and position in time domain and the
detection of the obstacle around of x-axis and y-axis. Angle of heading are
needed also to determine in time domain so it is applicable for obstacle
avoidance. A series of equation or relation needed to develop for the
obstacle avoidance simulation to be used as obstacle avoidance system.
Fuzzy logic control system will be used for simulation of the obstacle
avoidance system. The advantage of fuzzy logic is that it does not need an
exact or precise input or information to proceed the system. In other hand,
it is challenging to keep the accuracy, reliability, and extensiveness for the
built the fuzzy logic rule base.
9
1.3 Objective and scope
The objectives of this research:
1. To develop an algorithm for obstacle avoidance mobile robot using fuzzy
logic rules.
2. To verify the algorithm by using simulation
Obstacle avoidance mobile robot itself is a broad field of study. In order to bind
this research to be in manageable scale, the scope of this project is limited to:
1. The axis of the mobile robot travel area is only covered in two dimensional
analysis only, which is on X and Y axis. Z axis is assumed constant to ease
and simplify the algorithm development.
2. The surface of the mobile robot travel is assumed to be operated in flat and
smooth surface (normal friction coefficient, in dry surface). Different friction
coefficient will affect the calculation of the mobile robot travel distance due
to the wheel slip and will affect the decision making of the mobile robot
controllers.
3. The characteristic for the obstacle is assumed to be in perfect polygon
shape such as triangle, square, and circle. Complex or nonlinear shape will
introduce sensor reading error to the mobile robot.
4. Only static obstacle will be taken into consideration. The moving obstacle
will involve more parameters into consideration and add extra modelling
process to the moving obstacle detection.
10
1.4Applications
Obstacle avoiding robots can be used in almost all mobile robot navigation
systems.
They can be used for household work like automatic vacuum cleaning.
They can also be used in dangerous environments, where human penetration
could be fatal.
By the end of this article, you came to know about designing an obstacle avoidance
robot and the code to run the device. To your surprise, we have also provided Robot
vacuum cleaners that make use of anti-collision and obstacle avoidance sensors. Just
with a click, know more about the Robot Vacuum Cleaners that has amazing features.
Earlier the robots move in all directions as per the commands are given to it. Later they
came to know that it got stuck when there is an unexpected obstacle in front of it. So
they made extreme research work and come with the Obstacle avoidance Arduino
robots.
You came to know about its applications, working, and the hardware parts required
assembling. You have attempted it many times and didn’t get the result or would like to
get from other sources. Then the Arduino Robot Kits is for you.
These kits are a great solution for beginners, and the engineers to build their knowledge
in Arduino and Robots by designing cool projects. It has a manual to guide assembling
procedure, working theories and project designs.
Read the full-length article to know more about the Arduino robot kits. Arduino Robot
Kits
11
1.5 Overview of proposal
Robotics is the branch of technology that deals with the design,
construction, operation, and application of robots. A machine capable of
carrying out a complex series of actions automatically, esp. one programmable
by a computer is defined as a robot. The project is to develop a robot that will
move according to the code assigned but find a free space, navigating from a
obstacle on its way. This kind of obstacle is very useful in industries where
automatic supervision is needed, for example, in places where it might be risky
for humans to be. This robot can also be made by putting other sensors like
light sensors or line sensors, ultrasonic sensors and ultrasound sensor
depending on the need.
12
1.6 Literature review
In order to design and develop an obstacles avoidance robot by using fuzzy
logic controller, extensive research on the fuzzy controller need to be fulfilled.
This section will discuss previous studies that have been accomplished by other
researchers in the same area. “Mobile Robot Obstacle Avoidance in a
Computerized Travel Aid for the Blind” .In this paper a mobile robot obstacle
avoidance system has been converted successfully to a navigation aid for the
blind. Instead of transmitting electronic signals to the robot motion controllers,
the obstacle avoidance system relays information to the user by transmitting
stereophonic signals. These signals provide spatial information about the
location of objects in space, or guiding information for the recommended travel
direction and speed. [3] “Obstacle Avoidance Robot Applying Fuzzy Control
System”. In this project primarily addresses the design and implementation of
fuzzy logic based controller for obstacles avoidance robot. Some techniques,
sensors and controller have been applied to fulfill the requirements of the
robot. The robot is able to interact with unknown environment using a reactive
strategy determined by the sensors information. The obstacle avoidance
controller is two inputs and two outputs system. The inputs are two proximity
measurement of the obstacles distance, and the outputs are the velocities of
the two wheels. The robot is driven by two independent DC motors. The
ultrasonic sensors are mounted at left, front and right side of the mobile
robot. It can detect the obstacles within the range 3 cm to 300 cm. The
kinematic model was developed to control the movement of the robot’s
wheels. The detection of the obstacles by the sensors activates the [Chapter
Two] [Literature review] 8 controller which simply attempts to avoid the robot
with the obstacles. Once the robot avoids the obstacles, the robot will keep
sense for the new environment. Based on these signals, the controller control
the velocity of left and right wheels thus making the robot to move forward
13
and turning at the same time, i.e., the robot avoid the obstacle by turn left with
left motor velocity is 6.57 cm/s, right motor velocity is 8.29 cm/s and angular
velocity is 0.066154 rad/s when the obstacle detected from left sensor is 100
cm, right sensor is 100 cm and front sensor is 50 cm. Different obstacles
distance orientation also been tested and the robot response is working as
expected.
CHAPTER 2
METHODOLOGY AND IMPLEMENTATION
2.1 Basic block diagram and method of working
The basic block diagram for the implementation of the project is as shown in
figure. Block Diagram of the system The sonar system is used in HC-SR04
ultrasonic sensor to determine distance to an object like bats do. It offers
excellent non-contact range detection from about 2 cm to 400 cm or 1feet to
13 feet. Its operation is not affected by sunlight or black material. The
ultrasonic sensor emits the short and high frequency signal. If they detect any
object, then they reflect back echo signal which is taken as input to the sensor
through Echo pin .Firstly user initialize Trigger and Echo pin as low and push the
robot in forward direction. When obstacle is detected Echo pin will give input
as high to microcontroller. Pulse In function is used for calculating the time of
distance from the obstacle. Every time the function waits for pin to go high and
starts timing, then timing will be stopped when pin go to low. It returns the
pulse length in microseconds or when complete pulse was not received within
the timeout it returns. The timing has been determined means it gives length of
the pulse and will show errors in shorter pulses. Pulses from 10microseconds to
3 minutes in length are taken into consideration. After determining the time, it
converts into a distance. If the distance of object is moderate then speed of
robot get reduced and will take left turn, If obstacle is present in left side then
it will take right turn. If the distance of object is short then speed of robot get
reduced and will turn in backward direction and then can go in left or right
direction. This robot was built with an Arduino development board on which
microcontroller is placed.
14
Circuit Diagram
15
Fig 2.1.1 Block diagram
Before going to working of the project, it is important to understand how the
ultrasonic sensor works. The basic principle behind the working of ultrasonic
sensor is as follows:
Using an external trigger signal, the Trig pin on ultrasonic sensor is made logic
high for at least 10µs. A sonic burst from the transmitter module is sent. This
consists of 8 pulses of 40KHz.
The signals return back after hitting a surface and the receiver detects this signal.
The Echo pin is high from the time of sending the signal and receiving it. This time
can be converted to distance using appropriate The aim of this project is to
implement an obstacle avoiding robot using ultrasonic sensor and Arduino. All the
connections are made as per the circuit diagram. The working of the project is
explained below.
When the robot is powered on, both the motors of the robot will run normally and
the robot moves forward. During this time, the ultrasonic sensor continuously
calculate the distance between the robot and the reflective surface.
This information is processed by the Arduino. If the distance between the robot
and the obstacle is less than 15cm, the Robot stops and scans in left and right
directions for new distance using Servo Motor and Ultrasonic Sensor. If the
distance towards the left side is more than that of the right side, the robot will
prepare for a left turn. But first, it backs up a little bit and then activates the Left
Wheel Motor in reversed in direction.
Limitations of this Circuit:
The disadvantage with the obstacle avoidance based on triangulation is the need
of the robot to stop in front of an obstacle in order to allow for a more accurate
16
measurement. All robots feature some kind of collision avoidance, that detect
an obstacle and stop the robot short of it in order to avoid a collision.
It requires a fixed path for its execution.
2.2 Hardware and software required
Hardware required
1.Arduino uno
Arduino is an open-source(free to use) electronics platform. It is based on easy-
to-use hardware and software. It's intended for anyone making interactive
electronics projects.Arduino uses sensors for sensing the environment by
receiving inputs from interfaced sensors. It can control its surroundings by
controlling various devices connected to its port like LEDs, motors, and other
actuators . it can be easily programmed by writing code in the Arduino
programming language and using the Arduino development environment (IDE).
17
Fig 2.2.1 Arduino
2.Ultrasonic Sensor
Ultrasonic sensors are devices that measure distances using ultrasonic waves.
This sensor is
An air intelligent sensor , which will use the phenomenon of wave propagation
in the air to
Measure physical or chemical variables. A working ultrasonic sensor is
similar to a radar
That will evaluate a target by examining echoes from radio or sound waves.
Higher-frequen-
cy sound wave are generated by the ultrasonic sensor and will evaluate the
echoes recei-
18
ved in the recovery section.The distance of the object is measured by the time
interval betw-
een sending and receiving echoes. We can measure wind speed and direction
with this technology,it can also be useful to find the completeness of the tank
can be measured by measuring the distance to the surface to the surface of the
liquid.
Fig2.2.2 Ultrasonic Sensor
3. Power supply
A power supply usually converts AC to DC. Sometimes the outputs are
multiple , sometimes regulated in voltage and/or current. The definition is loose
as it may be for a specific device or for general use. There is a class called
laboratory supply that usually have variable volateg control , sometime current
control and possibly output meters.
4.Motor driver IC-L293D
L293d IC is known as a motor driver. It is a low voltage operating device like
other ICs. The other ICs could have the same functions like L293d but
they cannot provide the high voltage to the motor. L293d provides the continuous
bidirectional Direct Current to the Motor. The Polarity
of current can change at any time without affecting the whole IC or any other device in
the circuit. L293d has an internal H-bridge installed for two motors.
H-Bridge is an electrical circuit that enables the load in a bidirectional way. L293d bridge
is controlled by external low voltage signals. It may be small in size, but its power output
capacity is higher than our expectation. It could control any DC motor speed and
direction with a voltage range of 4.5 – 36 Volts. Its diodes also save the controlling
device and IC from back EMF. To control the max 600mA amount of current an internal
“Darlington transistor sink” installed in it, which could be used to control a large amount
of current by providing a small amount of current. It has also internal “pseudo-Darlington
19
source” which amplifies the input signal to control the high voltage DC motor without
any interception.
Fig 2.2.3 Motor Driver IC-L293D
Software required
1. Arduino programming
2.3 Expected output
Obstacle Avoidance Robot has dynamic steering algorithm which ensures that
the robot doesn't have to stop in front of an obstacle which allows robot to
navigate smoothly in an unknown environment, avoiding collisions.
The main motto of this robot is to avoid the accident which will generally
happen in congested Areas by applying emergency brake.
20
CHAPTER 3
FEASIBILITY ANALYSIS
3.1 Schedule
The whole project is completed in two months. A routine is decided to complete
the project. We are doing project work every Friday and Saturday. Our schedule
was from 10 am to 5 pm. First of all we completed our proposal writing in one
week. Then we start to collect the components needed to complete the project.
Then we do work on hardware part and then on software part. It takes aboutsix
week.
21
Table 3.1 Glantt chart
SN Tasks Weeks
1 Literature review One
2 Software simulation Three
3 Hardware realization Two
4 Documentation One
3.2 Financial plan
As this is a mini project we have done this project on arduino. First of all we
collected the name of the components used in this project. The total cost of the
project came around two thousand. Which includes arduino, IR sensor, diode,
transistor, led lights, resistors. While looking at the production cost it is a very
cost feasible project.
Table3.2.Cost Estimation
SN Items Cost per unit Total cost
1 Arduino 1500s 1500
2 Chessis board 1000 1000
3 UltraSonic sensor 350 350
4 Motor Driver 700 700
5 Servo Motor 250 250
6 Geared Motor 150 300
7 Power Supply 50 100
CHAPTER 4
CONCLUSION
Almost all navigation robot demands some sort of obstacle detection,
hence obstacle avoidance strategy is of most importance. Obstacle Avoidance
Robot has a vast field of application. They can be used as services robots, for
the purpose of household work and so many other indoor applications.
22
CHAPTER 5
REFERENCES
[1]V. Hanumante et al., “Low Cost Obstacle Avoidance Robot” in
International Journal of Soft Computing and Engineering, Vol. 3,
Issue-4, 2013
[2] ATMEGA328P Datasheet ATMEL Corporation, San Jose, CA,
2008
[3] M. Nasucha, “Design and Development of an Interface Module
for Obstacle Avoiding Robots”, Microcontroller Lab, Univ.
Pembangun Jaya, Tangerang Selatan, Indonesia, 2015
[4] M. Jouaneh, “Proximity Measurement” in Fundamentals of
Mechatronics, SI Edition, United States: Nelson Engineering,
ch.7, sec. 7.4, pp. 221-229, 2012
23
[5] M. Nasucha, “Design and Development of a Visible Light Sensor
Module for Obstacle Avoiding Robots”, Microcontroller Lab,
Univ. Pembangunan Jaya, Tangerang Selatan, Indonesia, 2015
24