project · pdf file · 2014-12-22we take an opportunity to present this project...
TRANSCRIPT
DTMF Controlled Robot
1
DTMF Controlled Robot
PROJECT
Submitted in complete fulfillment of the requirements
for the degree of
BACHELOR OF ENGINEERING
BY
Ronak Khara
Rinku Rohira
Shantanu Khare
Sheetal Daldani
Under the Guidance of
PROF.MRS.Archana Singhi
(Internal Guide)
Mrs. Sunita Sharma
(Head of the Department)
DEPARTMENT OF ELECTRONICS
AND TELECOMMUNICATION ENGINEERING
WATUMULL INSTITUTE OF ELECTRONICS
ENGINEERING AND COMPUTER TECHNOLOGY, MUMBAI
UNIVERSITY OF MUMBAI
2011-2012
DTMF Controlled Robot
2
WATUMULL INSTITUTE OF ELECTRONICS
ENGINEERING & COMPUTER TECHNOLOGY
AN AFFILIATE OF THE UNIVERSITY OF MUMBAI
CERTIFICATE
This is to certify that the following students have submitted the report for their final year
project on “DTMF Controlled Robot” under the guidance of Mrs. Archana Singhi in
partial fulfillment of requirement for the degree of Bachelor of Engineering (Electronics
and Telecommunication) of the University of Mumbai in the academic year 2011-2012.
Ronak Khara Rinku Rohira Shantanu Khare Sheetal Daldani
Internal Examiner External Examiner
Mrs. ARCHANA SINGHI Mrs. SUNITA SHARMA
Internal Guide Head of the Department
Mrs. SANDYA DESAI
Principal
Plot 47, DR. RG THADANI MARG,WORLI SEAFACE,WORLI,MUMBAI-400018.
INDIA
TEL : 91-22-2493 5281,2497 4858,2497 1506. FAX : 91-22-2491 5103
E-Mail :[email protected]
DTMF Controlled Robot
3
ACKNOWLEDGEMENT
Among the wide panorama of people who provided us help and motivation to complete
our project, we are grateful in presenting to you the rare shades of technology by
documenting project DTMF Controlled Robot.
We wish to express our deep sense of gratitude to our Head Of Department Prof Mrs.
Sunita Sharma for giving us her precious hour to our endeavor. We gratefully
acknowledge her generous help in providing us with relevant information, data comments
and manuscripts. Her encouragement proved to be boon in the path of our achievement.
We are thankful to our guide, Mrs. Archana Singhi for giving us valuable inputs and
helped us directly or indirectly in the development of this project. We also thank lab
technician Vijayan sir and Prabhakar sir and other non teaching staff of our Electronics
and Telecommunication for their help during the development of this project.
We also thank our colleagues to help us make our project a success.
Above all we thank our principal Mrs. Sandya Desai for providing us the facilities to
bring a success.
Ronak Khara Rinku Rohira Shantanu Khare Sheetal Daldani
DTMF Controlled Robot
4
PREFACE
We take an opportunity to present this project report on "DUAL TONE
MULTIPLE FREQUENCY (DTMF) CONTROLLED ROBOT" and put before
readers some useful information regarding our project.
We have made sincere attempts and taken every care to present this matter in
precise and compact form, the language being as simple as possible.
We are sure that the information contained in this volume would certainly prove
useful for better insight in the scope and dimension of this project in its true perspective.
The task of completion of the project though being difficulty was made quite
simple, interesting and successful due to deep involvement and complete dedication of
our group members.
DTMF Controlled Robot
5
Index:
Sr no. Topic Page number
1 Introduction 1
2 Block Diagram 4
3 Circuit Diagram 10
4 Working of Circuit 13
5 Software Development 16
6 PCB Fabrication 23
7 Different Components used 27
8 Advantages & Disadvantages 38
9 Applications 40
10 Future Scope 43
11 Troubleshooting 45
12 Conclusion 47
13 Bibliography 49
14 Data Sheets 51
DTMF Controlled Robot
6
Figure Index:
Sr no. Topic Page number
1 Circuit Image 3
2 Block Diagram 5
3 DTMF table 7
4 Circuit diagram 11
5 Network working 15
6 Microcontroller pin diagram 53
7 Microcontroller block diagram 54
8 Oscillator Connections 56
9 External Clock Drive Configuration 56
DTMF Controlled Robot
9
1.1 DTMF CONTROLLED ROBOT :-
Conventionally, Wireless-controlled robots use RF circuits, which have the
drawbacks of limited working range, limited frequency range and the limited control.
Use of a mobile phone for robotic control can overcome these limitations. It provides
the advantage of robust control, working range as large as the coverage area of the
service provider, no interference with other controllers and up to twelve controllers.
Although the appearance and the capabilities of robots vary vastly, all robots share
the feature 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 is performed using motors or with
some other actuators.
Man has come long way In terms of development over a period of time we would use
the RF modules for the purpose wireless after that we overcome with the techniques of
GSM modems and we use the DTMF in wireless system.
The DTMF technology has overcome the problem of limitation which we can work
only in limited range or limited area was in RF technology by using cell phone (DTMF).
We can access our device or the robot as large as the working space of the service
provider, no interference with other controllers and up to 12 controls.
DTMF Controlled Robot
13
2.2 DESCRIPTION ABOUT BLOCK DIAGRAM:-
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, a
tone corresponding to the button pressed is heard at the other end of the call. This tone
is called ‘DUAL –TONE MULTIPLE-FREQUENCY’ (DTMF) tone. The 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 MT8870. 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 center. The version of DTMF used for telephone
dialing is known as ‘Touch –Tone’.
DTMF assigns a specific frequency (consisting of two separate tones) to each key s
that it can easily be identified by the electronic circuit.
The signal generated by the DTMF encoder is the direct al-gebraic submission, in
real time of the amplitudes of two sine (cosine) waves of different frequencies, i.e.,
pressing ‘5’ will send a tone made by adding 1336Hz and 770Hz to the other end of the
mobile. The tones and assignments in a DTMF system shown below
DTMF Controlled Robot
14
Figure2.2- DTMF table
2.3 DTMF BASICS:-
DTMF, or tone dialing, is very commonly used. DTMF (Dual-tone Multi
Frequency) is a tone composed of two sine waves of given frequencies. Individual
frequencies are chosen so that it is quite easy to design frequency filters, and so that they
can easily pass through telephone lines (where the maximum guaranteed bandwidth
extends from about 300 Hz to 3.5 kHz).
DTMF was not intended for data transfer; it is designed for control signals only.
With standard decoders, it is possible to signal at a rate of about 10 "beeps" (=5 bytes)
per second.
DTMF standards specify 50ms tone and 50ms space duration. For shorter lengths,
synchronization and timing becomes very tricky.
DTMF Controlled Robot
15
2.4 DTMF USAGE: -
DTMF is the basis for voice communications control. Modern telephony uses
DTMF to dial numbers, configure telephone exchanges (switchboards), and so on.
Occasionally, simple floating codes are transmitted using DTMF - usually via a CB
transceiver (27 MHz). It is used to transfer information between radio transceivers, in
voice mail applications, etc.
Almost any mobile (cellular) phone is able to generate DTMF after establishing
connection. If your phone can't generate DTMF, you can use a stand-alone "dialer".
DTMF was designed so that it is possible to use acoustic transfer, and receive the codes
using standard microphone.
2.5 COMPOSITION OF DTMF signals:-
The table shows how to compose any DTMF code. Each code, or "beep",
consists of two simultaneous frequencies mixed together (added amplitudes). Standards
specify 0.7% typical and 1.5% maximum tolerance. The higher of the two frequencies
may have higher amplitude (be "louder") of 4 dB max.
This shift is called a "twist". If the twist is equal to 3 dB, the higher frequency is
3 dB louder. If the lower frequency is louder, the twist is negative.
Frequency table:
1209 Hz 1336 Hz 1477 Hz 1633 Hz
697 Hz 1 2 3 A
770 Hz 4 5 6 B
852 Hz 7 8 9 C
941 Hz * 0 # D
DTMF Controlled Robot
16
This table resembles a matrix keyboard. The X and Y coordinates of each code
give the two frequencies that the code is composed of. Notice that there are 16 codes;
however, common DTMF dialers use only 12 of them. The "A" through "D" is "system"
codes. Most end users won't need any of those; they are used to configure phone
exchanges or to perform other special functions.
2.6 How to transmit and to decode DTMF:-
To transmit DTMF:
Most often, dedicated telephony circuits are used to generate DTMF (for
example, MT8880). On the other hand, a microprocessor can do it, too. Just connect a RC
filter to two output pins, and generate correct tones via software. However, getting the
correct frequencies often requires usage of a suitable Xtal for the processor itself - at the
cost of non-standard cycle length, etc. So, this method is used in simple applications only.
To decode DTMF:
It is not easy to detect and recognize DTMF with satisfactory precision. Often,
dedicated integrated circuits are used, although a functional solution for DTMF
transmission and receiving by a microprocessor (a PIC in most cases) exists. It is rather
complicated, so it is used only marginally. Most often, a MT 8870 or compatible circuit
would be used.
Most decoders detect only the rising edges of the sine waves. So, DTMF generated by
rectangular pulses and RC filters works reliably. The mentioned MT 8870 uses two 6th
order band pass filters with switched capacitors. These produce nice clean sine waves
even from distorted inputs, with any harmonics suppressed.
DTMF Controlled Robot
19
3.2 DESCRIPTION ABOUT CIRCUIT DIAGRAM:
A figure shows the block diagram and circuit diagram of the microcontroller-
based robot. The important components of this robot are DTMF decoder, Microcontroller
and motor driver.
An MT8870 series DTMF decoder is used here. All types of the mt8870 series use
digital counting techniques to detect and decode all the sixteen DTMF tone pairs in to a
four bit code output. The built -in dial tone rejection circuit eliminated the need for pre-
filtering. When the input signal given at pin2 (IN-) single ended input configuration is
recognized to be effective, the correct four bit decode signal of the DTMF tone is
transferred to Q1 (pin11) through Q4(pin14) outputs.
The ATmega 16 is a low power, 8 bit; CMOS microcontroller based on the
AVR enhanced RISC architecture. It provides the following feature: 16kb of in system
programmable flash memory with read write capabilities, 512bytes of EEPROM, 1KB
SRAM, 32 general purpose input/output lines. 32 general purpose working registers. All
the 32 registers are directly connected to the arithmetic logic unit, allowing two
independent registers to be accessed in one signal instruction executed in one clock cycle.
The resulting architecture is more code efficient.
Outputs from port pins PD0 through PD3 and PD7 of the microcontroller are
fed to inputs IN1 through IN4 and enable pins (EN1 and EN2) of motor driver L293d
respectively, to drive geared motors. Switch S1 is used for manual reset. The
microcontroller output is not sufficient to drive the DC motors, so currently drivers are
required for motor rotation.
The L293D is a quad, high current, half-H drive designed to provide
bidirectional drive currents of up to 600mA at voltage from 4.5V to 36V. It makes it
easier to drive the DC motors. Pins IN1 through IN4 and OUT1 through OUT4 are input
and out pins, respectively, of driver 1 through driver 4. Drivers 1 and 2, and Drivers 3 &
4 are enabled by enable pin 1 (EN1) and pin 9 (En2), respectively. When enable input
En1 (pin 1) is high, drivers 1 & 2 are enabled and the outputs corresponding to their
inputs are active. Similarly, enable input EN2 (pin9) enables drivers 3 and
DTMF Controlled Robot
21
4.1 Working:
In order to control the robot, you need to make a call to the cell phone attached to
the robot (through head phone) 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
vehicle connected mobile end 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 below:
When you press 1 the robot will move forward
When you press 4 the robot will move left
When you press 2 the robot will move backwards
When you press 3 the robot will move right
When you press 5 the robot will stop.
The DTMF tones thus produced are received by the cell phone in the robot.
These tones are fed to the circuit by the headset of the cell phone. The MT8870 decodes
the received tone and sends the equipment binary number to 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 drivers the motor driver (L293D).
Port pins PD0 and PD3 drive motors M1 and M2 in forward direction. Similarly,
motors M1 and M2 move for left turn, right turn, backward motion and stop
condition.
DTMF Controlled Robot
24
5.1 SOFTWARE PROJECT MANAGEMENT PLAN
Conventionally, Wireless-controlled robots use RF circuits, which have the
drawbacks of limited working range, limited frequency range and the limited control. Use of
a mobile phone for robotic control can overcome these limitations.
It provides the advantage of robust control, working range as large as the coverage
area of the service provider, no interference with other controllers and up to twelve
controllers.
5.2 Project Deliverables:
The following are the deliverables of the Project:
1. GUIs made using Microsoft Visual Studio
2. Database using Microsoft Access
3. Executable Files.
4. DLL Files.
5. Help Files.
5.3 PROJECT ORGANIZATIONS
Software Process Model
The model used is Classic Life Cycle Model
The Project team is meeting once a week to discuss the progress made by each
member and to share the relevant information and be documents that have been
prepared. The number of meetings may increase during the final semester as the team
members will have more time.
There are reviews being conducted once a week during the team meetings. A
complete technical review will be conducted at the end of the Design Phase. There
will be reviews conducted at the completion of every testing phase.
The major milestones to be achieved are as follows:
DTMF Controlled Robot
25
1. Results of research of existing system and discussions with the Project
leader.
2. Results of interview with experts and team meetings to finalize the
requirements of the software.
3. Results of the Design Phase, which include a number of modeling
diagrams, like the use cases, class diagrams, etc.
4. Results of the first coding phase will be an initial code that will be then
tested.
5. Based on the results of the testing, they code will be reviewed in the
second coding phase.
Tools and Techniques
We will require the following tools:
1. Microsoft Visual Studio 2005.
2. Microsoft Office 2003.
Tasks
The following tasks are to be executed:-
1. Requirement Analysis Phase 1
2. Requirement Analysis Phase 2
3. Design of System
4. Coding Phase 1
5. Coding Phase 2
6. Testing Phase 1
DTMF Controlled Robot
26
Requirement analysis:
1. Requirement Analysis Phase 1:
This will include the research of existing software and a discussion with the Project
guide.
2. Requirement Analysis Phase 2:
Based on the above results, the project team will discuss and finalize the requirements
that are to be provided. We shall consult a number of experts during this phase. The
SPMP shall also be prepared during this phase.
Design Phase:
The design phase will involve the design of the static view, dynamic view, and the
functional view of the software. A number of diagrams including the Use case, class
diagram, activity diagram, and data flow diagrams will be used to model the software.
Also, the GUIs will be designed during this phase
Coding Phase 1:
The prerequisite to this phase is the study of Microsoft Visual basic6. After this
study, an initial code of the entire project will be written. Also, the database will be
created during this phase. Finally, we shall conduct unit tests.
Coding Phase 2:
This phase will include a review of the code created in Phase 1. After the review,
the necessary code and database will be modified to include the results of review.
Testing Phase:
We shall be following a testing program that will involve unit testing, integration
testing, and validation testing. More information will be known after further discussion.
5.4 SOURCE PROGRAM: ROBOT.C
DTMF Controlled Robot
27
Include C \ \ Code \ BCD_lib.Lib
Include C \ \ Code \89Sxx.Lib
Include C \ \ Code \Variable.Lib
Main:
If P1.0 = 1 then
Gosub decode_data
End if
Goto main
Decode_data:
Portval [0] = P1.1
Portval [1] = P1.2
Portval [2] = P1.3
Portval [3] = P1.4
Waitms 100
Gousb check
Return
Check:
Select Case Portval
Case 1:
P0.0 = 0
P0.1 = 0
P0.2 = 0
P0.3 = 0
Waitms 50
Case 2:
P0.0 = 1
P0.1 = 0
P0.2 = 1
P0.3 = 0
Waitms 50
DTMF Controlled Robot
28
Case 3:
P0.0 = 0
P0.1 = 1
P0.2 = 0
P0.3 = 1
Waitms 50
Case 4:
P0.0 = 1
P0.1 = 0
P0.2 = 0
P0.3 = 0
Waitms 50
Case 5:
P0.0 = 0
P0.1 = 0
P0.2 = 1
P0.3 = 0
Waitms 50
Case else
Goto main
End Select
Goto Main
P0.3 = 0
Wait 2
P0.0 = 0
P0.1 = 1
P0.2 = 0
P0.3 = 1
Wait 2
P0.0 = 0
P0.1 = 0
DTMF Controlled Robot
31
6.1 P.C.B. MAKING
P.C.B. is printed circuit board which is of insulating base with layer of thin
copper-foil.
The circuit diagram is then drawn on the P. C. B. with permanent marker and then
it is dipped in the solution of ferric chloride so that unwanted copper is removed
from the P.C.B., thus leaving components interconnection on the board.
The specification of the base material is not important to know in most of the
application, but it is important to know something about copper foil which is
drawn through a thin slip.
The resistance of copper foil will have an affect on the circuit operation.
Base material is made of lamination layer of suitable insulating material such as
treated paper, fabric; or glass fibers and binding them with resin. Most commonly
used base materials are formed paper bonded with epoxy resin.
It is possible to obtain a range of thickness between 0.5 mm to 3 mm.
Thickness is the important factor in determining mechanical strength particularly
when the commonly used base material is “Formea” from paper assembly.
Physical properties should be self supporting these are surface resistivity, heat
dissipation, dielectric, constant, dielectric strength.
Another important factor is the ability to withstand high temperature.
6.2 DESIGNING THE LAYOUT
While designing a layout, it must be noted that size of the board should be as
small as possible.
DTMF Controlled Robot
32
Before starting, all components should be placed properly so that an accurate
measurement of space can be made.
The component should not be mounted very close to each other or far away from
one another and neither one should ignore the fact that some component reed
ventilation, which considerably the dimension of the relay and transformer in
view of arrangement, the bolting arrangement is also considered.
The layout is first drawn on paper then traced on copper plate which is finalized
with the pen or permanent marker which is efficient and clean with etching.
The resistivity also depends on the purity of copper, which is highest for low
purity of copper. The high resistance paths are always undesired for soldered
connections.
The most difficult part of making an original printed circuit is the conversion
from, theoretical circuit diagram into wiring layout. Without introducing cross
over and undesirable effect.
Although it is difficult operation, it provides greaten amount of satisfaction
because it is carried out with more care and skill.
The board used for project has copper foil thickness in the range of 25 40 75
microns.
The soldering quality requires 99.99% efficiency.
It is necessary to design copper path extra large. There are two main reasons for
this.
i. The copper may be required to carry an extra large overall current.
ii. It acts like a kind of screen or ground plane to minimize the effect of interaction.
The first function is to connect the components together in their right sequence
with minimum need for interlinking i.e. the jumpers with wire connections.
It must be noted, that when layout is done, on the next day it should be dipped in
the solution and board is move continuously right and left after etching perfectly
the board is cleaned with water and is drilled.
DTMF Controlled Robot
33
After that holes are drilled with 1 mm or 0.8 mm drill. Now the marker on the P.
C. B. is removed.
The Printed Circuit Board is now ready for mounting the components on it.
6.3 SOLDERING:
For soldering of any joints first the terminal to be soldered are cleaned to remove
oxide film or dirt on it. If required flux is applied on the points to be soldered.
Now the joint to be soldered is heated with the help of soldering iron. Heat
applied should be such that when solder wire is touched to joint, it must melt
quickly.
The joint and the soldering iron is held such that molten solder should flow
smoothly over the joint.
When joint is completely covered with molten solder, the soldering iron is re-
moved.
The joint is allowed to cool, without any movement.
The bright shining solder indicates good soldering.
In case of dry solder joint, an air gap remains in between the solder maternal and
the joint. It means that soldering is improper. This is removed and again soldering
is done.
Thus is this way all the components are soldered on P. C. B.
DTMF Controlled Robot
35
7.1 Diodes:-
Diodes are components that allow current to flow in only one direction. They have a
positive side (leg) and a negative side. When the voltage on the positive leg is higher than
on the negative leg then current flows through the diode (the resistance is very low).
When the voltage is lower on the positive leg than on the negative leg then the current
does not flow (the resistance is very high). The negative leg of a diode is the one with the
line closest to it. It is called the cathode. The positive end is called the anode.
7.2 LED:-
Light Emitting Diodes are great for projects because they provide visual entertainment.
LEDs use a special material which emits light when current flows through it. Unlike light
bulbs, LEDs never burn out unless their current limit is passed. A current of 0.02 Amps
(20 mA) to 0.04 Amps (40 mA) is a good range for LEDs. They have a positive leg and a
negative leg just like regular diodes. To find the positive side of an LED, look for a line
in the metal inside the LED. It may be difficult to see the line. This line is closest to the
positive side of the LED. Another way of finding the positive side is to find a flat spot on
the edge of the LED. This flat spot is on the negative side.
When current is flowing through an LED the voltage on the positive leg is about 1.4
volts higher than the voltage on the negative side. Remember that there is no resistance to
limit the current so a resistor must be used in series with the LED to avoid destroying it.
Now we know enough that we can start to build circuits. But first we will look a little
closer at a component that was introduced in Section 1.2.
The LED
DTMF Controlled Robot
36
An LED is the device shown above. Besides red, they can also be yellow, green and
blue. The letters LED stand for Light Emitting Diode. If you are unfamiliar with diodes,
take a moment to review the components in Basic Components, Section 1.2. The
important thing to remember about diodes (including LEDs) is that current can only flow
in one direction.
To make an LED work, you need a voltage supply and a resistor. If you try to use an
LED without a resistor, you will probably burn out the LED. The LED has very little
resistance so large amounts of current will try to flow through it unless you limit the
current with a resistor. If you try to use an LED without a power supply, you will be
highly disappointed.
7.3 Resistors:-
Resistors are components that have a predetermined resistance. Resistance
determines how much current will flow through a component. Resistors are used to
control voltages and currents. A very high resistance allows very little current to flow.
Air has very high resistance. Current almost never flows through air. (Sparks and
lightning are brief displays of current flow through air. The light is created as the current
burns parts of the air.) A low resistance allows a large amount of current to flow. Metals
have very low resistance. That is why wires are made of metal. They allow current to
flow from one point to another point without any resistance. Wires are usually covered
with rubber or plastic. This keeps the wires from coming in contact with other wires and
creating short circuits. High voltage power lines are covered with thick layers of plastic
to make them safe, but they become very dangerous when the line breaks and the wire is
exposed and is no longer separated from other things by insulation.
Resistance is given in units of ohms. (Ohms are named after Mho Ohms who
played with electricity as a young boy in Germany.) Common resistor values are from
100 ohms to 100,000 ohms. Each resistor is marked with colored stripes to indicate its
resistance. To learn how to calculate the value of a resistor by looking at the stripes on
the resistor, go to Resistor Values which includes more information about resistors.
Variable Resistors
DTMF Controlled Robot
37
Variable resistors are also common components. They have a dial or a knob that
allows you to change the resistance. This is very useful for many situations. Volume
controls are variable resistors. When you change the volume you are changing the
resistance which changes the current. Making the resistance higher will let less current
flow so the volume goes down. Making the resistance lower will let more current flow so
the volume goes up. The value of a variable resistor is given as its highest resistance
value. For example, a 500 ohm variable resistor can have a resistance of anywhere
between 0 ohms and 500 ohms. A variable resistor may also be called a potentiometer
(pot for short).
7.4 The Capacitor:-
If you already understand capacitors you can skip this part.
The picture above on the left shows two typical capacitors. Capacitors usually have two
legs. One leg is the positive leg and the other is the negative leg. The positive leg is the
one that is longer. The picture on the right is the symbol used for capacitors in circuit
drawings (schematics). When you put one in a circuit, you must make sure the positive
leg and the negative leg go in the right place. Capacitors do not always have a positive
leg and a negative leg.
The smallest capacitors in this kit do not. It does not matter which way you put them in
a circuit.
A capacitor is similar to a rechargeable battery in the way it works. The difference is
that a capacitor can only hold a small fraction of the energy that a battery can. (Except for
really big capacitors like the ones found in old TVs.) These can hold a lot of charge. Even
if a TV has been disconnected from the wall for a long time, these capacitors can still
make lots of sparks and hurt people.) As with a rechargeable battery, it takes a while for
the capacitor to charge. So if we have a 12 volt supply and start charging the capacitor, it
DTMF Controlled Robot
38
will start with 0 volts and go from 0 volts to 12 volts. Below is a graph of the voltage in
the capacitor while it is charging.
The same idea is true when the capacitor is discharging. If the capacitor has been
charged to 12 volts and then we connect both legs to ground, the capacitor will start
discharging but it will take some time for the voltage to go to 0 volts. Below is a graph of
what the voltage is in the capacitor while it is discharging.
We can control the speed of the capacitor's charging and discharging using resistors.
Capacitors are given values based on how much electricity they can store. Larger
capacitors can store more energy and take more time to charge and discharge. The values
are given in Farads but a Farad is a really large unit of measure for common capacitors.
In this kit we have 2 33pf capacitors, 2 10uf capacitors and 2 220uF capacitors. Pf means
picofarad and uf means microfarad. A picofarad is 0.000000000001 Farads. So the 33pf
capacitor has a value of 33 picofarad or 0.000000000033 Farads. A microfarad is
0.000001 Farads. So the 10uf capacitor is 0.00001 Farads and the 220uF capacitor is
0.000220 Farads. If you do any calculations using the value of the capacitor you have to
use the Farad value rather than the picofarad or microfarad value.
Capacitors are also rated by the maximum voltage they can take. This value is always
written on the larger can shaped capacitors. For example, the 220uF capacitors in this kit
have a maximum voltage rating of 25 volts. If you apply more than 25 volts to them they
will die.
DTMF Controlled Robot
39
7.5 Volt Power Supply: -
Most digital logic circuits and processors need a 5 volt power supply. To use these
parts we need to build a regulated 5 volt source. Usually you start with an unregulated
power supply ranging from 9 volts to 24 volts DC. To make a 5 volt power supply, we
use a LM7805 voltage regulator IC (Integrated Circuit). The IC is shown below.
The LM7805 is simple to use. You simply connect the positive lead of your unregulated
DC power supply (anything from 9VDC to 24VDC) to the Input pin, connect the
negative lead to the Ground pin and then when you turn on the power, you get a 5 volt
supply from the Output pin. This 5 volt output will be used as Vcc in the following
projects.
Connect the red wire from the power supply adapter to the input of the 7805.
Connect the black wire from the power supply adapter to the ground row (with the blue
line beside it). Run a black jumper wire from the ground row to the ground of the 7805.
Then use a yellow jumper to connect the 5 v output to the row of holes with the red stripe
beside it.
DTMF Controlled Robot
40
7.6 DC MOTOR:-
Introduction:
This page describes how DC motors work, and how we can use them to build the
traction system of a robot. It covers both permanent magnet motors, and series wound
motors (such as car starter motors). If you are interested in converting a starter motor for
use in a robot, see the separate page Converting starter motors.
Motor principles:
All motors require two magnetic fields, one produced by the stationary part of the
motor (the stator, or field), and one by the rotating part (the rotor, or armature). These
are produced either by a winding of coils carrying a current, or by permanent magnets. If
the field is a coil of wire, this may be connected in a variety of ways, which produces
different motor characteristics.
The basic law of a motor, the reason why they rotate, is governed by Fleming’s left hand
rule (see figure below). This tells you the direction of the force on a wire that is carrying
current when it is in a magnetic field.
DTMF Controlled Robot
41
The next diagram shows the force acting on a wire carrying current, obeying the left hand
rule:
If we now bend the wire round in a loop, and place it in a magnetic field caused by two
permanent magnets, we have the situation shown in the diagram below. Here, both sides
of the wire loop will have a force on them, trying to make the wire loop rotate. The
current is applied to the loop through the commutator, which is shown as two pieces of
metal formed into a ring in the figure. Current is applied to the commutator by stationary
graphite blocks, called brushes, which rub against the commutator ring.
The loop will continue to rotate anticlockwise (as we see it in the figure) until it is
vertical. At this point, the stationary brushes won't be applying current around the loop
any more because they will be contacting the gap between the commutator segments, but
the inertia of the loop keeps it going a little more, until the DC supply reconnects to the
DTMF Controlled Robot
42
commutator segments, and the current then goes around the loop in the opposite
direction. The force though is still in the same direction, and the loop continues to rotate.
This is how DC motors work. In a real motor, there are many wire loops (windings) all at
varying angles around a solid iron core. Each loop has its own pair of commutator
segments. This block of core and wire loops is called the rotor because it rotates, or the
armature.
7.7 Crystal Oscillator:-
This is how some oscillator looks like.
DTMF Controlled Robot
43
Short description:
Crystals are commonly used to provide a stable clock source for micro-controllers. This
has a freq. tolerance of +-50ppm, temperature stability of +-50ppm, and load capacitance
of 18pF. It's slightly more than 1/8" tall.
More information and instructions:
Here are 22pF ceramic disc capacitors commonly used with this crystal to provide a
clock source to micro-controllers.
When installing, be sure that the case does not make contact with any other
conductors; i.e., don't push it all the way flush with the board.
+-5ppm (parts per million) per year aging drift.
About crystals:
There are several different ways to provide a clock source, including crystals,
oscillators, RC circuits, and resonators; this article gives a good comparison. Crystals
offer a good compromise of low cost, high accuracy, good temperature stability, and low
power use.
They are typically used in what's called a "Pierce circuit" with microcontrollers that
has two other capacitors tied to ground on either side of the crystal. The value of the
capacitors affects the circuit's frequency. Crystals manufactured for use in this type of
circuit are parallel crystals and come pre-compensated for a certain "capacitive load." The
formula that relates the crystal's capacitive load and the capacitors used in the circuit is:
CL = (C1*C2)/ (C1+C2) + Cs (stray capacitance in leads and circuit board). Many guides
suggest Cs is usually around 5 pF, but the Microchip spec sheets seem to assume its
12.5pF.
PPM (Parts per Million):
This is like a percent error (1000 PPM = .1% error), and is convenient for calculating
error with crystals. 5ppm on a 4MHz crystal = 5*4 = 20Hz possible error. Most
DTMF Controlled Robot
44
microcontroller applications don't require too much accuracy, 100ppm is fine. If the
parallel capacitors don't match the crystal's capacitive load exactly, they will pull the
frequency, but not much. This offers more info about pull ability and crystals in general.
It seems to indicate that on a 20pF CL crystal, you may get 16ppm/pF error between the
anticipated load and actual.
A Microchip application note that talks about crystal design considerations for
microcontrollers.
DTMF Controlled Robot
46
Advantages:
- DTMF’s technology is simple, low cost, as well as its already popular status
in the telephone industry of today.
In the networks there are large number of nodes that are very simple and act
merely as relay stations.
In healthcare (hospital and home environments), a robot that is capable of
sending acoustic commands to turn on/off devices such as light switch or
closing door while letting the user know that the process is taking place will
be very helpful in allowing the user to feel more comfortable around robots.
Disadvantages:
As signal strength decreases the performance of the system also degrades
DTMF Controlled Robot
48
Applications:-
Scientific
• Remote control vehicles have 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
spaceflight and exploration.
Military and Law Enforcement
• Military usage of remotely controlled military vehicles dates back to the first
half of 20th century. Soviet Red Army used remotely controlled Teletanks during
1930s in the Winter War and early stage of World War II.
Search and Rescue
• UAVs will likely play an increased role in search and rescue in the United
States. This was demonstrated by the successful use of UAVs during the 2008
hurricanes that struck Louisiana and Texas.
Recreation and Hobby
• See Radio-controlled model. Small scale remote control vehicles have long been
popular among hobbyists. These remote controlled vehicles span a wide range in
DTMF Controlled Robot
49
terms of price and sophistication. There are many types of radio controlled
vehicles. These include on-road cars, off-road trucks, boats, airplanes, and even
helicopters. The "robots" now popular in television shows such as Robot Wars,
are a recent extension of this hobby (these vehicles do not meet the classical
definition of a robot; they are remotely controlled by a human).
DTMF Controlled Robot
51
Future Scope:
IR Sensors
• IR sensors can be used to automatically detect & 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.
Password Protection
• 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 & increases security to a great extent.
Alarm Phone Dialer
• By replacing DTMF Decoder IC CM8870 by a 'DTMF Transceiver IC’
CM8880, 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 relay). For
example, 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.
DTMF Controlled Robot
53
Troubleshooting:
During our final year full time project we had to par many hurdles to complete our
project we tackled it with the help of our mentor and with our knowledge with finally
helped us to get the project done.
The different problems we faced were:-
While etching the PCB the due to some mishandling the tracks on the PCB were not
properly etched and so we had to etch the PCB again.
While soldering the circuit it led to overheating of the IC MT8870 and due to which the
IC got fused. So we replaced the IC to get our project working.
Due to improper connections the robot was operating in the reverse operations so we
changed the wiring of it and it started operating.
The tuning in the camera was not happening properly so remedy to it was removed by
changing the connectors to the camera transreciever.
DTMF Controlled Robot
55
Conclusion:-
This paper has described the design and implementation of experiments to
test the feasibility of using the Dual Tone Multi-Frequency encoding scheme
as a method for communicating simple messages.
DTMF Controlled Robot
57
Books:
Robotics Demystified
Hardware Hacking Projects
Parallel Port Complete
Electric Drives
Websites: www.epanorama.com
www.robotics.com
www.automation.com
www.mechtechworld.com
DTMF Controlled Robot
59
MICROCONTROLLER AT89SXX
Features
• Compatible with MCS®-51Products
• 2K Bytes of Reprogrammable Flash Memory – Endurance: 10,000 Write/Erase Cycles
• 2.7V to 6V Operating Range
• Fully Static Operation: 0 Hz to 24 MHz
• Two-level Program Memory Lock
• 128 x 8-bit Internal RAM
• 15 Programmable I/O Lines
• Two 16-bit Timer/Counters • Six Interrupt Sources
• Programmable Serial UART Channel
• Direct LED Drive Outputs
• On-chip Analog Comparator
• Low-power Idle and Power-down Modes
• Green (Pb/Halide-free) Packaging Option
1. Description
The AT89C2051 is a low-voltage, high-performance CMOS 8-bit microcomputer
with 2K bytes of Flash programmable and erasable read-only memory (PEROM).
The device is manufactured using Atmel’s high-density nonvolatile memory
technology and is compatible with the industry-standard MCS-51 instruction set.
By combining a versatile 8-bit CPU with Flash on a monolithic chip, the Atmel
AT89C2051 is a power-ful microcomputer which provides a highly-flexible and
cost-effective solution to many embedded control applications. The AT89C2051
DTMF Controlled Robot
60
provides the following standard features: 2K bytes of Flash, 128 bytes of RAM,
15 I/O lines, two 16-bit timer/counters, a five vector two-level interrupt
architecture, a full duplex serial port, a precision analog comparator, on-chip
oscillator and clock circuitry. In addition, the AT89C2051 is designed with static
logic for opera-tion down to zero frequency and supports two software selectable
power saving modes. The Idle Mode stops the CPU while allowing the RAM,
timer/counters, serial port and interrupt system to continue functioning. The
power-down mode saves the RAM contents but freezes the oscillator disabling all
other chip functions until the next hardware reset.
2. Pin Configuration
2.1 20-lead PDIP/SOIC
Figure 14.1- Microcontroller pin diagram
DTMF Controlled Robot
61
3. Block Diagram
Figure 14.2- Microcontroller block diagram
4. Pin Description
4.1 VCC Supply voltage.
4.2 GND Ground.
DTMF Controlled Robot
62
4.3 Port 1 The Port 1 is an 8-bit bi-directional I/O port. Port pins P1.2 to P1.7
provide internal pull-ups. P1.0 and P1.1 require external pull-ups. P1.0
and P1.1 also serve as the positive input (AIN0) and the negative input
(AIN1), respectively, of the on-chip precision analog comparator. The Port
1 out-put buffers can sink 20 mA and can drive LED displays directly.
When 1s are written to Port 1 pins, they can be used as inputs. When pins
P1.2 to P1.7 are used as inputs and are externally pulled low, they will
source current (IIL) because of the internal pull-ups. Port 1 also receives
code data during Flash programming and verification.
4.4 Port 3 Port 3 pins P3.0 to P3.5, P3.7 are seven bi-directional I/O pins with
internal pull-ups. P3.6 is hard-wired as an input to the output of the on-
chip comparator and is not accessible as a gen-eral-purpose I/O pin. The
Port 3 output buffers can sink 20 mA. When 1s are written to Port 3 pins
they are pulled high by the internal pull-ups and can be used as inputs. As
inputs, Port 3 pins that are externally being pulled low will source current
(IIL) because of the pull-ups. Port 3 also serves the functions of various
special features of the AT89C2051 as listed below: Port 3 also receives
some control signals for Flash programming and verification.
Port Pin Alternate Functions
P3.0 RXD (serial input port)
P3.1 TXD (serial output port)
P3.2 INT0 (external interrupt 0)
P3.3 INT1 (external interrupt 1)
P3.4 T0 (timer 0 external input)
P3.5 T1 (timer 1 external input)
4.5 RST Reset input. All I/O pins are reset to 1s as soon as RST goes high. Holding
the RST pin high for two machine cycles while the oscillator is running resets the
device. Each machine cycle takes 12 oscillator or clock cycles.
4.6 XTAL1 Input to the inverting oscillator amplifier and input to the internal clock
operating circuit.
4.7 XTAL2 Output from the inverting oscillator amplifier.
DTMF Controlled Robot
63
5. Oscillator Characteristics
The XTAL1 and XTAL2 are the input and output, respectively, of an inverting amplifier
which can be configured for use as an on-chip oscillator, as shown in Figure 5-1. Either a
quartz crystal or ceramic resonator may be used. To drive the device from an external
clock source, XTAL2 should be left unconnected while XTAL1 is driven as shown in
Figure 5-2. There are no require-ments on the duty cycle of the external clock signal,
since the input to the internal clocking circuitry is through a divide-by-two flip-flop, but
minimum and maximum voltage high and low time specifications must be observed.
Figure 5-1-Oscillator Connections
Note: C1, C2 = 30 pF ± 10 pF for Crystals
= 40 pF ± 10 pF for Ceramic Resonators
Figure 14.3-External Clock Drive Configuration
DTMF Controlled Robot
64
MT8870D/MT8870D-1
Integrated DTMF Receiver
Features:
• Complete DTMF Receiver
• Low power consumption
• Internal gain setting amplifier
• Adjustable guard time
• Central office quality
• Power-down mode
• Inhibit mode
• Backward compatible with MT8870C/MT8870C-1
Applications:
• Receiver system for British Telecom (BT) or CEPT Spec (MT8870D-1)
• Paging systems
• Repeater systems/mobile radio
• Credit card systems
• Remote control
Description:
The MT8870D/MT8870D-1 is a complete DTMF Receiver integrating both the band
split filter and Digital decoder functions. The filter section uses Switched capacitor
techniques for high and low Group filters; the decoder uses digital counting Techniques
to detect and decode all 16 DTMF tone pairs Into a 4-bit code. External component count
DTMF Controlled Robot
65
is Minimized by on chip provision of a differential input Amplifier, clock oscillator and
latched three-state bus Interface.
Ordering Information
MT8870DE/DE-1 18 Pin Plastic DIP
MT8870DS/DS-1 18 Pin SOIC
MT8870DN/DN-1 20 Pin SSOP
-40 °C to +85 °C
DTMF Controlled Robot
66
L293D
PUSH-PULL FOUR CHANNELS DRIVER WITH DIODES:
-600mA OUTPUT CURRENT CAPABILITY PER CHANNEL
-1.2A PEAK OUTPUT CURRENT (non repetitive) PER CHANNEL
-ENABLE FACILITY
-OVER TEMPERATURE PROTECTION
-LOGICAL”0” INPUT VOLTAGE UP TO 1.5 V(HIGH NOISE IMMUNITY)
-INTERNAL CLAMP DIODES
DESCRIPTION The Device is a monolithic integrated high voltage, High current four channel driver
designed to Accept standard DTL or TTL logic levels and drive Inductive loads (such as
relays solenoids, DC And stepping motors) and switching power transistors. To simplify
use as two bridges each pair of channels Is equipped with an enable input.
A separate Supply input is provided for the logic, allowing operation at a lower
voltage and internal clamp diodes are included.
This device is suitable for use in switching applications
At frequencies up to 5 kHz. The L293D is assembled in a 16 lead plastic. Package which has 4
center pins connected together and used for heatsinking the L293DD is assembled in a 20 lead
surface mount which has 8 center pins connected together and used for heatsinking.
DTMF Controlled Robot
67
LM78LXX Series
3-Terminal Positive Regulators
General Description
The LM78LXX series of three terminal positive regulators is available with several
fixed output voltages making them Useful in a wide range of applications. When used as
a zener diode/resistor combination replacement, the LM78LXX usually results in an
effective output impedance improvement of two orders of magnitude, and lower
quiescent current.
These regulators can provide local on card regulation, eliminating the distribution
problems associated with single point regulation. The voltages available allow the
LM78LXX to be used in logic systems, instrumentation, HiFi, and other solid state
electronic equipment.
The LM78LXX is available in the plastic TO-92 (Z) package, the plastic SO-8 (M)
package and a chip sized package (8-Bump micro SMD) using National’s micro SMD
package technology. With adequate heat sinking the regulator can deliver 100mA output
current. Current limiting is included to limit the peak output current to a safe value. Safe
area protection for the output transistors is provided to limit internal power dissipation. If
internal power dissipation becomes too high for the heat sinking provided, the thermal
shutdown circuit takes over preventing the IC from overheating.
Features:
- LM78L05 in micro SMD package
- Output voltage tolerances of ±5% over the temperature range
- Output current of 100mA
- Internal thermal overload protection
- Output transistor safe area protection
- Internal short circuit current limit
- Available in plastic TO-92 and plastic SO-8 low profile Packages
- Output voltages of 5.0V, 6.2V, 8.2V, 9.0V, 12V, 15V