Documentos de Académico
Documentos de Profesional
Documentos de Cultura
Project Report on
“CELLPHONE –CONTROLLED ROBOT”
Submitted to
Ra jas tha n T echnical Univ ersity, Ko ta
In Partial Fulfillment of the requirement for the award of the degree of
Bachelor of Technology
In
“Electronics & Communication Engineering”
2010-2011
Kapil Sharma
In this project the robot, is controlled by a mobile phone that makes call to the mobile phone
attached to the robot in the course of the call, if any button is pressed control corresponding to
the button pressed is heard at the other end of the call. This tone is called dual tone multi
frequency tome (DTMF) robot receives this DTMF tone with the help of phone stacked in the
robot.
The received tone is processed by the atmega16 microcontroller with the help of DTMF decoder
HT9170 the decoder decodes the DTMF tone in to its equivalent binary digit and this binary
number is send to the microcontroller, the microcontroller is preprogrammed to take a decision
for any give input and outputs its decision to motor drivers in order to drive the motors for
forward or backward motion or a turn. The mobile that makes a call to the mobile phone stacked
in the robot acts as a remote.
So this simple robotic project does not require the construction of receiver and transmitter units.
DTMF signaling is used for telephone signaling over the line in the voice-frequency band to the
call switching centre. The version of DTMF used for telephone tone dialing is known as ‘Touch-
Tone.’
DTMF assigns a specific frequency (consisting of two separate tones) to each key So that it can
easily be identified by the electronic circuit. The signal generated by the DTMF encoder is a
direct algebraic summation, in real time, of the amplitudes of two sine (cosine) waves of
different frequencies.
CHAPTER 1
INTRODUCTION
Robotics is an interesting field where every engineer can showcase his creative and technical
skills. Pleasing aspect of robotics is that a robot can be made indigenously by anyone. In this
competitive world there is need for every enthusiastic, amateur to professional, to make a simple
robot having innovated applications and with robust control.
Mobile phones today became an essential entity for one and all and so, for any mobile based
application there great reception. In this scenario making a mobile phone operated land rover is a
good idea. Conventionally wireless controlled robots utilize RF circuits, which had limitations
like limited range, limited frequency ranges and controls. But a mobile phone controlled robot
can hold up these limitations. It has a robust control, unlimited range (coverage area of the
service provided), no fear of interfering with other controllers and we can have as much as
12controls.
Although the appearance and capabilities of robots vary vastly, all robots share the features of a
mechanical, moveable structure under some form of control. This control of robot involves three
distinct phases: perception, processing and action. In common preceptors are sensors mounted on
the robot, processing is done by on-board microcontroller or processor and task (action) is
performed using motors or with some other actuators.
CHAPTER 2
TECHNOLOGY USED
As a method of in-band signaling, DTMF tones were also used by cable television broadcasters
to indicate the start and stop times of local commercial insertion points during station breaks for
the benefit of cable companies. Until better out-of-band signaling equipment was developed in
the 1990s, fast, unacknowledged , and loud DTMF tone sequences could be heard during the
commercial breaks of cable channels in the US and elsewhere.
2.1.1Telephone keypad
The contemporary keypad is laid out in a3x4 grid, although the original DTMF keypad had an
additional column for four now-defunct menu selector keys. When used to dial a telephone
number, pressing a single key produce a pitch consisting of two simultaneous pure tones
sinusoidal frequencies. The row in which the key appears determines the low frequency, and the
column determines the high frequency. For e.g., pressing the ‘1’ key will result in a sound
composed of both a 697 and a 1209Hz tone. The original keypads had levers inside, so each
button activated two contacts. Multiple tones are the reason for calling the system multi
frequency. These tones are then decoded by the switching center to determine which key was
pressed.
The Engineers had envisioned phones being used to access computers, and surveyed a number of
companies to see what they would need for this role. This led to the addition of number sign (#
sometimes called ‘octothorpe’ in this context) and asterisk or “star” (*) keys as well as a group
of keys for menu selection: A, B, C and D. In the end the lettered keys were dropped from most
phones, and it was many years before these keys became widely used for vertical service codes
such as *67 in United States and Canada for suppressing caller ID.
The U.S. military also used the letters, relabeled in their new defunct Autovon phone system.
Here they were used before dialing the phone in order to give some calls priority, cutting in over
existing calls if need be. The idea was to allow important traffic to get through every time. The
levels of priority available were Flash Override (A), Flash (B), Immediate (C), and Priority (D),
with Flash Override being the highest priority.
The important components of this robot are a DTMF decoder, microcontroller and motor driver.
An HT9170 series DTMF decoder is used here. All types of the HT9170 series use digital
counting techniques to detect and decode all the 16 DTMF tone pairs into a 4-bit code output.
The built-in dial tone rejection circuit eliminates the need of pre-filtering.
When the input signal given at pin 2(IN-) in single-ended input configuration is recognized to be
effective, the correct4-bit decode signal of the DTMF tone is transferred to (pin11) through
(pin14) outputs. The pin11 to pin14 of DTMF decoder are connected to the pins of
microcontroller (pa0 to pa3).The ATmega16 is a low power, 8-bit CMOS microcontroller based
on the AVR enhanced RISC architecture. it provides the following features: 16kb of in-system
programmable flash program memory with read-while-write capabilities, 512 bytes of EEPROM,
1kb SRAM, 32(I\O) lines. Outputs from port pins PD0 through PD3 and PD7 of the
microcontroller are fed to the inputsIN1 through IN4 and enable pins (EN1 and EN2) of motor
driver L293D IC, respectively to drive two geared dc motors. Switch S1 is used for manual reset.
The microcontroller output is not sufficient to drive the dc motors, so current drivers are required
for motor rotation. The L293D is a quad, high-current, half-h driver designed to provide
bidirectional drive currents of upto600mA at voltages from 4.5V to 36V. It makes it easier to
drive the dc motors. The L293D consists of four drivers. Pins IN1 through IN4 and OUT1
through OUT4 are the input and output pins, respectively, of driver 1 through driver 4. Drivers 1
and 2, and driver 3 and 4 are enabled by enable pin 1(EN1) and pin 9 (EN2), respectively.
When enable input EN1 (pin1) is high, drivers 1 and 2 are enabled and the outputs corresponding
to their inputs are active. Similarly, enable input EN2 (pin9) enables drivers 3 and 4 .
TABLE I
697Hz 1 2 3 A
770Hz 4 5 6 B
852Hz 7 8 9 C
941Hz * 0 # D
TABLE II
697 1209 1 H L L L H
697 1336 2 H L L H L
697 1477 3 H L L H H
770 1209 4 H L H L L
770 1336 5 H L H L H
770 1477 6 H L H H L
852 1209 7 H L H H H
852 1336 8 H H L L L
852 1477 9 H H L L H
941 1336 0 H H L H L
941 1209 * H H L H H
941 1477 # H H H L L
697 1633 A H H H L H
770 1633 B H H H H L
852 1633 C H H H H H
941 1633 D H L L L L
2 00000010 11111101
8 00001000 11110111
5 00000101 11111010
3.1 Block Diagram
Phone unit
DTMF decoder
Microcontroller
Motor driver
Phone unit is to give the desired control to the decoder part.
Semiconductors:
HT9170 DTMF decoder
ATMEGA 16 microcontroller
L293D motor driver
74LS04 hex inverting gate
Capacitors:
0.1mF ceramic disk
20pF ceramic disk
33pFceramic disk
Miscellaneous:
3.57MHz crystal
12MHz crystal
SW - Push-to-on switch
M1, M2 - 200-rpm geared DC motor
Bt1, Bt2 - 9V battery
TV Transmitter and Voltage regulator 7805
3.4 Components Details
DTMF Receiver
Features:
General Description:
The HT9170 series are Dual Tone Multi Frequency (DTMF) receivers integrated with digital
decoder and band split filter functions. The HT9170B and HT9170D types supply power-down
mode and inhibit mode operations. All types of the HT9170 series use digital counting
techniques to detect and decode all the 16 DTMF tone pairs into a 4-bit code output. Highly
accurate switched capacitor filters are employed to divide tone (DTMF) signals into low and
high group signals. A built-in dial tone rejection circuit is provided to eliminate the need for pre-
filtering.
Block Diagram:
Functional Description:
Overview:
The HT9170 series tone decoders consist of three band pass filters and two digital decode
circuits to convert a tone (DTMF) signal into digital code output. An operational amplifier is
built-in to adjust the input signal (refer to Figure 2).
Figure 4 Input operation for amplifier application circuits
The pre-filter is a band rejection filter which reduces the dialing tone from 350Hz to 400Hz. The
low group filter filters low group frequency signal output whereas the high group filter filters
high group frequency signal output. Each filter output is followed by a zero-crossing detector
with hysteresis. When each signal amplitude at the output exceeds the specified level, it is
transferred to full swing logic signal. When input signals are recognized to be effective, DV
becomes high, and the correct tone code (DTMF) digit is transferred.
Steering control circuit:
The steering control circuit is used for measuring the effective signal duration and for protecting
against drop out of valid signals. It employs the analog delay by external RC time-constant
controlled by EST.
The timing is shown in Figure 3. The EST pin is normally low and draws the RT/GT pin to keep
low through discharge of external RC. When a valid tone input is detected, EST goes high to
charge RT/GT through RC.
When the voltage of RT/GT changes from 0 to VTRT (2.35V for 5V supply), the input signal is
effective, and the correct code will be created by the code detector. After D0~D3 are completely
latched, DV output becomes high. When the voltage of RT/GT falls down from VDD to VTRT
(i.e.., when there is no input tone), DV output becomes low, and D0~D3 keeps data until a next
valid tone input is produced.
By selecting adequate external RC value, the minimum acceptable input tone duration (tACC)
and the minimum acceptable inter-tone rejection (tIR) can be set. External components (R, C) are
chosen by the formula (refer to Figure 5.):
tACC=tDP+tGTP;
tIR=tDA+tGTA;
where tACC: Tone duration acceptable time
tDP: EST output delay time (_L__H_)
tGTP: Tone present time
tIR: Inter-digit pause rejection time
tDA: EST output delay time (_H__L_)
tGTA: Tone absent time
Application Circuits:
Features:
• Speed Grades
– 0 - 16 MHz for ATmega16
Block Diagram:
Introduction:
This section discusses the AVR core architecture in general. The main function of the CPU core
is to ensure correct program execution. The CPU must therefore be able to access memories,
perform calculations, control peripherals, and handle interrupts.
Architectural Overview:
Block Diagram of the AVR MCU Architecture:
FEATURES:
Featuring Unitrode L293 and L293D Products Now From Texas Instruments
Wide Supply-Voltage Range: 4.5 V to 36 V
Separate Input-Logic Supply
Internal ESD Protection
Thermal Shutdown
High-Noise-Immunity Inputs
Functional Replacements for SGS L293 and SGS L293D
Output Current 1 A Per Channel(600 mA for L293D)
Peak Output Current 2 A Per Channel(1.2 A for L293D)
Output Clamp Diodes for Inductive
Transient Suppression (L293D)
Description:
The L293 and L293D are quadruple high-current half-H drivers. The L293 is designed to provide
Bidirectional drive currents of up to 1 A at voltages from 4.5 V to 36 V. The L293D is designed
to provide bidirectional drive currents of up to 600-mA at voltages from 4.5 V to 36 V. Both
devices are designed to drive inductive loads such as relays, solenoids, dc and bipolar stepping
motors, as well as other high-current/high-voltage loads in positive-supply applications.
All inputs are TTL compatible. Each output is a complete totem-pole drive circuit, with a
Darlington transistor sink and a pseudo-Darlington source. Drivers are enabled in pairs, with
drivers 1 and 2 enabled by 1,2EN and drivers 3 and 4 enabled by 3,4EN. When an enable input is
high, the associated drivers are enabled and their outputs are active and in phase with their
inputs. When the enable input is low, those drivers are disabled and their outputs are off and in
the high-impedance state. With the proper data inputs, each pair of drivers forms a full-H (or
bridge) reversible drive suitable for solenoid or motor applications.
On the L293, external high-speed output clamp diodes should be used for inductive
transient suppression.
A VCC1 terminal, separate from VCC2, is provided for the logic inputs to minimize
device power dissipation.
The L293and L293D is characterized for operation from 0°C to 70°C.
+5V
+9V
16 8
2 3
A
MOTOR
B 7
L293D IC 6
C 10
11
15 MOTOR
D
14
4 5 12 13
GND
This device contains six independent gates each of which performs the logic INVERT function.
Function Table:
Voltage Regulator 7805
(3-Terminal 1A Positive Voltage Regulator)
Description:
The KA78XX/KA78XXA series of three-terminal positive regulator are available in the TO
220/D-PAK package and with several fixed output voltages, making them useful in a wide range
of applications. Each type employs internal current limiting, thermal shut down and safe
operating area protection, making it essentially indestructible. If adequate heat sinking is
provided, they can deliver over 1A output current. Although designed primarily as fixed voltage
regulators, these devices can be used with external components to obtain adjustable voltages and
currents.
Internal Block Diagram:
4.1 Working
In order to control the robot, you need to make a call to the cell phone attached to the robot
(through headphone) from any phone, which sends DTMF tunes on pressing the numeric
buttons. The cell phone in the robot is kept in 'auto answer' mode. (if the mobile does not have
the auto answering facility ,receive the call by 'OK' key on the rover connected mobile and then
made it in hands-free mode.) so after a ring, the cell phone accepts the call. Now you may press
any button on your mobile to perform actions as listed in the table. The DTMF tones thus
produced are received by the cell phone in the robot. These tones are fed to the circuit by headset
of the cell phone. The HT9170 decodes the received tone and sends the equivalent binary
number to the microcontroller. According to the program in the microcontroller, the robot starts
moving, When you press key '2' (binary equivalent 00000010) on your mobile phone, the
microcontroller outputs '10001001' binary equivalent. Port pins PD0, PD3 and PD7 are high. The
high output at PD7 of the microcontroller drives the motor driver (L293D) port pins PD0 and
PD3 drive motors M1 and M2 in forward direction( as per table ).Similarly, motors M1 and M2
move for left turn, right turn, backward motion and stop condition as per (table ).
4.2 Construction
When constructing any robot, one major mechanical constraint is the number of motors being
used. You can have either a two-wheel drive or a four-wheel drive. Though four-wheel drive is
more complex than two-wheel drive, it provides more torque and good control.
Top view of a four-wheel-drive land rover is shown in Fig.3. The chassis used in this model is a
10 x 18 cm2 sheet made up of par ax. Motors are fixed to the bottom of this sheet and the circuit
is affixed firmly on top of the sheet. A cell phone is also mounted on the sheet as shown in the
picture.
In the four-wheel drive system, the two motors on a side are controlled in parallel. So a single
L293D driver IC can drive the rover. For this robot, beads affixed with glue act as support
wheels.
The software is written in ‘C’ language and compiled using Code Vision AVR ‘C’ compiler. The
source program is converted into hex code by the compiler. Burn this hex code into ATmega16
AVR microcontroller.
The source program is well commented and easy to understand. First include the register name
defined specifically for ATmega16 and also declare the variable. Set port A as the input and port
D as the output. The program will run forever by using ‘while’ loop. Under ‘while’ loop, read
port A and test the received input using ‘switch’ statement. The corresponding data will output at
port D after testing of the received data.
#include <mega16.h>
Void main (void)
{
Unsigned int k, h;
DDRA=0x00;
DDRD=0XFF;
While (1)
{
k =~PINA;
h=k & 0x0F;
Switch (h)
{
Case 0x02:
{
PORTD=0x89;
Break;
}
Case 0x08:
{
PORTD=0x86;
Break;
}
Case 0x04:
{
PORTD=0x85;
Break;
}
Case 0x06:
{
PORTD=0x8A;
Break;
}
Case 0x05:
{
PORTD=0x00;
Break;
}
}
}
}
5.2 Hex Code of the Programme
: 100000000C942B000C9400000C9400000C94000045
: 100010000C9400000C9400000C9400000C94000060
: 100020000C9400000C9400000C9400000C94000050
: 100030000C9400000C9400000C9400000C94000040
: 100040000C9400000C9400000C9400000C94000030
: 100050000C9400000000F894EE27ECBBF1E0FBBF2D
: 10006000EBBFE5BFF8E1F1BDE1BD8DE0A2E0BB274C
: 10007000ED938A95E9F780E094E0A0E6ED9301978F
: 10008000E9F7E4E5F0E085919591009761F0A5919D
: 10009000B59105901590BF01F00105900D92019763
: 1000A000E1F7FB01F0CFEFE5EDBFE4E0EEBFC0E626
: 1000B000D1E00C945B00E0E0EABBEFEFE1BBE9B319
: 1000C000E0950E2F1127F801EF70F0709F01F901F4
: 1000D000E230A0E0FA0711F4E9E817C0E830A0E048
: 1000E000FA0711F4E6E811C0E430A0E0FA0711F4D1
: 1000F000E5E80BC0E630A0E0FA0711F4EAE805C035
: 10010000E530A0E0FA0711F4E0E0E2BBD8CFFFCF82
: 00000001FF
CHAPTER 6
Cell phone acts as a DTMF generator with tone depending upon key pressed. DTMF decoder i.e.
IC HT9170 decodes the received tone and gives binary equivalent of it to the microcontroller.
The controller is programmed such that appropriate output is given to motor driver IC L293D
which will drive the two DC motors connected to it. The concept used for driving is ‘differential
drive’. So ultimately the two motors rotate according to the key pressed on the keypad of the cell
phone.
CHAPTER 7
7.1Applications
7.1.1Scientific
Remote control vehicles have a various scientific uses including hazardous environments,
working in the Deep Ocean, and space exploration. The majority of the probes to the other
planets in our solar system have been remote control vehicles, although some of the more recent
ones were partially autonomous. The sophistication of these devices has fueled greater debate on
the need for manned space flights and exploration. The voyager I spacecraft is the first craft of
any kind to leave the solar system. The Martian explorers Spirit and Opportunity have provided
continuous data about the surface of Mars since January 3, 2004.
Remote controlled vehicles are used in Law enforcement and military engagements because of
many reasons. The exposures to hazards are mitigated to the person who operates the vehicle
from the location of relative safety. They are used by many police department bomb-squads to
defuse or detonate explosives.
Current Unmanned Aerial Vehicles (UAVs) can hover around possible targets until they are
positively identified before releasing their pay load of weaponry. Backpack sized UAVs will
provide ground troops with over the horizon surveillance capabilities.
7.1.3 Search and Rescue
UAVs play an increased role in search and rescue all over the world. This was demonstrated by
the successful use of UAVs during the 2008 hurricanes that struck Louisiana and Texas in US.
Small scale remote control vehicles span a wide range in terms of price and sophistication. There
are many types like on-road cars, off-road truck, boats, aero planes and helicopters. Radio-
controlled submarine also exist
7.2.1 IR Sensors:
IR sensors can be used to automatically detect and avoid obstacles if the robot goes beyond line
of sight. This avoids damage to the vehicle if we are maneuvering it from a distant place.
Project can be modified in order to password protect the robot so that it can be operated only if
correct password is entered. Either cell phone should be password protected or necessary
modification should be made in the assembly language code. This introduces conditioned access
and increases security to a great extent.
7.2.3 Alarm Phone Dialer
By replacing DTMF Decoder IC HT9170 by a ‘DTMF Transceiver IC’, DTMF tones can be
generated from the robot. So, a project called ‘Alarm Phone Dialer’ can be built which will
generate necessary alarms for something that is desired to be monitored (usually by triggering a
delay). For e.g., a high water alarm, low temperature alarm, opening of back window, garage
door etc.
When the system is activated it will call a number of programmed numbers to let the user know
the alarm has been activated. This would be great to get alerts of alarm conditions from home
when user is at work.
If the current land rover is interfaced with a camera (e.g. a web cam) robot can be driven beyond
line-of-sight and range becomes unlimited as GSM networks have a very large range.
.
CHAPTER 8
CONCLUSION
Conventionally, wireless-controlled robots use RF circuits, which have the drawbacks of limited
working range, limited frequency range and limited control. Use of a mobile phone for robotic
control can overcome these limitations. It provides the advantages of robust control, working
range as large as the coverage area of the service provider, no interference with other controllers
and up to twelve controls. Although the appearance and capabilities of robots vary vastly, all
robots share the features of a mechanical, movable structure under some form of control. The
control of robot involves three distinct phases: perception, processing and action. Generally, the
preceptors are sensors mounted on the robot, processing is done by the on-board microcontroller
or processor, and the task (action) is performed using motors or with some other actuators.
REFERENCES
3. http://en.wikipedia.org/wiki/Passive_infrared_sensor
4. http://www.alldatasheet.com
5. http://www.datasheet4u.com
6. http://www.datasheetcatalog.com
APPENDICES
ATmega 16 Microcontroller
Pin Configurations:
Pin Descriptions:
GND Ground
Port B is an 8-bit bi-directional I/O port with internal pull-up resistors (selected for each bit).
The Port B output buffers have symmetrical drive characteristics with both high sink and source
capability. As inputs, Port B pins that are externally pulled low will source current if the pull-up
resistors are activated. The Port B pins are tri-stated when a reset condition becomes active, even
if the clock is not running. Port B also serves the functions of various special features of the
ATmega16.
RESET
Reset Input. A low level on this pin for longer than the minimum pulse length will generate a
reset, even if the clock is not running. The minimum pulse length is Shorter pulses are not
guaranteed to generate a reset.
XTAL1
Input to the inverting Oscillator amplifier and input to the internal clock operating circuit.
XTAL2
Output from the inverting Oscillator amplifier.
AVCC
AVCC is the supply voltage pin for Port A and the A/D Converter. It should be externally
connected to VCC, even if the ADC is not used. If the ADC is used, it should be connected to
VCC through a low-pass filter.
AREF AREF is the analog reference pin for the A/D Converter.
HT9170 DTMF Decoder IC
Pin Assignment:
Pin Description:
Contacts for more Info:-
Kapil Sharma
Kapil2010sharma@gmail.com (+91 8003535095)