Академический Документы
Профессиональный Документы
Культура Документы
PREFACE
The main objective of this project is to design an obstacle
detection and collision avoidance robot with help of IR sensors
embedded around the body of robotic vehicle. This design can be
used in fully automated vehicles like cars, moving materials in
industries and similar other commercial applications. Starting with
an overview of the system the document would cover
implementation details like components used, circuits and
algorithms, problems faced during designing of the obstacle
detection and collision avoidance robot. It has also been
described that how the microcontroller program has been
embedded in the microcontroller with the help of a burner device.
Some suggestions on improving the design and its commercial
application have also been discussed in the later part of the
document.
The Reference and Resources page has a list of relevant books,
websites, electronic shops and commonly used parts & their
prices.
1
ROVER 2010
ABSTRACT
The robot uses three IR sensors to sense any obstacle in its path.
The data coming from those sensors are fed into voltage
comparators where the sensor data is compared with a fixed
reference voltage. After the comparison of sensor data and the
Vref, the voltage comparator gives output as OV for presence of
any obstacle and 5 V for absence of obstacle. This output of
comparator circuit is fed into the microcontroller in which decision
making program is stored .The microcontroller process uses the
output of comparator circuit according to the program stored in it
and gives output at another port. The output of microcontroller is
fed into the motor driver circuit which amplifies the low output
current coming from microcontroller so that its output becomes
capable to drive the DC motors fitted in the robotic vehicle base.
2
ROVER 2010
3
ROVER 2010
4
ROVER 2010
• Pin 0 .1 - Front sensor
For motor 1
• Pin1.0 .
• Pin 1.1
For motor 2
• Pin2.0
• Pin 2.1
Eight 10k pull up resistors are connected to the microcontroller
at port P0. Rest of the ports have inbuilt pullup resistors, so there
is no need to connect pull-up resistors to port1 , port2 and port3.
COMPONENTS USED
• Microcontroller (AT89S52)
• Motor Driver(L293D)
• Timer (LM555)
• DC Motor
• Voltage Regulator(LM7805)
• Variable Resistance
IR Transmitter
5
ROVER 2010
The IR Transmitter block is used to generate IR signal. It uses
timer IC555 in astable multivibrator mode to generate square
wave which have continuous pulses of 50% duty cycle of
frequency 38 KHz.
6
ROVER 2010
Description
7
ROVER 2010
IR sensor (TSOP 1738) which gives normally 5v at its
output but. after receiving infrared light , output of sensor is 0v.
Features
8
ROVER 2010
• Improved shielding against electrical field disturbance
9
ROVER 2010
IR sensor Module
MICROCONTROLLER
(AT89S52)
The AT89S52 is a low-power, high-performance CMOS 8-bit
microcomputer with 8 Kbytes of Flash programmable and
10
ROVER 2010
erasable read only memory (PEROM). The device is manufactured
using Atmels high density nonvolatile memory technology and is
compatible with the industry standard 80C51 instruction set and
pin out.
The on-chip Flash allows the program memory to be
reprogrammed in system or by a conventional nonvolatile
memory programmer. By combining a versatile 8-bit CPU with
Flash on a monolithic chip the Atmel AT89S52 is a powerful
microcomputer which provides a highly flexible and cost effective
solution to many embedded control applications.
AT89S52
Pin Configurations:
11
ROVER 2010
Pin Description
Vcc
Supply voltage
GND
Ground
Port 0
12
ROVER 2010
Port 1
Port 1 can be used as input or output, In contrast to port 0, this port does
not need any pull-up resistors since it already has pull-up resistors internally. Upon
reset, port 1 is configured as an input port. To make port 1 an input port, it
must be programmed as such by writing 1to all its bits
Port 2
Port 3
13
ROVER 2010
RST
Reset input. A high on this pin for two machine cycles while the
oscillator is running resets the device.
ALE/PROG
Address Latch Enable is an output pulse for latching the low byte
of the address during access to external memory. This pin is also
the program pulse input (PROG) during Flash programming.
In normal operation ALE is emitted at a constant rate of 1/6 the
oscillator frequency and may be used for external timing or
clocking purposes.
XTAL1
Input to the inverting oscillator amplifier and input to the internal
clock operating circuit.
XTAL2
Output from the inverting oscillator amplifier
14
ROVER 2010
15
ROVER 2010
MOTOR DRIVER
(L293D)
The Device is a monolithic integrated high voltage, high current
driver designed to accept standard TTL logic levels and drive
inductive loads (such as relays solenoids, DC and stepping
motors) and switching power transistors.
Specifications
. Supply Voltage Range 4.5V to 36V
. 600-mA Output current capability per driver
. Separate input- logic supply
16
ROVER 2010
Thermal Shutdown
High-Noise-immunity inputs
PIN CONFIGURATION
Pinout of L293D
Circuit implementation
L293D
L293D motor driver needs two voltage levels
• 12V at pin no.8
• 5V at pin no. 1 ,9 and 16.
The main function of driver is to amplify the 15mA current,
17
ROVER 2010
coming from the microcontroller which is incapable to drive 50mA
rating motor it can give output current upto 600mA.
The driver circuit basically consists two H-bridges for diving small
DC motors. In a H-bridge circuit there are four transistors of which
only two are in ON state which are located diagonally. The two
pairs of transistors gives the bidirectional rotation of motor.
18
ROVER 2010
OTHERS
TIMER
(LM555)
General Description
LM555
19
ROVER 2010
ASTABLE OPERATION
20
ROVER 2010
Dc Motor(45rpm)
VOLTAGE REGULATOR
(LM7805)
The LM78M05, a three-terminal positive voltage regulator
employs built-in current limiting, thermal shutdown, and
protection mechanism which makes them virtually immune to
damage from output overloads. With adequate heat sinking, they
can deliver in excess of O.5A output current.
Features
21
ROVER 2010
CIRCUIT IMPLEMENTATION
voltage Regulator is needed as because we have different voltage
level requirement in different components e.g motor requires 12v
supply but circuits like microcontroller board and voltage
comparator require only 5 V supply.
LM7805
22
ROVER 2010
VARIABLE RESISTANCE
Mechanical design
It is made up of light weight material , steel which provides easy
movement of the robotic vehicle. It has folowing provisions in it:
• Slot for DC motors.
23
ROVER 2010
ALGORITHM
While (1)
if left_obstacle
Stop
Move back
Move right
elseif right_obstacle
Stop
Move back
Move left
elseif front_obstacle
Stop
Move back
24
ROVER 2010
Move left
Stop
Move back
Move right
Stop
Move back
Move left
Stop
Move back
Move left
{
25
ROVER 2010
Stop
Move back
Move left
else
Move forward
26
ROVER 2010
SCREEN SHOTS OF KEIL PROGRAMING
27
ROVER 2010
28
ROVER 2010
29
ROVER 2010
30
ROVER 2010
31
ROVER 2010
32
ROVER 2010
33
ROVER 2010
34
ROVER 2010
35
ROVER 2010
36
ROVER 2010
PROBLEMS FACED
37
ROVER 2010
The first microcontroller we used had its write enable
failed. Perhaps it was damaged during transportation.
Then we used other microcontroller but after burning the
microcontroller using the first code it seemed that no
program was written at all in the flash memory. Later on
we found that the microcontroller had some inherent
problem and we had to replace it.
Keil programming
FUTURE SCOPE
38
ROVER 2010
Some of the improvements that can be made are the following:
DATA SHEETS
39
ROVER 2010
40
ROVER 2010
41
ROVER 2010
42
ROVER 2010
43
ROVER 2010
44
ROVER 2010
45
ROVER 2010
46
ROVER 2010
47
ROVER 2010
REFERENCE AND RESOURCES
• Wikipedia/microcontroller
• www.engineeringprojects.org
• http://indianengineer.blog.co.in
• www.8051projects.com
48