4th yr main report
-
Upload
kimwatusteve -
Category
Documents
-
view
225 -
download
0
Transcript of 4th yr main report
-
8/7/2019 4th yr main report
1/39
-
8/7/2019 4th yr main report
2/39
1.2 OBJECTIVESy To co-ordinate appliances and other devices through Short Message Service(SMS).
y To effectively receive and transmit data via SMSy To eliminate the need of being physically present in any location for tasks involving the
operation of appliances within a household/office.
y To Minimize power and time wastagey To design and construct a simple circuit that is to be implemented to come up with the
device that remotely controls electrical interfaced appliances in a modern premise.
y To design a device whose operation will utilize the calling services by mere flashingfor cheap operation and can withstand harsh environments.
1.2.0 Intended Users and Uses
This system is aimed toward all the average users who wish to control theirHousehold/officeappliances remotely from their cell phones provided that the appliancesare electricallycontrollable. Example of feasible appliances and applications underconsideration include;enable/disable security systems, fans, lights, kitchen appliances,and adjusting the temperaturessettings of a heating/ventilation/air conditioning system.
1.2.1 Assumptions
Certain assumptions have to be made in order to implement our project.
a. The user and control unit will establish communication via GSMb. The cell phone and service provider chosen will support text messaging service.c. The user is familiar with the text messaging program on their cell phone.d. All service charges (standard messaging rates) from the service provider apply.
e. The controlled appliances can and will have to have an electrical interface in
Orderto be controlled by the microcontroller.
1.3 BACKGROUND INFORMATIONNowadays, the communications has becomes very simple, fast, interactive and morecompact, that makes the global as a small village. So it is very easy for anyone tosubscribe in the local or global telecommunication networks with individual mobile
phone device.Mobile devices, such as mobile phones, are becomingmultipurpose devices. These devicesare capable of storing data as well as running custom application. As more peopleadopt these devices and begin to use them for personal or business tasks, the need forcontrolling access to the data stored within the devices will become vital.With todays and tomorrows wireless technologies, such as IEEE 802.11, Bluetoothand G3, mobile devices will frequently be in close and interactive communication.Many environments including offices, meeting rooms, automobiles and class roomsalready contains many computers and computerized applications, and the smart all
-
8/7/2019 4th yr main report
3/39
input/output signals from its ports, hence, the interface hardware circuits.In this project, for the purpose of interfacing with the real time control applications, the
microcontroller is used.The data bit signals can be managed by software that is applied for this purpose, the
powerful assembly language which can access the ports more efficiently than otheravailable computer program languages is used.
As the whole project software is written and implemented through the use of assemblylanguage. There are many ways that could be used to control all home appliances by sendingappropriate signals to the microcontrollers ports, parallel or serial. Then these signalsinserted to the interface hardware system that is prepared, designed and matches withthe output signals, then depend on the signal, the interface hardware control or manageone or more of the home appliances.The advantage of using a mobile phone in this type of system is its low cost, due to large-scale production, and general availability. It also assures automatic reconnection mechanismsto the cellular net, even after service or transmission occasional interruptionsHowever they require the knowledge of serial communication protocols established by
theManufacturerthat in general, is not freely available.
1.4 ListofAcronyms
DAQ Data Acquisition the process by which events in the real world aretranslated intomachine-readable signals.
EL Explosive Limit the concentration at which an air and specific gas mixturebecomes
explosive.EMI Electromagnetic Interference the interference in signal transmission orreceptioncaused by the radiation of electrical and magnetic fields.
FET Field Effect Transistor a type of transistor commonly used for weak-signalAmplification
JFET JunctionField Effect Transistor the simplest type of field effect transistor.MOS Metal-Oxide Semiconductor (hydrogen concentration sensing type)PCB Printed Circuit Board
-
8/7/2019 4th yr main report
4/39
CHAPTER 2
2.0 REVIEW OF RELATED LITERATURE:
This project has been made by several other people, but most of the times their systems areoperated by sending SMS to control the electrical appliances. These systems are usuallycomplex and expensive for daily operation to most of the people. Inthis projectthe callingservices of mobile service providers have been utilized to come up with a simple device thatcan perform the same function, but the operation is cheap. It makes use of flashing which isfamiliar with all mobile phone users. This makes technology affordable to most of the people.
2.1 DESIGN AND COMPONENT DESCRIPTION2.1.1 INTEL 8051 MICROCONTROLLER
A microcontroller is an entire computer manufactured on a single chip. Microcontrollers areusually dedicated devices embedded within an application. For example, microcontrollersare used as engine controllers in automobiles and as exposure and focus controllers incameras. In order to serve these applications, they have a high concentration of on-chipfacilities such as serial ports, parallel input-output ports, timers, counters, interrupt control,analog-to-digital converters, and random access memory and read only memory. The I/O,memory, and on-chip peripherals of a microcontroller are selected depending on the specificsof the target application.
Since microcontrollers are powerful digital processors, the degree of control andprogrammability they provide, significantly enhances the effectiveness of the application.
Embedded control applications also distinguish the microcontroller from its relative, the
general-purpose microprocessor. Embedded systems often require real-time operation andmultitasking capabilities. Real-time operation refers to the fact that the embedded controllermust be able to receive and process the signals from its environment as they are received.That is, the environment must not wait for the controller to become available. Similarly, thecontroller must perform fast enough to output control signals to its environment when theyare needed. Again, the environment must not wait for the controller. In other words, theembedded controller should not be a bottleneck in the operation of the system. Multitaskingis the capability to perform many functions in a simultaneous or quasi-simultaneous manner.The embedded controller is often responsible of monitoring several aspects of a system andresponding accordingly when the need arises.
The architecture of the 8051 family of microcontrollers is referred to as the MCS-51architecture, or sometimes simply as MCS-51. The microcontrollers have an 8-bit data bus.They are capable of addressing 64K of program memory and a separate 64K of data memory.The 8051 has 4K of code memory implemented as on-chip Read Only Memory (ROM). The8051 has 128 bytes of internal Random Access Memory (RAM). The 8051 has twotimer/counters, a serial port, 4 general purpose parallel input/output ports, and interruptcontrol logic with five sources of interrupts.
Besides internal RAM, the 8051 has various Special Function Registers (SFR), which are thecontrol and data registers for on-chip facilities. The SFRs also include the accumulator, the Bregister, and the Program Status Word (PSW), which contains the CPU flags. Programming
-
8/7/2019 4th yr main report
5/39
the various internal hardware facilities of the 8051 is achieved by placing the appropriatecontrol words into the corresponding SFRs.
As stated, the 8051 can address 64K of external data memory and 64K of external programmemory. These may be separate blocks of memory, so that up to 128K of memory can beattached to the microcontroller. Separate blocks of code and data memory are referred to asthe Harvard architecture. The 8051 has two separate read signals, RD# (P3.7) and PSEN#.The first is activated when a byte is to be read from external data memory, the other, fromexternalprogram memory. Both of these signals are so-called active low signals. That is, theyare cleared to logic level 0 whenactivated. All external code is fetched from external
program memory. In addition, bytes from external program memory may be read by specialread instructions such as the MOVC instruction. There are separate instructions to read fromexternal data memory, such as the MOVX instruction. That is, the instructions determinewhich block of memory is addressed, and the corresponding control signal, either RD# orPSEN# is activated during the memory read cycle. A single block of memory may bemapped to act as both data and program memory. This is referred to as the Von
Neumann1architecture. In order to read from the same block using either the RD# signal orthe PSEN# signal, the two signals are combined with a logic AND operation.
This way, the output of the AND gate is low when either input is low. The advantage of theHarvard architecture is not simply doubling the memory capacity of the microcontroller.Separating program and data increases the reliability of the microcontroller, since there areno instructions to write to the program memory. A ROM device is ideally suited to serve as
program memory. The Harvard architecture is somewhat awkward in evaluation systems,where code needs to be loaded into program memory. By adopting the Von Neumannarchitecture, code may be written to memory as data bytes, and then executed as programinstructions.
-
8/7/2019 4th yr main report
6/39
Figure no.1:Port 0 with pull-up resistors.
P1.0 1 40 VCC
P1.1 2 39 P0.0/AD0
P1.2 3 38 P0.1/AD1
P1.3 4 37 P0.2/AD2
P1.4 5 36 P0.3/AD3
P1.5 6 35 P0.4/AD4
P1.6 7 34 P0.5/AD5
P1.7 8 33 P0.6/AD6
RST/VPD 9 32 P0.7/AD7
RxD/P3.0 10 31 EA
TxD/P3.1 11 30 ALE
INT0/P3.2 12 29 PSEN
INT1/P3.3 13 28 P2.7/A15
T0/P3.4 14 27 P2.6/A14
T1/P3.5 15 26 P2.5/A13
WR/P3.6 16 25 P2.4/A12
RD/P3.7 17 24 P2.3/A11
XTAL2 18 23 P2.2/A10
XTAL1 19 22 P2.1/A9
VSS 20 21 P2.0/A8
Figure no. 2: 8051 microcontroller - DIP 40 package
Source: 8051 Datasheet
Port 0: Is an 8-bit open drain bidirectional I/O port. As an output port each pin can sink 8 LS
TTL inputs. Port 0 pins that have 1s written to them float, and in that state can be used as
high impedance inputs. Port 0 is also the multiplexed low-order address and data-bus during
accesses to external program and data memory. It receives the code bytes during
programming of the EPROM parts, and outputs the code bytes during the program
verification of the ROM and EPROM parts.
PORT 1: Is an 8-bit bidirectional I/O port with internal pull-ups. Port 1 output buffers cansink/source 4 LS TTL inputs.Port1 pins that have 1s written to them are pulled high byinternal pull-ups, and in that state can be used as inputs. Port 1 also receives the low- orderaddress bytes during programming of the EPROM parts and during program verification ofthe ROM and EPROM parts.
-
8/7/2019 4th yr main report
7/39
PORT 2: Is an 8-bit bidirectional I/O port with internal pull-up.The port 2 buffers can alsosink/source 4 LS TTL inputs. Port 2 pins that have 1s written to them are pulled high byinternal pull-ups, and in that state can be used as inputs. Port 2 emits high order address bytesduring fetches from external program memory and during accesses to external data memorythat use 16-bit addresses. It also receives the high-order address bytes during programming ofthe EPROM parts and during program verification of the ROM and EPROM parts.
PORT 3: Is an 8-bit bidirectional I/O port with internal pull-ups. The port 3 buffers can alsosink/source 4 LS TTL inputs. Port 3 pins that have 1s written to them are pulled high by
internal pull-ups, and in that state can be used as inputs.
Table no.1 : Reset value for 8051 ports.Source:8051 Datasheet
-
8/7/2019 4th yr main report
8/39
Table no. 2: Port 3 alternate functions.
Table no.3:Single-Bit Addressability of ports.
Source:8051 Datasheet
Table no.4: Single-Bit Instructions
Tableno.5: Instructions forreading anInput port
-
8/7/2019 4th yr main report
9/39
Table no.6:Instructions for reading a latch(Read-Modify-Write)
Source: 8051 Datasheet
-
8/7/2019 4th yr main report
10/39
Figureno. 3: MCS-51 blockdiagram
Source:8051 Datasheet
-
8/7/2019 4th yr main report
11/39
2.1.2 NOKIA 3310
The Nokia 3310 is a dual band GSM900/1800 phone. The 3310 is a compact but somewhatheavy (133 g) phone featuring an 84 x 48 monochrome display. It has a lighter 115 g batteryvariant which has fewer features. It is a slightly rounded rectangular unit that is typically heldin the palm of a hand, with the buttons operated with the thumb. The blue button is the main
button for selecting options, with "C" button as a "back" or "undo" button. Up and downbuttons are used for navigation purposes. The on/off/profile button is a stiff black buttonlocated on the top of the phone. It has a very sturdy design which was big contribution for itssuccess. However, radiation is high with SAR = 0.96 W/kg.
2.1.3 CONNECTING NOKIA 3310
Most Nokia phones have F-Bus and M-Bus connections that can be used to connect a phoneto a PC or in our case a microcontroller. The connection can be used for controlling justabout all functions of the phone, as well as uploading new firmware. The very popular Nokia3310 has the F/M Bus connection under the battery holder. This is a bit of a pain to get to and
requires a special cable to make the connection.
The F-Bus is bi-directional serial type bus running at 115,200bps, 8 data bits. The serial cablecontains electronics for level conversion and therefore requires power. By using a Max232 or
similar transceiver for the RS232 TX and RX pins and then connecting the DTR pin on theserial cable to the V+ pin on the Max232. Do the same for the RTS; however connect it to the
V- pin on the Max232. The V+ and V- pins are derived from internal charge pumps thatdouble the input voltage. ie for a 5V Max232, the V+ will +10V and the V- will be -10V.
To synchronize the UART in the phone with the microcontroller, this is done by sending astring of 0x55 or 'U' 128 times. The bus is now ready to be used for sending frames. The
Nokia protocol has a series of commands that allow the user to make calls, send and get SMS
messages and lots more.
-
8/7/2019 4th yr main report
12/39
2.1.4F-BUS AND M-BUS HLLLLL
KKKKGVKFBKFVBRKV
Nokia 3310 has the F/M Bus connection under the battery holder. The F-Bus and M-Bus
connections are used to connect a phone to a microcontroller. The connection can be used forcontrolling almost all functions of the phone. This connection requires a special cable called
F-Bus cable (Nokia download cable). The cable contains electronics to level convert 3Vsignals to RS232 type signals. There are also M and F bus switching in most cables.
M-Bus is a one pin bi-directional bus for both transmitting and receiving data from thephone. It is slow (9600bps) and only half-duplex. Only two pins on the phone are used.Oneground and one data. M-Bus runs at 9600bps, 8 data bits, odd parity, and one stop bit. Thedata terminal ready (DTR) pin must be cleared with the request to send (RTS). This powersthe electronics in the cable and it sets it for M-Bus operation.
F-Bus is the later high-speed full-duplex bus. It uses one pin for transmitting data and one pinfor receiving data plus the ground pin. Very much like a standard serial port. It is fast
115,200bps, 8 data bits, no parity, and one stop bit. For F -Bus the data terminal ready (DTR)
pin must be set and the request to send (RTS) pin cleared.
2.1.5 DB9 CONNECTORFOR SERIAL PORT
In computing, a serial port is a serial communication physical interface through whichinformation transfers in or out one bit at a time (contrast parallel port).
Figure no. 4: DB-9 connector
Source:www.electrosofts.com/serial.
-
8/7/2019 4th yr main report
13/39
Figure no.5 DB-9 Pin out
Source: www.electrosofts.com/serial.
2.1.6 MAX232
The MAX232 is an integrated circuit that converts signals from an RS-232 serial port to
signals suitable for use in TTL compatible digital logic circuits. The MAX232 is a dualdriver/receiver and typically converts the RX, TX, CTS and RTS signals. Each receiverconverts TIA/EIA-232-E levels into 5V TTL/CMOS levels. Each driver converts TT -L/COMS levels into TIA/EIA-232-E levels. The MAX232 is characterized for operationfrom -40C to +85C for all packages.
The drivers provide RS-232 voltage level outputs (approx. 7.5 V) from a single + 5 V
supply via on-chip charge pumps and external capacitors. This makes it useful forimplementing RS-232 in devices that otherwise do not need any voltages outside the 0 V to
+ 5 V range, as power supply design does not need to be made more complicated just fordriving the RS-232 in this case.
The receivers reduce RS-232 inputs (which may be as high as 25 V), to standard 5 V TTLlevels. These receivers have a typical threshold of 1.3 V, and a typical hysteresis of 0.5 V
-
8/7/2019 4th yr main report
14/39
Figure no. 6: Max232 pin configuration
Source: MAX 232 datasheet
PIN DESCRIPTION
No. NameFunction1 C1+ External capacitance of positive voltage multiplier unit2 V+ Output of positive voltage of multiplier unit3 C1- External capacitance of positive voltage multiplier unit4 C2+ External capacitance of negative voltage multiplier
5 C2- External capacitance of negative voltage multiplier unit
6 V- Output of negative voltage of multiplier unit7T2out Output of transmitter data (levels RS 232)8R2in Input of receiver data (levels RS 232)
9 R2out Output of receiver data (levels TTL/CMOS)10 T2in Input of transmitter data (levels TTL/CMOS)
11 T1in Input of transmitter data (levels TTL/CMOS)12 R1out Output of receive r data (levels TTL/CMOS)
13 R1in Input of receiver data (levels RS 232)14 T1out Output of transmitter data (levels RS 232)15 GND Ground16 VCC Supply voltage
-
8/7/2019 4th yr main report
15/39
Figure no.7: Timing diagram 2
Figure no.8: Timing diagram 2Source: Max232 Datasheet
-
8/7/2019 4th yr main report
16/39
Figure no. 9: Max 232application
circuit
Source: Max232 Datasheet
2.1.778L05 THREE TERMINAL VOLTAGE REGULATOR:
Figure no.10: 78L08
Source:www.wikipedia
The three terminal voltage regulator outputs stabilized voltage at a lower level than the inputvoltage. A voltage regulator cannot output higher voltage than the input voltage.
2.1.8 1N4148 DIODE
The 1N4148 is a standard small signal silicondiode used in signal processing. Its namefollows the JEDEC nomenclature. The 1N4148 is generally available in a DO-35 glass
-
8/7/2019 4th yr main report
17/39
package and i very useful at high frequencies with a reverse recovery ti e of not more than4ns. This permits rectification and detection of radio frequency signals very effectively, aslong as their amplitude is above the forward conduction threshold of silicon (around 0.7V) orthe diode is biased.
Figure no.11: 1N4148
Source: www.wikipedia
2.1.9 SCHOTT Y DIODE
Schottky diode schematic symbol
Figure no. 12: Schottky Diode
Source: www.wikipedia
A Schottky diode is a specialtype of diode with very low forward-voltage drop. Whencurrent flows through a diode there is a small voltage drop across the diode terminals. Anormal silicon diode has a voltage drop between 0.61.7 volts, while a Schottky diodevoltage drop is between approximately 0.150.45 volts. This lower voltage drop can providehigher switching speed and better system efficiency.
A Schottky diode uses a metalsemiconductorjunction as a Schottky barrier (instead of asemiconductorsemiconductorjunction as in conventional diodes). This Schottky barrierresults in both very fast switching and low forward voltage drop.
2.2.0 ZENE DIODE
-
8/7/2019 4th yr main report
18/39
Figure no. 13: zener diode
Source: www.wikipedia
Figure no. 14:zener diode characteristics
Source: www.wikipedia
Current-voltage characteristic of a Zener diode with a breakdown voltage of 17 volts.Noticethe change of voltage scale between the forward biased (positive) direction and the reverse
biased (negative) direction.
A Zener diode is a type of diode that permits current not only in the forward direction like anormal diode, but also in the reverse direction ifthe voltage is largerthan the breakdownvoltage known as "Zener knee voltage" or"Zener voltage".
The Zener diode's operation depends on the heavy doping ofits p-njunction allowingelectrons to tunnel from the valence band ofthe p-type materialto the conduction band ofthen-type material. In the atomic scale, this tunneling corresponds to the transport of valence
band electrons into the empty conduction band states; as a result ofthe reducedbarrierbetween these bands and high electric fields that are induced due to the relatively high levelsof dopings on both sides.The breakdown voltage can be controlled quite accurately in the
doping process. While tolerances within 0.05% are available, the most widely used tolerancesare 5% and 10%. Breakdown voltage for commonly available zener diodes can vary widelyfrom 1.2 volts to 200 volts.
2.2.1 ELECT OLYTIC CAPACITOR
-
8/7/2019 4th yr main report
19/39
Figure no. 15: electrolytic capacitor
Source: www.wikipedia
Axial lead (top) and radial lead (bottom) electrolytic capacitors
An electrolytic capacitor is a type of capacitor that uses an electrolyte, an ionic conducting
liquid, as one of its plates, to achieve a larger capacitance per unit volume than other types.They are often referred to in electronics usage simply as "electrolytics". They are used inrelatively high-current and low-frequency electrical circuits, particularly in power supplyfilters, where they store charge needed to moderate output voltage and current fluctuations inrectifier output. They are also widely used as coupling capacitors in circuits where AC should
be conducted but DC should not. There are two types of electrolytic; aluminum and tantalum.
Electrolytic capacitors are capable of providing the highest capacitance values of any type ofcapacitor. However they have drawbacks which limit their use. The voltage applied to themmust be polarized; one specified terminal must always have positive potential with respect tothe other. Therefore they cannot be used with AC signals without a DC bias. They also havevery low breakdown voltage, higher leakage current and inductance, poorer tolerances and
temperature range, and shorter lifetimes compared to other types of capacitors.
-
8/7/2019 4th yr main report
20/39
CHAPTER 3
3.0 BLOCK DIAGRAM:Below is the block representation of the whole project.
INTEL 8051MICRO-
CONTROLLER
MAX232
SECURITYLIGHTS
GATE
NOKIA3310
RECEIVER
REMOTE
USER
-
8/7/2019 4th yr main report
21/39
3.1BLOCK DIAGRAM DESCRIPTION
REMOTE USER PHONE
The person who wants to switch on/off the security lights and open or close the gate callsfrom the phone and, once the call gets picked up, enters the password and codes for acorresponding device.
RECEIVER MOBILE PHONEThe mobile phone on the receiver side picks up the phone automatically after 5seconds, andthen makes the signal available to the max 232.
THE MAX 232
It provides an interface between the receiver mobile phone and the microcontroller. Itconverts the RS-232 signal to TTL/CMOS logic level signal that are fed to themicrocontroller.
MICROCONTROLLER:The output of the max 232 serves as an input to port 1 of the microcontroller. Then the signal
is verified by the programmed microcontroller and once a correct sequence of code isreceived, output corresponding to the signal sent by the user is made available at the port0,which is connected to motor and the bulb and TDA 2003.
-
8/7/2019 4th yr main report
22/39
3.2 COMPONENTS SPECIFICATIONS:
INTEL 8051:
y High performance HMOS processy Internal timers/event countersy 2-level interrupt priority structurey
32 I/O lines(Four 8-bit ports)y 64K program memory spacey Boolean processory Bit addressable RAMy Programmable full duplex serial channely 111 instructions(64-single cycle)y Analog to Digital Converter
NOKIA 3310:
Manufacturer: Nokia
Available: 2000
Screen: monochrome display, 84 x 48
Default ringtone: monophonic ringtones
Networks: GSM
Battery: 900 mAh Li-Ion
Physical size: 113x48x22 mmWeight: 133 g
Predecessor: Nokia 3210
Successor:Nokia 3410
Nokia 3510
MAX232
FEATURES:
y Input voltage levels are compatible with standard MOS levels.y
Output voltage levels are compatible with EIA/TIA-232-E levelsy Single Supply voltage: 5Vy Low input current: 0.1A at A= 25 y Output current: 24mAy Latching current not less than 450mA at A= 25y The transmitter outputs and receiver inputs are protected to 15kV Air ESD
-
8/7/2019 4th yr main report
23/39
78L05 THREE TERMINAL VOLTAGE REGULATOR:
The output voltage is +5V, and the maximum output current is about 100mA.
The maximum input voltage is +35V.
ELETROL TIC CAPACITORS: 16V rated
1N4148:
Specifications:
y VRRM = 100V (Maximum Repetitive Reverse Voltage)y IO = 200mA (Average Rectified Forward Current)y IF = 300mA (DC Forward Current)y IFSM = 1.0 A (Pulse Width = 1 sec), 4.0 A (Pulse Width = 1 Sec) (Non-Repetitive
Peak Forward Surge Current)y PD = 500 mW (power Dissipation)y TRR< 4ns (reverse recovery time)
DC MOTOR: 9V DC
SPEAKERS: 10W,4.
During design a LED was connected to the microcontroller as an indicator as follows
5V 5V
Switch
GND
GND
Figureno.17: Ledinterface
Source: Drawnfrom MS Word
The circuit for TDA 2003 was used to interface the speaker to Intel 8051.
8051 40
P1.4 P0.5
Intel 8051
-
8/7/2019 4th yr main report
24/39
Vs
100F C3 C4 0.1F
C1 5
Vin1 TDA 4 C4
2 2003
R1 C5 SPEAKERC2
R4 R3
Figure no.18: TDA2003 audio amplifier circuit
Source: Drawnfrom MS Word
3.3COMPLETE CIRCUIT:
-
8/7/2019 4th yr main report
25/39
The circuit below was constructed and implemented to come up with the device.
M
MAX 232
78L05
INTEL
8051
-
8/7/2019 4th yr main report
26/39
3.4PROGRAMMING THE MICROCONTROLLER:
THE FLOW CHART DIAGRAM
Figure no.20: Flow chart diagram
Source: Drawnfrom MS Word
START
PORT INITIALISATION
RECEIVE THE CALLAND DECODING THEFLASH CALL TIME
CONTROLWORDS?
COMPARE WITHAVAILABLE CONTROLWORDS.
CONVERT THE COTROL WORD
TO SUITABLE DATA OUTPUTSIGNAL TO CONTROL THEOPERATIONS.
SEND THE SIGNAL TOAPPROPRIATEINTERFACE CIRCUITS.
QUIT?
END
-
8/7/2019 4th yr main report
27/39
The following programs were implemented in the project.
ORG 0HSJMP 30H
ORG 0HMOV a,#00
BACK: ACALL DELAYINC a; dec a for binary down counterJNZ BACKHERE:SJMP HEREDELAY: MOV r1,#0FFHDECR1:MOV r2,#0FFHDECR: MOV r3,#OFFHDJNZ r3,$DJNZ r2,DECRRNSIT 16
SETB P1.4; make p 1.4 an input (initializing)BACK; JB P1.4, LED ON; jump if byte = 1
CPL P0.5; Switch off LED P0.5SJMP BACK; keep doing it
LED ON: SETB P0.5; turn on LED if switch is pressedSJMP BACK; keep doing it
END
ORG 0H; Reset VectorSJMP 30HORG 0BH; TF0 vectorSJMP ISRORG 30HMOV a,#00MOV R0,#0MOV R1,#0MOV TMOD,#02H; 00000010-Run timer0 in mode 2MOV TH0,#118; Set up timer 0 to overflow in 0.05msecMOV IE,#82H ; %10000010 Enable timer0 interruptSETB TCON.4; Start the timer0HERE:SJMP HEREISR: CLR TCON.4; Disable timer0INC r; r1*r2 = 100*200 = 20000 * 0.05msec = 1secCJNE r1,#100,SKIPMOV r1,#00
INC r0CJNE r0,#200,SKIPMOV r0,#00H
INC aSKIP: SETB TCON.4; Enable TimerRETI; Return from interrupt subroutineEND
-
8/7/2019 4th yr main report
28/39
ORG 0HSJMP 30H
ORG 30HMOV TMOD,#20H //timer 1; mode 2
MOV TH1,#-3; -3=FD loaded into TH1 for 9600 baud, 11.0592MHz.MOV SCON,#50H //8-bit, 1 stop bit, REN enabled
SETB TR; Start timer 1AGAIN:MOV A,#y; transfer yACALL TRANSMOV a,#E; transfer EACALL TRANSAGAIN1:SJMP AGAIN1TRANS: MOV SBUF,a; load SBUFHERE:JNB TI,HERE; Wait for last bit to transferCLR TI; get ready for next byteRET
END
-
8/7/2019 4th yr main report
29/39
CHAPTER4
GSM TECHNOLOGY AND SHORT MESSAGING SERVICE
4.0 GSM TECHNOLOGY
GSMis a global system for mobile communication GSMis an internationaldigital cellulartelecommunication. The GSM standard was released by ETSI (European StandardTelecommunication Standard) backin 1989. The first commercial services were launched in1991 and afterits early introduction in Europe;the standard went globalin 1992. Since then,GSM has become the most widely adopted and fastest-growing digital cellular standard, and itis positioned to become the worlds dominant cellular standard. Todays second-generationGSM networks deliver high quality and secure mobilevoice and data services (such as SMS/
TextMessaging) with full roaming capabilities across the world. GSM platform is a hugelysuccessfultechnology and as unprecedented story of global achievement. In less than ten years
since the first GSM network was commercially launched, it become, the worlds leading andfastest growing mobile standard, spanning over 173 countries. Today, GSMtechnology is in
use by more than one in ten ofthe worlds population and growth continues to sour with thenumber of subscriber worldwide expected to surpass one billion by through end of 2003.
Todays GSM platform is living, growing and evolving and already offers an expanded andfeature-rich family of voice and enabling services. The Global System forMobile
Communication (GSM) networkis a cellulartelecommunication network with a versatilearchitecture complying with the ETSI GSM 900/GSM 1800 standard. Siemens implementation
is the digital cellular mobile communication system D900/1800/1900 that uses the very latesttechnology to meet every requirement ofthe standard.
-
8/7/2019 4th yr main report
30/39
-
8/7/2019 4th yr main report
31/39
-
8/7/2019 4th yr main report
32/39
32
The SMSC transfer the message in a Short Message Delivery Point to Point format to the servingsystem. The system pages the device, and if it responds, the message gets delivered. The SMSCreceives verification that the message was received by the end user, then categorizes the messageas sent and will not attempt to send again. SMS provides a mechanism for transmitting shortmessage to and from wireless devices. The service makes use of an SMSC, which acts as a storeand forward system for short messages. One major advantage of SMS is that it is supported by100% GSM mobile phones. Almost all subscription plans provided by wireless carriers include
inexpensive SMS messaging service.
4.1.1What makes SMS messaging so successful worldwide? SMS is so success all over theworld. SMS messaging is now one of the most important revenue sources of wireless carriers.Some of the reasons are discussed below.
SMS Messages can be sent and read at any time SMS Message can be sent to an offline
Mobile Phone. SMS Messaging is less disturbing while you can still stay in touch. SMS aresupported by 100% GSM Mobile Phones and they can be Exchanged
between different wireless carriers
4.1.2SMS Service Providers (SMS Gateway Providers, SMS Resellers, SMS
Brokers)There is a demand for SMS connectivity from applications that does not requirethe sending or receiving of large amount of SMS messages. One example is a remote monitoringsystem. If the remote monitoring system finds that a certain server is not
responding, it will send an SMS alert to the system administrator mobile phone. This remotemonitoring system will have a very small amount of SMS traffic per month since the servers beingmonitored should be working fine most of the time. Since a wireless carrier usually doesntprovide direct SMSC or SMS gateway access to user without a large amount of SMS traffic, somecompanies come out to fill the gap. These companies are called SMS service providers. SMSservice providers are also known as SMS gateway providers, SMS resellers and SMS brokers
because of the following reasons:
SMS gateway providers-: An SMS service provider provides an SMS gateway for its user tosend SMS message to. This SMS gateway will then route the SMS message to another SMSgateway or SMSC.
SMS reseller and SMS broker-: SMS service provider buy a large amount of SMS messagefrom a lot of wireless carrier at low price per SMS message. They then sell the SMS messageat a price higher than the cost.
Another advantage of using the SMS connectivity services of SMS service providers is that theirnetwork coverage is very good. They work hard to cover as many wireless networks as possible soas to make their services attractive. 4.1.3Short Message Service Center (SMSC) SMSC is a
combination of hardware and software responsible for the relaying and storing and forwarding ofshort message between an SME and mobile device. The SMSC must have high reliability,subscriber capacity, and message throughput. In addition, the system should be easily scalable toaccommodate growing demand for SMS in the network.
-
8/7/2019 4th yr main report
33/39
33
CHAPTER 5
5.0THECOMPLETE ASSEMBLED DEVICE
-
8/7/2019 4th yr main report
34/39
34
Below is the complete device that was assembled and programmed.
Figure no. 21: The completeassembled device
Source: Phototaken after presentation
-
8/7/2019 4th yr main report
35/39
35
CHAPTER 6
CONCLUSION
The design was a big success. The GSM microcontroller based premise control is a super device
that uses the current affordable technology to offer good services the people. It makes
technology affordable to all, since currently most of the people possess mobile phones. This is a
good manifestation of the future of mobile phones as it renders as mobile phone a multipurpose
device.
-
8/7/2019 4th yr main report
36/39
36
CHAPTER 7
RECOMMENDATION
y The device should be kept under secure conditions away from interference of otherelectronic devices in the premise.
y It should be inspected regularly to ensure efficient operation.y The premise should be within a good reception of the GSM network coverage.y
With thorough and intensive research the project can be made simpler and cheaper.
-
8/7/2019 4th yr main report
37/39
37
APPINDEX
THE WORK PLAN
WEEKS
Feb2010-April 2010
ACTIVIT
1 2 3 4 5 6 7 8 9 10
Have everything bought.
Gathering comprehensive information forcircuit design.
Design circuit for the system.
Assembling of the components
Testing for continuity of the circuit and itsability to work.
Wrote the assembly language program.
Compiling and loading the program
Test, Test, Test and troubleshoot bugs.
General review.
Presentation.
-
8/7/2019 4th yr main report
38/39
38
PRICE LIST
Component Quantity Price/one Total price(KSH)
Resistance 5 25 25
Zener Diode 2 10 20
Ceramic Cap. 2 5 10
Electrolytic Cap. 11 5 55
Crystal 1 200 200IC 78L05 1 80 80
1N4148 5 10 50
IC INTEL 8051 1 1500 1500
DC motor 1 250 250
MAX 232 1 150 150
PCB 1 200 200
Bulb 1 150 150
Nokia 3310 1 1800 1800
Nokia download cable 1 400 400
Speaker 1 200 200
TOTAL COST 5090
-
8/7/2019 4th yr main report
39/39
REFERENCES:
www.8051projects.netwww.edaboard.comMazidi-8051 microcontrollerMax 232 and 8051 Datasheetswww.electrosofts.com/serial