Obstracle Avoiding Vehicle
Obstracle Avoiding Vehicle
POLYTECHNIC, AMRUTNAGAR
2020-2021
I st SHIFT (0080)
Amrutvahini Sheti and Shikshan Vikas Sanstha’s
CERTIFICATE
Deshmukh Shriraj Gorake.
Hinde Dharmaraj Hirama
Gite Vaibhav Uttam
Hadawale Tejas Narendra
“OBSTRACAL AVOIDING VEHICLE”
Have satisfactorily carried out and completed the Capstone Project work.
Mechanical Engineering.
MSBTE, Mumbai
(Guide) (H.O.D)
MAHARASHTRA STATE BOARD OF TECHNICAL EDUCATIONMUMBAI
By
Date :
Place : Sangamner.
ACKNOWLEDGEMENT
INTRODUCTION
Now day’s many industries are using robots due to theirhigh level of performance
and reliability and which is a great help for human beings. The obstacle avoidance robotics is
used for detecting obstacles and avoiding the collision. This is an autonomous robot. The design
of the obstacle avoidance robot requires the integration of many sensors according to their task.
LITERATURE SURVEY
Literature Survey-
“obstacle avoidance vehicle using arduino” has been designed and
developed by Aamir attar, Aadilansari, Abhishekdesai, Shahid khan, Dipashrisonawale to create
an autonomous robot which intelligently detects the obstacle in its path and navigates according
to the actions that user set for it. So this system provides an alternate way to the existing system
by replacing skilled labor with robotic machinery, which in turn can handle more patients in less
time with better accuracy and a lower per capita cost [1]. “Obstacle-avoiding robot with IR and
PIR motion Sensors” has been designed and developed by Aniket D. Adhvaryu et al has proposed
that 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 1.6.5 compiler, IR and PIR 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 [2]. “Obstacle
Avoidance Robotic Vehicle Using Ultrasonic Sensor, Android and Bluetooth for Obstacle
Detection” has been designed and developed by Vaghela et.al has mentioned that enormous
amount of work has been done on wireless gesture controlling of robots. Various methodologies
have been analyzed and reviewed with their merits and demerits under various operational and
functional strategies. Thus, it can be concluded that features like user friendly interface, light
weight and portability of android OS based smart phone has overtaken the sophistication of
technologies like programmable glove, static cameras etc., making them obsolete. Although
recent researches in this field have made wireless gesture controlling a ubiquitous phenomenon,
it needs to acquire more focus in relevant areas of applications like home appliances,
wheelchairs, artificial nurses, table top screens etc. in a collaborative manner [3]. “Obstacle
Avoidance Robot” has been designed and developed by Paul Kinsky,Quan Zhou mentioned that
robot with a few mechanical components to add two more functions to the main body, namely
the laptop holder and the camera holder. AT89S52 development board is designed, developed
and tested in a large scale, which was used to control the motors smoothly. the cameras with
relatively low cost are fixed and adjusted on the camera holder for good calibration of the
computer vision.Users establish the serial communication method between the upper laptop and
the lower development board with USB port. The laptop will send out a signal of the motor
condition to the development board [4]. “obstacle avoidance car” has been designed and
developed by FaizaTabassum, et.al has mentioned that Obstacle Avoidance Car successfully
detects and avoids obstacles. Simple algorithms used to steer and reducing the turning radius,
successfully navigated the vehicle. In conclusion, the group successfully interfaced every
component that was originally planned. Timer interrupts for IR pulse generation. Obstacle
detection using IR transceiver. Servo mechanism using PWM. Steering system using Lego.
CHAPTER-3
Block Diagram-
5. 9V Battery. 6. TT Motor
–
1. ARDUINO UNO=
Overview
The Arduino Uno is a microcontroller board based on the ATmega328. It has 20 digital
input/output pins (of which 6 can be used as PWM outputs and 6 can be used as analog inputs), a
16 MHz resonator, a USB connection, a power jack, an in-circuit system programming (ICSP)
header, and a reset button. It contains everything needed to support the microcontroller; simply
connect itto a computer with a USB cable or power it with a AC-to-DC
adapter or battery to get started. The Arduino has a large support community and an extensive set
of support libraries and hardwareadd-on.
1. Motor Drive Control
The L293D is a popular 16- Pin Motor Driver IC. As the name
suggests it is mainly used to drive motors. A single L293D IC is capable of running two DC
motor at the
same time; also the direction of these two motors can be controlled independently. So if you
have motors which has operating voltage less than 36V and operating current less than 600mA,
which are to be controlled by digital circuits like Op-Amp, 555 times, digital gates or even
Micron rollers like Arduino, PIC, ARM etc.. this IC will be the rightchoice for you.
2. Ultrasonic Sensor-
In order to calculate the distance between the sensor and the object, the sensor measures the
time it takes between the emission of the sound by the transmitter to its contact with the
receiver. The formula for this calculation is D = ½ T x C (where Dis the distance, T is the time,
and C is the speed of sound ~ 343 meters/second). For example, if a scientist set up an
ultrasonic sensor aimed at a box and it took 0.025 seconds for the sound to bounce back, the
distance between the ultrasonic sensor and thebox would be:
3. Servo Motor-
Servo motors are rated in kg/cm (kilogram per centimeter) most hobby servo motors are rated at
3kg/cm or 6kg/cm or 12kg/cm. This kg/cm tells you how much weight your servo motor can
lift at a
particular distance. For example: A 6kg/cm Servo motor should be able to lift 6kg if the load is
suspended 1cm away from the motorsshaft, the greater the distance the lesser the weight carrying
capacity. The position of a servo motor is decided by electrical pulse and its circuitry is placed
beside the motor.
4. TT MOTOR-
1.6 TT MOTOR
6.9V Battery-
Circuit diagram
Circuit diagram-
Working Principle
Working Principle-
The ultrasonic sensor emits the short and high-frequency signal. These propagate in the air at the
velocity of sound. If they hit any object, then they reflect an echo signal to the sensor. The ultrasonic
sensor consists of a multivibrator, fixed to the base. The multivibrator is a combination of a resonator
and a vibrator. The resonator delivers ultrasonic wave generated by the vibration. The ultrasonic
sensor consists of two parts; the emitter which produces a 40 kHz sound wave and the detector
detects a 40 kHz sound wave and sends an electrical signal back to the microcontroller.
The ultrasonic sensor enables the robot to virtually see and recognize an object, avoid obstacles,
measure distance. The operating range of the ultrasonic sensor is 10 cm to 30 cm.
CHAPTER -6
APPLICATIONS
Applications-
1. Obstacle avoiding robots can be used in almost all mobile robot navigationsystems.
2. They can be used for household work like automatic vacuum cleaning.
CODEING
Code
#include <AFMotor.h>
#include <NewPing.h>
#include <Servo.h>
#define TRIG_PIN A0
#define ECHO_PIN A1
#define MAX_DISTANCE
200
#define MAX_SPEED 190 // sets speed of DC motors #define
MAX_SPEED_OFFSET 20
AF_DCMotor motor1(1,
MOTOR12_1KHZ); AF_DCMotor
motor2(2, MOTOR12_1KHZ);
AF_DCMotor motor3(3,
MOTOR34_1KHZ); AF_DCMotor
motor4(4, MOTOR34_1KHZ); Servo
myservo;
void loop() {
int distanceR = 0; int
distanceL = 0;
delay(40);
if(distance<=15)
{
moveStop();
delay(100);
moveBackward();
delay(300);
moveStop();
delay(200);
distanceR = lookRight();
delay(200);
distanceL = lookLeft();
delay(200);
if(distanceR>=distanceL)
{
turnRight();
moveStop();
}else
{
turnLeft();
moveStop();
}
}else
{
moveForward();
}
distance = readPing();
}
int lookRight()
{
myservo.write(50);
delay(500);
int distance = readPing();
delay(100); myservo.write(115);
return distance;
}
int lookLeft()
{
myservo.write(170);
delay(500);
int distance = readPing();
delay(100); myservo.write(115);
return distance;
delay(100);
}
int readPing() {
delay(70);
int cm = sonar.ping_cm();
if(cm==0)
{
cm = 250;
}
return cm;
void moveStop() {
motor1.run(RELEASE);
motor2.run(RELEASE);
motor3.run(RELEASE);
motor4.run(RELEASE);
}
void moveForward() {
if(!goesForward)
{
goesForward=true;
motor1.run(FORWARD
);
motor2.run(FORWARD
);
motor3.run(FORWARD
);
motor4.run(FORWARD
);
for (speedSet = 0; speedSet < MAX_SPEED; speedSet +=2) // slowly bring the speed up to
avoid loading down the batteries too quickly
{
motor1.setSpeed(speedSet);
motor2.setSpeed(speedSet);
motor3.setSpeed(speedSet);
motor4.setSpeed(speedSet);
delay(5);
}
}
}
void moveBackward() {
goesForward=false;
motor1.run(BACKWARD)
;
motor2.run(BACKWARD)
;
motor3.run(BACKWARD)
;
motor4.run(BACKWARD)
;
for (speedSet = 0; speedSet < MAX_SPEED; speedSet +=2) // slowly bring the speed up to
avoid loading down the batteries too quickly
{
motor1.setSpeed(speedSet);
motor2.setSpeed(speedSet);
motor3.setSpeed(speedSet);
motor4.setSpeed(speedSet);
delay(5);
}
}
void turnRight() {
motor1.run(FORWARD);
motor2.run(FORWARD);
motor3.run(BACKWARD)
;
motor4.run(BACKWARD)
; delay(500);
motor1.run(FORWARD);
motor2.run(FORWARD);
motor3.run(FORWARD);
motor4.run(FORWARD);
void turnLeft() {
motor1.run(BACKWARD)
;
motor2.run(BACKWARD)
; motor3.run(FORWARD);
motor4.run(FORWARD);
delay(500);
motor1.run(FORWARD);
motor2.run(FORWARD);
motor3.run(FORWARD);
motor4.run(FORWARD);
}
}
CHAPTER NO-8
COSTING
List of Components and Expenses
Breadboard 1 240
Tyres 4 180
Battery 9V 2 80