My Document
My Document
ROBOTIC VEHICLE
using
ULTRASONIC SENSOR
and
ARDUINO
CONTROLLER
V
ABSTRACT
VI
ACKNOWLEDGEMENT
It is my proud privilege and duty to acknowledge the kind of help and guidance
received from several people in preparation of this report. Apart from my own,
the success of this report depends largely on the encouragement and guidelines of
many others. It would have not been possible to prepare this report in this form
without their valuable help, co- operation and guidance.
I would like to express my deep sense of gratitude to our Principal Dr. Sanjay
Jain, CMR Institute of Technology College, Bangalore for his motivation and for
creating an inspiring atmosphere in college by providing state of the art facilities
for preparation and delivery of this report.
project.
Last but not least, I would like to put forward my heartfelt acknowledgement to
all my project mates who have directly or indirectly provided their overwhelming
support during my project work and the development of this report.
Jeevan M
1CR17EE025
VII
CONTENTS
Chapter 1:
Introduction 1
Chapter 2:
Literature Review 3
Chapter 3:
Design & Hardware 5
Chapter 4:
Block Diagram 7
Chapter 5:
Working 11 - 16
Chapter 6:
Circuit Diagram 17
Chapter 7:
Applications 19
Chapter 8:
Experimental Results 21
Chapter 9:
Program 23 - 25
Chapter 10:
Conclusion 27
Chapter 11:
Reference 30
CHAPTER NO: 1
INTRODUCTION
INTRODUCTION
This project is basic stage of any automatic robot.This ROBOT has sufficient
intelligence to cover the maximum area of provided space. It has a ultrasonic sensor which
are used to sense the obstacles coming in between the path of ROBOT. It will move in a
particular direction and avoid the obstacle which is coming in its path. We have used two D.C
motors to give motion to the ROBOT. The construction of the ROBOT circuit is easy and
small .The electronics parts used in the ROBOT circuits are easily available and cheap too.
CHAPTER NO :2
LITERATURE REVIEW
LITERATURE REVIEW:
Robots need miscellaneous of sensors to obtain information about the world around
them. Sensors will help detect position, velocity, acceleration and range for the
object in the robot's workspace. There is a variety of sensors used to detect the range
of an object. One of the most common range finders is the ultrasonic transducer.
Vision systems are also used to greatly improve the robot’s versatility, speed and
accuracy for its complex and difficult task. Electronic signals are sent to a mobile
robot’s motor controllers and auditory signals can guide the blind traveller around
the obstacles the developed robot uses ultrasonic range finder for detection and
mapping to avoid collision with the unexpected obstacles.
“Obstacle-avoiding robot with IR motion Sensors” has been designed and developed
,robot platform was not designed for specific task but as a general wheeled
autonomous platform. It can therefore be used for educational, research or industrial
implementation. Students can use it to learn the microcontroller programming using
C++, Arduino Uno compiler, IR sensors characteristics, motor driving circuit and
signal condition circuit design. Research on obstacle avoidance robot at the
polytechnic level can help students to develop communication, technical skills and
teamwork. The design of such robot is very flexible and various methods can be
adapted for another implementation. It shows that PIR sensors are more sensitive
compared to IR sensors while detecting human being
CHAPTER NO: 3
DESIGN & HARDWARE
REQUIREMENTS
Design:
Hardware:
Arduino UNO
Ultrasonic sensor
DC Motors
Motor driver IC (L293D)
Battery (9V)
Jumper Wires
Chassis
Wheels
CHAPTER NO:4
BLOCK DIAGRAM
BLOCK DIAGRAM
The basic block diagram of the obstacle avoiding car is shown in above figure. Mainly this
block diagram consists of the following essential blocks.
1. Arduino uno
2. Ultrasonic sensor
3. Motor driver(L293D)
1) Arduino uno -
2) Ultrasonic sensor -
3) Motor driver -
It is a motor driver which can provide bi-directional drive current for two motors.
CHAPTER NO:5
WORKING
Working Principle:
The obstacle avoidance robotic vehicle uses ultrasonic sensors for its movements. Arduino is
used to achieve the desired operation. The motors are connected through motor driver IC to
Arduino. The ultrasonic sensor is attached in front of the robot.
Whenever the robot is going on the desired path the ultrasonic sensor transmits the ultrasonic
waves continuously from its sensor head. Whenever an obstacle comes ahead of it the
ultrasonic waves are reflected back from an object and that information is passed to the
arduino. The arduino controls the motors left, right, back, front, based on ultrasonic signals.
In order to control the speed of each motor pulse width modulation is used (PWM).
When ultrasonic sensor detect the object which is kept inside the path it will send the signal
toward the arduino uno and according to that it will it will rotate the motor M3 & M4 in
forward direction and rotate the motor M1 & M2 in reverse direction such way that the car
get moving in left direction .
Similarly in every time when ever an obstacle in found to be in path of car it will detect it and
rotate the car in left direction to avoid the obstacle.
ARDUINO UNO:
Motor drivers take a low current control signal but provide a higher current signal,
thus acting as a current amplifier. The higher current signal drives the motors. L293D
is a motor driver that allows direct current (DC) motor to drive on either direction. It
contains two inbuilt H-bridge driver circuits . To rotate the motor in clockwise or
anticlockwise direction, voltage need to change its direction. H-bridge is a circuit that
allows voltage to be flown in either direction. Hence H-bridge IC are ideal for driving
a DC motor .
Here are 4 input pins for L293d, pin 2,7 on the left and pin 15 ,10 on the right as
shown on the pin diagram. Left input pins will regulate the rotation of motor
connected across left side and right input for motor on the right hand side. The motors
are rotated on the basis of the inputs provided across the input pins as LOGIC 0 or
LOGIC 1. For rotating the motor in clockwise direction the input pins has to be
provided with Logic 1 and Logic 0.Enable pins 1 and 9 (corresponding to the two
motors) must be high for motors to start operating. When an enable input is high, the
associated driver gets enabled. As a result, the outputs become active and work in
phase with their inputs. Similarly, when the enable input is low, that driver is disabled,
and their outputs are off and in the high-impedance state.
Motor (100rpm/ 12V DC Motor)
The obstacle detection and avoiding robot uses two 200rpm and 12V DC geared
motors. The motor used has a 6mm shaft diameter with internal holes. The internal
holes are for easy mounting of the wheels by using screws. It is an easy to use low-
cost motor for robotics application
An Electric DC motor is a machine which converts electric energy into mechanical
energy. The working of DC motor is based on the principle that when a current-
carrying conductor is placed in a magnetic field, it experiences a mechanical force.
The direction of mechanical force is given by Fleming’s Left-hand Rule and its
magnitude is given by F = BIL Newton.
DC motors are seldom used in ordinary applications because all electric supply
companies furnish alternating current.
ULTRASONIC SENSOR
An Ultrasonic sensor is a device that can measure the distance to an object by using
sound waves. It measures distance by sending out a sound wave at a specific
frequency and listening for that sound wave to bounce back. By recording the elapsed
time between the sound wave being generated and the sound wave bouncing back, it
is possible to calculate the distance between the sonar sensor and the object.
It emits an ultrasound at 40 000 Hz which travels through the air and if there is an
object or obstacle on its path It will bounce back to the module. Considering the travel
time and the speed of the sound you can calculate the distance.
The HC-SR04 Ultrasonic Module has 4 pins, Ground, VCC, Trig and Echo. The
Ground and the VCC pins of the module needs to be connected to the Ground and the
5 volts pins on the Arduino Board respectively and the trig and echo pins to any
Digital I/O pin on the Arduino Board.
In order to generate the ultrasound you need to set the Trig on a High State for 10 µs.
That will send out an 8 cycle sonic burst which will travel at the speed sound and it
will be received in the Echo pin. The Echo pin will output the time in microseconds
the sound wave traveled.
CHAPTER NO:6
CIRCUIT DIAGRAM
CIRCUIT DIAGRAM
CHAPTER NO:7
APPLICATIONS
APPLICATIONS
The result is obtained for obstacle avoidance robot using Arduino, if the robot moves
forward if any obstacle detect it check for other directions and moves where there is no
obstacles it moves in forward direction, to sense the obstacle ultrasonic sensor is used.
We used servo motor to rotate the ultrasonic sensor.
The working principle of the robot is transmitting sensed signal to the microcontroller to control the
DC motors for obstacle avoidance. The direction of the motors to move either clockwise or anti-
clockwise directions as provided by the microcontroller. Ultrasonic sensor detect a moving object
while IR sensor does not detect any object, the robot will move backward (motor 1 and motor 2
counter clockwise).
The sensor also detects object, the robot will stop (motor 1 and motor 2 OFF). After 50 ms, motor 1
will move clockwise and the robot will turn left. After 500 ms, the robot will move forward (motor 1
and motor 2 clockwise) and after 1000ms, both motors will stop. From the flow chart in Figure 10, it
shows that the IR sensors are very effective in sensing signals in their path for the obstacle avoiding
robots to evade obstacles in its path.
CHAPTER NO: 9
PROGRAM
// OBSTACLE AVOIDING CAR:
In loop() function, get the distance from HC-SR04 and based on the distance move the motor
direction.
The distance will show the object distance coming in front of the robot.
The Distance is taken by bursting a beam of ultrasonic up to 10 us and receiving it after 10us.
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
digitalWrite(trigPin, HIGH); // send waves for 10 us
delayMicroseconds(10);
duration = pulseIn(echoPin, HIGH); // receive reflected waves
distance = duration / 58.2; // convert to distance
delay(10);
If the distance is greater than the defined distance means there is not obstacle in its path and it will
moving in forward direction.
The goal of our project is to create a autonomous robot which intelligently detects the
obstacle in his path and navigate according to the actions we set for it.
The above Arduino controller and ultrasonic sensor were studied and the HcSR-04 ultrasonic
sensor was selected, as the controlling result are satisfying for its use in the automobile
prototype system bring developed. It was used to sense the obstacle and avoidance them.
On successful implementation of obstacle avoidance algorithm was successfully carried out
too with minimal errors, by coding the algorithm in python. Obstacle avoidance is a very
good application to be used in vehicle preventing many accidents and loss of life.
This project developed an obstacle avoiding robot to detect and avoid obstacles in its path.
The robot is built on the Arduino platform for data processing and its software counterpart
helped to communicate with the robot to send parameters for guiding movement. For
obstacle detection, three ultrasonic distance sensors were used that provided a wider field of
detection. The robot is fully autonomous and after the initial loading of the code, it requires
no user intervention during its operation.
When placed in unknown environment with obstacles, it moved while avoiding all obstacles
with considerable accuracy. In order to optimize the movement of the robot, we have many
considerations for improvement. However, most of these ideas will cost more money and
time as well. In future cameras can be used to detect the obstacle however, it is better to get
CCD or industrial use ones to get clear and fast pictures. Even the ones we mentioned in the
camera holder part will be better because of the special software.
CHAPTER NO: 11
REFERENCES
REFERENCES
[1] Amir attar, aadilansari, abhishek desai, shahid khan, dip ashrisonawale “line follower and
obstacle avoidance bot using arduino” International Journal of Advanced Computational
Engineering and Networking, vol. 2, pp. 740-741, August 1987.
[2] Aniket D. Adhvaryu et al “Obstacle-avoiding robot with IR and PIR motionSensors” IOP
Conference Series: Materials Science and Engineering, vol. A247, pp. 529-551, April 2005.
[3] Vaghela Ankit1, Patel Jigar2, Vaghela Savan3 “Obstacle Avoidance Robotic Vehicle Using
Ultrasonic Sensor, Android And Bluetooth For Obstacle Detection” International Research Journal
of Engineering and Technology (IRJET), vol. A247, pp. 29-32, 2005.
[4] Paul Kinsky,Quan Zhou “Obstacle Avoidance Robot” Worcester polytechnic institute.
[5] FaizaTabassum, SusmitaLopa, Muhammad MasudTarek& Dr. Bilkis Jamal Ferdosi “obstacle
avoidance car”Global Journal of Researches in Engineering: HRobotics & Nano-Tech.
[6] Bhagya shree S R , Manoj kollam “Zigbee Wireless Sensor Network For Better Interactive
Indus
WEBSITES:
https://www.ijcaonline.org/archives/volume56/number5/8885-2882
https://ieeexplore.ieee.org/document/4725791
https://www.sciencedirect.com/science/article/pii/S1877050917302107
http://www.datasheetcatalog.com
http://www.instructabal.com
http://en.wikipedia.org/wiki/Artificial_intelligence
http://science.howstuffworks.com/robot2.htm
http://arduino.cc/en/Main/arduinoBoardUno
Magazines: