GSM MODEM USING HOME AUTOMATION                         A PROJECT REPORT                             Submitted by         ...
MEENAKSHI ACADEMY OF HIGHER EDUCATION AND RESEARCH              (MEENAKSHI UNIVERSITY)(Established under Section 3 of the ...
ACKNOWLEDGEMENT        We are greatly indebted to our beloved chancellorThiru. A.N. Radha Krishnan M.A., D.Com. for giving...
ABSTRACT  The development of GSM-based control home appliances for smart home system.  The main aim of the prototype devel...
TABLE OF CONTENTSCHAPTER                 TITLE                                PAGE NONO.                   ABSTRACT       ...
4.   MICRO CONTROLLER AT89C51RD2BN         4.1 Details of Microcontroller        21         4.2 Block Diagram             ...
LIST OF TABLESTABLE NO.         TITLE                        PAGE NO.  2.1       PIN Details of LCD                    10 ...
LIST OF FIGURES NO.             TITLE                        PAGE NO.  2.1    Block Diagram                         2  2.2...
LIST OF ABBREVIATIONSGSM         Global System for Mobile CommunicationsSMS         Short Message ServiceSIM         Subsc...
CHAPTER 1                                 INTRODUCTION                    The development of digital information has led t...
CHAPTER 2                                 CONTROL SYSTEMControl System consists of the following components      •   Power...
Block diagram of the home appliance control system using SMS.The Mobile Phone is integrated with the microcontroller ATMEG...
U 10                     5V                                                                          5V                   ...
VCC           V CC                                                              10K PO T                                  ...
AT89C51 Controller:    This is the heart of the control system which control the device(s) based on the SMS.    ULN 2003 t...
data from an RS-232 interface the voltage has to be reduced. Also the low and highvoltage level has to be inverted. This l...
Applications include relay drivers, hammer drivers, lamp drivers, display drivers (LEDgas Discharge), line drivers, and lo...
presence of a “high” level at the input and drives the relay from another voltage    source. Hence the relay is used to sw...
• Type: Reflective Yellow Green    • Interface : 4 Bit Mode    • Number of characters: 16 characters*2 lines.    • Power S...
A GSM Modem could be a standard GSM mobile phone with the appropriate cable andsoftware driver to connect to a serial port...
became later the acronym for Global System for Mobile communications). Thestandardized system had to meet certain criteria...
1989       The responsibility of the GSM specifications is passed to the ETSI1990       Appearance of the phase 1 of the G...
adopted and fastest-growing digital cellular standard, and it is positioned to become theworld’s dominant cellular standar...
4G             High-speed Wireless Broadband3.3 ARCHITECTURE OF GSM NETWORKThe GSM technical specifications define the dif...
at the beginning. Later it was ported to wireless technologies like CDMA and TDMA.The GSM and SMS standards were originall...
mobile phones. Almost all subscription plans provided by wireless carriers includeinexpensive SMS messaging service.3.5 SP...
AT+CMGF=1 <ENTER> If the modem responds with "OK" this mode is supported.Please note that using this mode it is only possi...
To check if your modem supports this text mode, you can try the following command:AT+CMGF=1 <ENTER> If the modem responds ...
COMMANDS                     RESPONDING                 SMS SEND TO THE                             ON / OFF IN HARDWARE  ...
•   Fully Static Operation: 0 Hz to 33 MHz    •   Three-level Program Memory Lock    •   256 x 8-bit Internal RAM    •   3...
ACCUMULATOR (ACC): Accumulator is a general-purpose register, which storesruntime results. Before performing any operation...
ones, or read from them an existing status. Ports represent physical connection ofCentral Processing Unit with an outside ...
Port 1 (P1): Port 1 is I/O port. Having the "pull up" resistor, Port 1 is fully compatible      with TTL circuits. The alt...
Pin    Alternate Name           Alternate Function         P3.0   RXD                      Serial input         P3.1   TXD...
SP is decremented by one. The number in Stack Pointer points to the location of the last"valid" address within the Stack. ...
Interrupts: An interrupt is a signal from a device attached to a computer or from aprogram within the computer that causes...
When a word is given to the UART for Asynchronous transmissions, a bit calledthe "Start Bit" is added to the beginning of ...
Fig: LDR Fig: Example Circuitry                 This is an example of a light sensor circuit. When the light level is lowt...
device and the resulting output signal. In the case of a photocell, one is dealing with therelationship between the incide...
Applications:Analog Applications· Camera Exposure Control· Auto Slide Focus - dual cell· Photocopy Machines - density of t...
CHAPTER 6                                POWER SUPPLY UNIT5.1 POWER SUPPLY CIRCUIT         Power supply is to provide the ...
•   Smoothing: The raw DC from the rectifier is far from constant falling to zero        when the AC waveform crossed the ...
CHAPTER 6                                    CONCLUSIONRecent development in Science and Technology provide a wide range o...
CHAPTER 8                                     REFERENCES               1) David Tse, Pramod Viswanth (2005) “Fundamentals ...
9) FLOYD: Digital Fundamentals, Universal Book Stall, New Delhi, 1993               10)George Kennedy: Electronic Communic...
Upcoming SlideShare
Loading in...5
×

Yuvaraja project

767

Published on

Published in: Technology, Business
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
767
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
25
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Yuvaraja project

  1. 1. GSM MODEM USING HOME AUTOMATION A PROJECT REPORT Submitted by YUVARAJA.R 6109314 In partial fulfillment for the award of the degree of BACHELOR OF ENGINEERING IN ELECTRONICS & COMMUNICATION ENGINEERING MEENAKSHI ACADEMY FOR HIGHER EDUCATION AND RESEARCH WEST K.K. NAGAR CHENNAI - 600078 June 20121|Page
  2. 2. MEENAKSHI ACADEMY OF HIGHER EDUCATION AND RESEARCH (MEENAKSHI UNIVERSITY)(Established under Section 3 of the UGC Act, 1956 vide Notification No.F.9-5/2002-U.3, dt.31.03.2004) BONAFIDE CERTIFICATECertified that this project report “GSM MODEM USING HOMEAUTOMATION” is the Bonafide work of YUVARAJA.R ( 6109314 )carried put the research under my supervision. Certified further, that to the best ofmy knowledge, the work reported herein does not form part of any other projectreport or dissertation on the basis of which a degree or award was conferred on anearlier occasion on this or any other candidate[SUPERVISOR] [HEAD OF THE DEPARTMENT]Evaluated and Viva Voce Conducted on: ………………………….INTERNAL EXAMINER EXTERNAL EXAMINER2|Page
  3. 3. ACKNOWLEDGEMENT We are greatly indebted to our beloved chancellorThiru. A.N. Radha Krishnan M.A., D.Com. for giving an opportunity to completethis project work. We are thankful to our Vice Chancellor – In chargeDr.P.Jayakumar MDS for his kind help rendered to us in finishing this projectsuccessfully. We also express our sincere thanks to the director of part time courseMs.V.PriyankaRajan M.A., M.B.A., B.Ed., M.Phil., L.L.B., for extending valuableassistance. We would like to express our sincere thanks to our project guideMr. M.Tamil Selvan ME., Asst. Professor for providing valuable guidance andextensive support. I express my gratitude to my friends for their support in all aspects toaccomplish this project. I deem it fit to thank all the staff of Mechanical engineering dept, who helpedme a lot during the project work and nurtured an environment of creativity and support.3|Page
  4. 4. ABSTRACT The development of GSM-based control home appliances for smart home system. The main aim of the prototype development is to reduce electricity wastage. GSM module was used for receiving short message service (SMS) from user’s mobile phone that automatically enable the controller to take any further action such as to switch ON and OFF the home appliances such as light, air-conditioner etc. The system can be controlled and monitored via SMS from anywhere that covered by GSM service. For example if you are aside of your home, you want control and monitor appliances like motor, TV, lights, air-conditioner etc. by sending a SMS to the GSM modem presented in home you can monitor all the above appliances and you can also control some appliances like fans and AC. Whenever you send SMS to do specific task GSM modem will send an acknowledgement to the user so that user can know the status of his request. The system was integrated with microcontroller and GSM network interface using Embedded C language. The system is activated when user sends the SMS to controller at home. Upon receiving the SMS command, the microcontroller unit then automatically controls the electrical home appliances by switching ON or OFF the device according to the user order4|Page
  5. 5. TABLE OF CONTENTSCHAPTER TITLE PAGE NONO. ABSTRACT iv LIST OF TABLE vii LIST OF FIGURES ix LIST OF ABBREVIATIONS x 1. INTRODUCTION 1 2. CONTROL SYSTEM 2 2.1 Block diagram 2 2.2 Components Descriptions 3 2.2.1 Max-232 Circuit 4 2.2.2 Driver Circuit 6 2.2.3 Relay Circuit 7 2.2.4 LCD Display 9 2.2.5 LDR circuit 3. GSM MODEM 11 3.1 History of Cellular Mobile Radio 12 3.2 Evolution of GSM 14 3.3 Architecture of GSM Network 16 3.4 SMS in GSM 16 3.5 Specification GSM Modem 18 3.6 Commands used in GSM Modem 195|Page
  6. 6. 4. MICRO CONTROLLER AT89C51RD2BN 4.1 Details of Microcontroller 21 4.2 Block Diagram 23 4.3 Pin Diagram 24 4.4 Specification 24 4.5 Pin descriptions 25 4.6 Architectural overview 27 5. POWER SUPPLY UNIT 34 6. CONCLUSION 38 7. REFRENCES 396|Page
  7. 7. LIST OF TABLESTABLE NO. TITLE PAGE NO. 2.1 PIN Details of LCD 10 3.1 Events in the development of GSM 14 4.1 Status Register 28 4.2 General purpose working register 30 4.3 Program memory map 337|Page
  8. 8. LIST OF FIGURES NO. TITLE PAGE NO. 2.1 Block Diagram 2 2.2 MAX-232 Circuit 5 2.3 ULN2003 Pin configuration & Internal Structure 6 2.4 ULN2003 Circuit with Relay 7 2.5 Relay Structure 8 3.1 LCD wring diagram 9 3.2 Architecture of the GSM network 16 3.3 Block Diagram of ATMEGA-168 23 3.4 Pin Diagram of ATMEGA-168 24 3.5 Architectural overview 27 5.1 SMPS Block Diagram 34 5.2 Pin Diagram 36 5.3 Voltage regulator circuit Diagram 36 5.4 Power Supply Wiring Diagram 378|Page
  9. 9. LIST OF ABBREVIATIONSGSM Global System for Mobile CommunicationsSMS Short Message ServiceSIM Subscriber Identity ModuleSMPS Switched Mode Power SupplyISP In System ProgramESTI European Standard Telecommunication InstituteRISC Reduced Instruction Set ComputerPDU Protocol Data UnitEMF Electro Magnetic FieldGPRS General Packet Radio ServiceEDGE Enhanced Data for GSM EvolutionCDMA Code Division Multiple AccessTDMA Time Division Multiple AccessISDN Integrated Services Digital Network9|Page
  10. 10. CHAPTER 1 INTRODUCTION The development of digital information has led the rapid change inhuman lifestyle. The use of electricity is very important as one of the main source ofenergy that is vital in today modern life. Some kinds of mechanism using availabletechnology could be used to reduce wastage in electricity usage. Thus a prototype basedon a microcontroller device using SMS is developed. It can automatically control anyelectrical equipment at home remotely using Mobile phone.GSM (SMS) Controlled system which is capable of receiving a set of commandinstructions in the form of Short message service and performs the necessary actionslike ON, OFF and STATUS. We will be using a dedicated modem/mobile at thereceiver module i.e., with the commands using SMS service as per the required actions.The mobile unit which is connected with an intellectual device called Micro controllerso that it takes the responsibility of reading the received commands in the from of SMSfrom the mobile unit and perform the corresponding predefined tasks such as deviceON, OFF and STATUS10 | P a g e
  11. 11. CHAPTER 2 CONTROL SYSTEMControl System consists of the following components • Power Supply Circuit • GSM Modem • MAX232 Circuit • AT89C51RD2BN Microcontroller • ULN 2003 to Driver • LDR • Relay • LCD Display • Keil C Language • Controlled Devices2.0 BLOCK DIAGRAM11 | P a g e
  12. 12. Block diagram of the home appliance control system using SMS.The Mobile Phone is integrated with the microcontroller ATMEGA168, which receivesSMS message from user Mobile Phone and sends a command to AVR to controlwhether to turn ON or OFF the output.The Mobile Phone also sends status reporting to the user regarding the electricalappliance. The system utilizes a low cost microcontroller that is currently available inthe market. The development of this device involves with both hardware and softwareto provide a preferable results.2.1 SCHEMATIC DIAGRAMAT89C51 INTERFACING RTC ,MEMORY AND ULN280312 | P a g e
  13. 13. U 10 5V 5V 1 14 U 8 2 1A VC C 13 R EL AY 1 U 14 + C 3 31 39 3 1Y 6A 12 1 1 8 R EL AY 2 C 1 E A /V P P 0 .0 38 4 2A 6Y 11 2 1 7 LED 1 C R Y STAL 19 P 0 .1 37 5 2Y 5A 10 3 1 6 LED 2 X1 P 0 .2 36 6 3A 5Y 9 4 1 5 LED 3 R 1 Q 2 P 0 .3 35 7 3Y 4A 8 5 1 4 LED 4 C 2 18 P 0 .4 34 G N D 4Y 6 1 3 1k X2 P 0 .5 33 7 1 2 P 0 .6 32 8 1 1 9 P 0 .7 74H C 14 9 1 03 2 .6 7 8 K H Z U 5 R ESET 21 R S U LN 2803 P 2 .0 22 EN X3 1 8 5V 12 P 2 .1 23 LC D O X1 VC C 7 13 IN T 0 P 2 .2 24 LC D 1 2 O U T 6 14 IN T 1 P 2 .3 25 LC D 2 3 X2 SC L 5 S 1 D5 A T0 P 2 .4 26 LC D 3 4 BAT SD A T1 P 2 .5 27 1 B T1 G N D 1 P 2 .6 28 2 P 1 .0 /T 2 P 2 .73 .3 V D S1307 3 P 1 .1 /T 2 X 17 4 P 1 .2 R D 16 U 4 P 1 .3 W R 2 5 29 6 P 1 .4 PSEN 30 5 4 7 P 1 .5 A L E /P 11 6 3 8 P 1 .6 TXD 10 7 2 P 1 .7 R XD 8 1 8052 5V 24C 16AT89C51 INTERFACING 16X2 LCD AND MAX 23213 | P a g e
  14. 14. VCC V CC 10K PO T 1 2 5 3 9 P1 .0 4 4 P1 .1 5 8 CT S P1 .2 6 TXD 3 P2 .0 7 7 RXD RT S U1 P2 .1 8 2 P2 .2 9 6 39 21 P2 .3 10 1 P 0.0 P 0.0/ AD0 P2. 0/A 8 P 0.1 38 22 P2 .4 11 37 P 0.1/ AD1 P2. 1/A 9 23 P2 .5 12 P 0.2 P 0.2/ AD2 P 2. 2/A 10 36 24 P2 .6 13 Connec t or DB9 P 0.3 P 0.3/ AD3 P 2. 3/A 11 35 25 P2 .7 14 P 0.4 P 0.4/ AD4 P 2. 4/A 12 P 0.5 34 26 15 33 P 0.5/ AD5 P 2. 5/A 13 27 16 P 0.6 P 0.6/ AD6 P 2. 6/A 14 32 28 P 0.7 P 0.7/ AD7 P 2. 7/A 15 1 10 LCD P 1.0 P3. 0/RX D 2 11 3 P 1.1 P3. 1/ TXD 12 P 1.2 P3. 2/ INT0 P 3. 2 4 13 P 1.3 P 1.3 P3. 3/ INT1 P 3. 3 P 1.4 5 14 P 1.4 P 3.4/ T0 P 3. 4 P 1.5 6 15 P 1.5 P 3.5/ T1 P 3. 5 7 16 6 V CC P 1.6 P 1.6 P 3. 6/WR P 3. 6 1 8 17 9 P 1.7 P 1.7 P3. 7/RD P 3. 7 R2OUT 19 10 C X1 T 2IN 30 C 0. 1M F ALE A LE V 33pF 11.0592M Hz 29 12 2 PS EN P SE N- R1OUT V+ 11 6 18 1 T 1IN V- X2 C1+ 31 0. 1M F EA 33pF RST 9 20 0. 1M F 15 40 RST 3 GND V CC C1- 14 T1OUT RTS VCC 4 13 V CC C2+ R1I N CTS 89C51 1 0. 1M F 8 R XD 2 5 R2I N 7 T XD PS EN- 3 C2- T2OUT I CL232 T iny S witc h2.2 COMPONENTS DESCRIPTIONS Power Supply circuit: The STEP DOWN Transformer gives the 12v AC then regulator and filter will gives the 12v DC delivered to MCU Circuits & Relays GSM Modem: GSM Modem receives the signal and converts the data and pushes instruction to microcontroller. MAX232 Circuit: It is an interface between GSM Modem and Microcontroller.14 | P a g e
  15. 15. AT89C51 Controller: This is the heart of the control system which control the device(s) based on the SMS. ULN 2003 to Driver: It is power driver circuit that controls the relay(s). Relay: The Relay is connected to the output device(s). LCD Display: This displays the status of the device. LDR: Light dependent resistor using light intensity dependent to lights on Embedded C Language: The software is used to program the AT89C51 Controller. Controlled Device: The wide variety of home appliances and such as Lights, Fans, etc. can be connected. LED: Light Emitting Diode ) is a semiconductor light source2.2.1 Max-232 Circuit When communicating with various micro processors one needs to convertthe RS232 levels down to lower levels, typically 3.3 or 5.0 Volts. Serial RS-232 (V.24)communication works with voltages -15V to +15V for high and low. On the other hand,TTL logic operates between 0V and +5V .Modern low power consumption logic operates in the range of 0V and +3.3V or evenlower. Thus the RS-232 signal levels are far too high TTL electronics, and the negativeRS-232 voltage for high can’t be handled at all by computer logic. To receive serial15 | P a g e
  16. 16. data from an RS-232 interface the voltage has to be reduced. Also the low and highvoltage level has to be inverted. This level converter uses a Max232 and fivecapacitors..The MAX232 from Maxim was the first IC which in one package containsthe necessary drivers and receivers to adapt the RS-232 signal voltage levels to TTLlogic. Fig 2.2 MAX-232 Circuit2.2.2 DRIVER CIRCUITULN 2803:The ULN2003 is a monolithic high voltage and high current Darlington transistorarrays. It consists of seven NPN Darlington pairs that feature high-voltage outputs withcommon-cathode clamp diode for switching inductive loads. The collector-currentrating of a single Darlington pairs 500mA. The Darlington pairs may be paralleled forhigher current capability.16 | P a g e
  17. 17. Applications include relay drivers, hammer drivers, lamp drivers, display drivers (LEDgas Discharge), line drivers, and logic buffers. The ULN2803 has a 2.7kW series baseresistor for each Darlington pair for operation directly with TTL or 5V CMOS devices.Specification: • High Voltage, High Power Relay control • Max: 7 Relay • 500mA rated collector current ( Single output ) • High-voltage outputs: 50V • Inputs compatible with various types of logic. • Relay driver application. Fig 2.4 ULN2803 Circuit with Led 1.2.3. RELAY CIRCUIT The relay driver is used to isolate both the controlling and the controlled device. The relay is an electromagnetic device, which consists of solenoid, moving contacts (switch) and restoring spring and consumes comparatively large amount of power. Hence it is possible for the interface IC to drive the relay satisfactorily. To enable this, a driver circuitry, which will act as a buffer circuit, is to be incorporated between them. The driver circuitry senses the17 | P a g e
  18. 18. presence of a “high” level at the input and drives the relay from another voltage source. Hence the relay is used to switch the electrical supply to the appliances.Fig 2.5 Relay StructureNC: - Normally ConnectedNO: - Normally OpenCOM: - CommonThe common contact or moving contact establishes the GSM Based Control Systemconnection with a new terminal which is indicated as a normally open terminal “(N/O)”.Whenever, the supply coil is withdrawn the magnetizing force is vanished. Now, thespring pulls the moving contact back to initial position, where it makes a connectionmakes with N/C terminal. However, it is also to be noted that at this time also a backemf is produced. The withdrawal time may be in microsecond, the back emf may be inthe range of few kilovolts and in opposite polarity with the supplied terminals thevoltage is known as surge voltage. It must be neutralized or else it may damage thesystem2.2.4 LCD DISPLAYA liquid crystal display (LCD) is a thin, flat display device made up of any number ofcolor or monochrome pixels arrayed in front of a light source or reflector. It is oftenutilized in battery-powered electronic devices because it uses very small amounts ofelectric power.Specification: • Model: JHD162A18 | P a g e
  19. 19. • Type: Reflective Yellow Green • Interface : 4 Bit Mode • Number of characters: 16 characters*2 lines. • Power Supply : 5V DC Table 2.1: PIN Details of LCDLCD wring diagram CHAPTER 3 GSM MODEMA GSM Modem can be an external Modem device, such as the LINKTO. Insert a GSMSIM card into this Modem and connect the modem to an available serial port on thecomputer to check the performance of the same.19 | P a g e
  20. 20. A GSM Modem could be a standard GSM mobile phone with the appropriate cable andsoftware driver to connect to a serial port on the computer.3.1 HISTORY OF CELLULAR MOBILE RADIOThe idea of cell-based mobile radio systems appeared at Bell Laboratories (in USA) inthe early 1970s. However, mobile cellular systems were not introduced for commercialuse until the 1980s. During the early 1980s, analog cellular telephone systemsexperienced a very rapid growth in Europe, particularly in Scandinavia and the UnitedKingdom. Today cellular systems still represent one of the fastest growingtelecommunications systems. But in the beginnings of cellular systems, each countrydeveloped its own system, which was an undesirable situation for the followingreasons: • The equipment was limited to operate only within the boundaries of each coun- try. • The market for each mobile equipment was limited.In order to overcome these problems, the Conference of European Posts andTelecommunications (CEPT) formed, in 1982, the Group Special Mobile (GSM) inorder to develop a pan-European mobile cellular radio system (the GSM acronym20 | P a g e
  21. 21. became later the acronym for Global System for Mobile communications). Thestandardized system had to meet certain criteria: • Spectrum efficiency • International roaming • Low mobile and base stations costs • Good subjective voice quality • Compatibility with other systems such as ISDN (Integrated Services Digital Net- work) • Ability to support new servicesUnlike the existing cellular systems, which were developed using an analog technology,the GSM system was developed using a digital technology.In 1989 the responsibility for the GSM specifications passed from the CEPT to theEuropean Telecommunications Standards Institute (ETSI). The aim of the GSMspecifications is to describe the functionality and the interface for each component ofthe system, and to provide guidance on the design of the system. These specificationswill then standardize the system in order to guarantee the proper inter-working betweenthe different elements of the GSM system. In 1990, the phase I of the GSMspecifications was published but the commercial use of GSM did not start untilmid-1991. The most important events in the development of the GSM system arepresented in the table 1.Year Events CEPT establishes a GSM group in order to develop the standards for a pan-1982 European cellular mobile system TDMA is chosen as access method (in fact, it will be used with FDMA) Initial1987 Memorandum of Understanding (MoU) signed by telecommunication operators (representing 12 countries)21 | P a g e
  22. 22. 1989 The responsibility of the GSM specifications is passed to the ETSI1990 Appearance of the phase 1 of the GSM specifications1991 Commercial launch of the GSM service Enlargement of the countries that signed the GSM- MoU> Coverage of larger1992 cities/airports1993 Coverage of main roads GSM services start outside Europe1995 Phase 2 of the GSM specifications Coverage of rural areas Table 3.1: Events in the development of GSMFrom the evolution of GSM, it is clear that GSM is not anymore only a Europeanstandard. GSM networks are operational or planned in over 80 countries around theworld. The rapid and increasing acceptance of the GSM system is illustrated with thefollowing figures: • 1.3 million GSM subscribers worldwide in the beginning of 1994. • Over 5 million GSM subscribers worldwide in the beginning of 1995. • Over 10 million GSM subscribers only in Europe by December 1995.Since the appearance of GSM, other digital mobile systems have been developed. Thetable 2 charts the different mobile cellular systems developed since the commerciallaunch of cellular systems. 3.2 EVOLUTION OF GSM GSM is a global system for mobile communication GSM is aninternational digital cellular telecommunication. The GSM standard was released byETSI (European Standard Telecommunication Institute) back in 1989. The firstcommercial services were launched in 1991 and after its early introduction in Europe;the standard went global in 1992. Since then, GSM has become the most widely22 | P a g e
  23. 23. adopted and fastest-growing digital cellular standard, and it is positioned to become theworld’s dominant cellular standard.Today’s second-generation GSM networks deliver high quality and secure mobile voiceand data services (such as SMS/ Text Messaging) with full roaming capabilities acrossthe world. GSM platform is a hugely successful technology and as unprecedented storyof global achievement. In less than ten years since the first GSM network wascommercially launched, it become, the world’s leading and fastest growing mobilestandard, spanning over 173 countries. Today, GSM technology is in use by more thanone in ten of the world’s population and growth continues to sour with the number ofsubscriber worldwide expected to surpass one billion by through end of 2003.Today’s GSM platform is living, growing and evolving and already offers an expandedand feature-rich ‘family’ of voice and enabling services.The Global System for Mobile Communication (GSM) network is a cellulartelecommunication network with a versatile architecture complying with the ETSI GSM900/GSM 1800 standard. Siemen’s implementation is the digital cellular mobilecommunication system D900/1800/1900 that uses the very latest technology to meetevery requirement of the standard.The following GSM generation passed in 3decades:1G Analog Communication2G Digital Communications2.5G GPRS2.75G EDGE3G Enhanced feature of Video call23 | P a g e
  24. 24. 4G High-speed Wireless Broadband3.3 ARCHITECTURE OF GSM NETWORKThe GSM technical specifications define the different entities that form the GSMnetwork by defining their functions and interface requirements.The architecture of the GSM network is presented in figure 2. Fig. 3.1 Architecture of the GSM network 3.3 SMS IN GSMSMS stands for Short Message Service. It is a technology that enables the sending andreceiving of message between mobile phones. SMS first appeared in Europe in 1992. Itwas included in the GSM (Global System for Mobile Communication) standards right24 | P a g e
  25. 25. at the beginning. Later it was ported to wireless technologies like CDMA and TDMA.The GSM and SMS standards were originally developed by ETSI. ETSI is theabbreviation for European Telecommunication Standard Institute. 1.Now the 3GPP (Third Generation Partnership Project) is responsible for thedevelopment and maintenance of the GSM and SMS standards.One SMS message can contain at most 140 bytes (1120 bits) of data, so one SMSmessage can contain up to: • 160 characters if 7-bit character encoding is used. (7-bit character encoding issuitable for encoding Latin characters like English alphabets.) • 70 characters if 16-bit Unicode UCS2 character encoding is used. (SMS textmessages containing non-Latin characters like Chinese character should use 16-bitcharacter encoding.)Once the message is sent the message is received by SMSC, which must then get it tothe appropriate mobile device. To do this the SMSC sends a SMS request to HomeLocation Register (HLR) to find the roaming customer. Once HLR receives the request,it responds to the SMSC with the subscriber’s status:1 Inactive or active2 Where subscriber is roaming.SMS provides a mechanism for transmitting short message to and from wirelessdevices. The service makes use of an SMSC, which acts as a store and forward systemfor short messages. One major advantage of SMS is that it is supported by 100% GSM25 | P a g e
  26. 26. mobile phones. Almost all subscription plans provided by wireless carriers includeinexpensive SMS messaging service.3.5 SPECIFICATIONS OF GSM MODEMOutput PowerClass 4 2W @ 900MHzClass 1 1W @ 1800MHzInput voltage5V-24VDCInput current1A-2A5mA readiness for action, 140mA in GSM 900MHz @ 12V telephone conversationcondition5mA readiness for action, 100mA in GSM 1800/1900MHz @ 12V telephoneconversation conditionSMS service function-Writing and PDU-Point-to-point (MT/MO)-Plot broadcastRS232 connection-Orders with AT to make the remote control (GSM07.07 and 07.05)-Establishes contacts the baud rate by 300 to 1.15,2 million bits/s-Automatic baud rate (300 to 38,,400 bits/s)SMA antenna connection Slides into the type SIM card memory3.6 COMMANDS USED IN GSM MODEMReceiving SMS messages using AT commands26 | P a g e
  27. 27. AT+CMGF=1 <ENTER> If the modem responds with "OK" this mode is supported.Please note that using this mode it is only possible to send simple text messages. It isnot possible to send multipart, Unicode, data and other types of messages.Setting up the modem:In order to send a SMS, the modem has to be put in SMS text mode first using thefollowing command:AT+CMGF=1 <ENTER>If the modem responds with error, either the modem does not support SMS text mode,or the SIM card is not ready. In this case please check that the SIM card is inserted andthe pin code is entered.Reading a messageTo list a single message, you have to use the read command. You must use the listcommand first, so you know the indexes of the messages in the storage. For instance, toread the message on memory location 2 use:AT+CMGR=2 <ENTER>The modem will list the single message:+CMGR: "REC READ","+31625012254",,"07/07/05,09:56:03+08"Test message 2OKSend SMS using AT commandsSome advanced GSM modems like Waveform and Multitask, support the SMS textmode. This mode allows you to send SMS messages using AT commands, without theneed to encode the binary PDU field of the SMS first. This is done by the GSM modem27 | P a g e
  28. 28. To check if your modem supports this text mode, you can try the following command:AT+CMGF=1 <ENTER> If the modem responds with "OK" this mode is supported.Please note that using this mode it is only possible to send simple text messages. It isnot possible to send multipart, Unicode, data and other types of messages.Sending the message:AT+CMGS="+31638740161" <ENTER> Replace the above phone number with yourown cell phone number. The modem will respond with:>You can now type the message text and send the message using the <CTRL>-<Z> keycombination:Hello World ! <CTRL-Z>After some seconds the modem will respond with the message ID of the message,indicating that the message was sent correctly:+CMGS: 62SMS responding Relay or light power ON / OFF commands list.SMS SENDING COMMAND CURRENT STATUS28 | P a g e
  29. 29. COMMANDS RESPONDING SMS SEND TO THE ON / OFF IN HARDWARE OWNER NUMBER*xxxxxS1ON# AC POWERED ON AC OFF*xxxxxS2ON# LIGHT POWERED ON LIGHT OFF*xxxxxS3ON# FAN POWERED ON FAN OFF*xxxxxS4ON# MOTOR POWERED ON MOTOR OFF*xxxxxS1OF# AC POWERED OFF AC OFF*xxxxxS2OF# LIGHT POWERED OFF LIGHT OFF*xxxxxS3OF# FAN POWERED OFF FAN OFF*xxxxxS4OF# MOTOR POWERED OFF MOTOR OFF*xxxxxPASSxxxxxx# PASSWORD CHANGING PASSWORD CHANGED FORMAT OLD TO NEW*xxxxxSTAT# ALL APPLICATIONS STATUS AC ON | IN LIGHT OFF | ARE SEND TO THE OWNER MOTOR ON | FAN ON | NUMBER OUT LIGHT OFF*xxxxxxTIME TIME AND DATE UPDATED TO ------DDMMYYHHMMSS# RTC*xxxxxxRONOFddmmyyhh TIME DEPENDENT RELAY ON/ ------ddmmyyhh# OFF*xxxxxxPHON9791260935# OWNER NUMBER CHANGING OWNER NUBER COMMAND CHANGED MICRO CONTROLLER AT89C51RD2BNFeatures: • Compatible with MCS-51® Products • 8K Bytes of In-System Programmable (ISP) • Write/Erase Cycles • 4.0V to 5.5V Operating Range29 | P a g e
  30. 30. • Fully Static Operation: 0 Hz to 33 MHz • Three-level Program Memory Lock • 256 x 8-bit Internal RAM • 32 Programmable I/O Lines • Three 16-bit Timer/Counters • Eight Interrupt Sources • Full Duplex UART Serial Channel • Low-power Idle and Power-down Modes • Interrupt Recovery from Power-down Mode • Watchdog Timer • Dual Data Pointer • Power-off Flag AT89c51 pin diagram It has a 64k program memory space (flash) and 64k external data memory space.One special 16 bit programmable counter array (PCA) is present. It also providessystem programming (ISP) facility and operates at 20 MHz max. clock operation.Philips 89c51 has the features of on-chipPWM generation & watchdog timer facility suited for motor control applications. 3.2 89C51 architecture30 | P a g e
  31. 31. ACCUMULATOR (ACC): Accumulator is a general-purpose register, which storesruntime results. Before performing any operation upon an operand, operand has to bestored in the accumulator. Results of arithmetical operations are also stored in theaccumulator. When transferring data from one register to another, it has to go throughthe accumulator. Due to its versatile role, this is the most frequently used register,essential part of every MCU. B REGISTER: B Register is used along with the Accumulator for multiplication and division. This B register provides temporary storage space for the result of multiplication & division operation. Instructions of multiplication and division can be applied only to operands located in registers A and B. Other instructions can use this register as a secondary accumulator (A).PORTS: Term "port" refers to a group of pins on a microcontroller which can beaccessed simultaneously, or on which we can set the desired combination of zeros and31 | P a g e
  32. 32. ones, or read from them an existing status. Ports represent physical connection ofCentral Processing Unit with an outside world. Microcontroller uses them in order tomonitor or control other components or devices. 89C51 has 4 ports; with each port have8-bit length. All the ports are bit and byte addressable. Port 0 (P0): Port 0 has two-fold role: If external memory is used, P0 behaves as address output (A0 – A7) when ALE pin is at high logical level, or as data output (Data Bus) when ALE pin is at low logical level, otherwise all bits of the port are either input or output. Another feature of this port comes to play when it has been designated as output. Unlike other ports, Port 0 lacks the "pull up" resistor (resistor with +5V on one end). This seemingly insignificant change has the following consequences:• When designated as input, pin of Port 0 acts as high impedance offering the infinite input resistance with no "inner" voltage.• When designated as output, pin acts as "open drain". Clearing a port bit grounds the appropriate pin on the case (0V). Setting a port bit makes the pin act as high impedance. Therefore, to get positive logic (5V) at output, external "pull up" resistor needs to be added for connecting the pin to the positive pole.Therefore, to get one (5V) on the output, external "pull up" resistor needs to be addedfor connecting the pin to the positive pole.32 | P a g e
  33. 33. Port 1 (P1): Port 1 is I/O port. Having the "pull up" resistor, Port 1 is fully compatible with TTL circuits. The alternate functions of Port1 are Pin Alternate Name Alternate Function P1.0 T2 Serial input P1.1 T2EX Serial output P1.2 ECI External interrupt 0 P1.3 CEX0 External interrupt 1 P1.4 CEX1 Timer 0 external input P1.5 CEX2 Timer 1 external input P1.6 CEX3 Signal write to external memory P1.7 CEX4 Signal read from external memoryPort 2 (P2): When using external memory, this port contains the higher address byte (addresses A8–A15), similar to Port 0. Otherwise, it can be used as universal I/O port.Port 3 (P3): Beside its role as universal I/O port, each pin of Port 3 has an alternate function. In order to use one of these functions, the pin in question has to be designated as input, i.e. the appropriate bit of register P3 needs to be set. By selecting one of the functions the other one is disabled. From a hardware standpoint, Port 3 is similar to Port 0. The alternate functions of Port 3 is given below33 | P a g e
  34. 34. Pin Alternate Name Alternate Function P3.0 RXD Serial input P3.1 TXD Serial output 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 P3.6 WR Signal write to external P3.7 RD memory Signal read from external memoryData Pointer (DPTR) : The Data pointer register is made up of two 8 bit registers,named DPH (Data Pointer High) and DPL (Data Pointer Low). These registers are usedto give addresses of the internal or external memory. The DPTR is under the control ofprogram. DPTR is also manipulated as one 16 bit register, DPH & DPL are eachassigned an address. The 89C51 microcontroller has additional DPTR. The dual DPTRstructure is a way by which the chip will specify the address of an external data memorylocation. There are two 16-bit DPTR registers that address the external memory, and asingle bit called DPS (bit0 in AUXR1) that allows the program code to switch betweenthem.Stack Pointer (SP) : The stack refers to an area of internal RAM that is used inconjunction with certain opcodes to store and retrieve data quickly. The register used toaccess the stack is called Stack Pointer. The 8 bit stack pointer register is used by the89C51 to hold an internal RAM address that is called then top of the stack. The stackpointer increments before storing the data on the stack. As retrieved from the stack the34 | P a g e
  35. 35. SP is decremented by one. The number in Stack Pointer points to the location of the last"valid" address within the Stack. With the beginning of every new routine, StackPointer increases by 1; upon return from routine, SP decreases by 1. Upon reset (orturning the power on), the stack pointer contains the value 07h.Program Counter (PC): Used to access code memory. Program counter always pointsto the address of the next instruction in memory to be executed. Upon reset (or turningthe power on), the program counter resets to the starting location of the program.Instruction Register: When an instruction is fetched from the Flash memory, it is loadedin the instruction register.Timing & Control unit: The timing and control unit synchronizes the operation of themicrocontroller and generates control signals necessary for communication between themicrocontroller and the peripherals.Program Status Word (PSW): The Program Status Word (PSW) register is an 8 bitregister. It is also referred to as the flag register. It contains the math flags, user programflag F0, and the register select bits that identify which of the four general purposeregister banks is currently in use by the program.Oscillator: Oscillator circuit is used for providing a microcontroller with a clock. Clockis needed so that microcontroller could execute a program or program instructions.Stable pace provided by the oscillator allows harmonious and synchronous functioningof all other parts of MCU. The manufacturers make available 89C51 designs that canrun at specified maximum and minimum frequencies, typically 1 megahertz to 33megahertz. Minimum frequencies imply that some internal memories are dynamic andmust always operate above a minimum frequency or data will be lost.35 | P a g e
  36. 36. Interrupts: An interrupt is a signal from a device attached to a computer or from aprogram within the computer that causes the main program that operates the computerto stop and points out what to do next. In general, there are hardware interrupts andsoftware interrupts. A hardware interrupt is related to the hardware of the system. Forexample, when an I/O operation is completed such as reading some data into thecomputer from a keyboard interrupt the main program. As the name implies thesoftware interrupts related to the software of the system. It occurs when an applicationprogram terminates or requests certain services from the operating system.Timers/Counters: Timers are usually the most complicated parts of a microcontroller.Physically, timer is a register whose value is continually increasing to FFFFh, and thenit starts all over again: 0h, 1h, 2h, 3h, 4h...FFFFh....0h, 1h, 2h, 3h......etc. The 89C51MCU clock employs a quartz crystal. As this frequency is highly stable and accurate, itis ideal for time measuring. Since one instruction takes 12 oscillator cycles to complete,the math is easy. 89C51 has three Timers/Counters marked as T0, T1 & T2. Theirpurpose is to measure time and count external occurrences, but can also be used asclock in serial communication purpose called as, Baud Rate.Serial Port: Serial port is used to provide communication among two devices. Serialdata communication has been widely used for long distance communication because ofthe ease and the economy of using only one wire to transmit data. Serial port is alsoreferred as RS232 port. RS232 is a asynchronous way of communication.Asynchronous transmission allows data to be transmitted without the sender having tosend a clock signal to the receiver. Instead, the sender and receiver must agree ontiming parameters in advance and special bits are added to each word, which are used tosynchronize the sending and receiving units.36 | P a g e
  37. 37. When a word is given to the UART for Asynchronous transmissions, a bit calledthe "Start Bit" is added to the beginning of each word that is to be transmitted. The StartBit is used to alert the receiver that a word of data is about to be sent, and to force theclock in the receiver into synchronization with the clock in the transmitter. CHAPTER 5LIGHT DEPENDENT RESISTOR: LDRs or Light Dependent Resistors are very useful especially inlight/dark sensorcircuits. Normally the resistance of an LDR is very high, sometimes ashigh as 1000 000ohms, but when they are illuminated with light resistance drops dra-matically. Two cadmium sulphide (cds) photoconductive cells with spectral responsessimilar to that of the human eye. The cell resistance falls with increasing light intensity.Applications include smoke detection, automatic lighting control, and batch countingand burglar alarm systems.37 | P a g e
  38. 38. Fig: LDR Fig: Example Circuitry This is an example of a light sensor circuit. When the light level is lowthe resistance of the LDR is high. This prevents current from flowing to the base of thetransistors. Consequently the LED does not light. However, when light shines onto theLDR its resistance falls and current flows into the base of the first transistor and thenthe second transistor. The LED lights. The preset resistor can be turned up or down toincrease or decrease resistance, in this way it can make the circuit more or less sensi-tive.There are just two ways of constructing the voltage divider, with the LDR at the top, orwith the LDR at the bottom:You are going to investigate the behaviour of these two circuits. You will also find outhow to choose a sensible value for the fixed resistor in a voltage divider circuit.Remember the formula for calculatingVout : Rbottom x Vin Rbottom x RtopSensitivity:The sensitivity of a photo detector is the relationship between the light falling on the38 | P a g e
  39. 39. device and the resulting output signal. In the case of a photocell, one is dealing with therelationship between the incident light and the corresponding resistance of the cell.Fig2: Resistance as function of Illumination Fig3: Spectral ResponseSpectral Response:Like the human eye, the relative sensitivity of a photoconductive cell is dependent onthe wavelength (color) of the incident light. Each photoconductor material type has itsown unique spectral response curve or plot of the relative response of the photocell ver-sus wavelength of light.Electrical Characteristics:39 | P a g e
  40. 40. Applications:Analog Applications· Camera Exposure Control· Auto Slide Focus - dual cell· Photocopy Machines - density of toner· Colorimetric Test Equipment· Densitometer • Digital Applications • Automatic Headlight Dimmer • Night Light Control • Oil Burner Flame Out • Street Light Control • Absence / Presence (beam breaker) • Position Sensor40 | P a g e
  41. 41. CHAPTER 6 POWER SUPPLY UNIT5.1 POWER SUPPLY CIRCUIT Power supply is to provide the required level of DC power to the load using anAC supply at the input. Different applications require different attributes, but more of-ten than not these days DC power supplies provide an accurate output voltage - this isregulated using electronic circuitry so that it provides a constant output voltage over awide range of output loads.In most power supplies there are number of different elements. These may not all bepresent in every design. • Input transformer: The input transformer is used to transform the incoming line voltage down to the required level for the power supply. Typically the input transformer provides a step down function. It also isolates the output circuit from the line supply. • • Rectifier: The power supply rectifier converts the incoming signal from an AC format into raw DC. Either half wave or more commonly full wave rectifiers may be used as they make use of both halves of the incoming AC signal.41 | P a g e
  42. 42. • Smoothing: The raw DC from the rectifier is far from constant falling to zero when the AC waveform crossed the zero axis, and then rising to its peak. The ad- dition of a reservoir capacitor here fills in the troughs in the waveform, enabling the next stage of the power supply to operate. Large value capacitors are normal- ly used within this stage. • • Regulator: This stage of the power supply takes the smoothed voltage and uses a regulator circuit to provide a constant output virtually regardless of the output current and any minor fluctuations in the input level. Fig 5.3 Voltage regulator circuit Diagram42 | P a g e
  43. 43. CHAPTER 6 CONCLUSIONRecent development in Science and Technology provide a wide range of scope ofapplication of reduction power wastage. This project is useful in the domestic as well inthe industrial applications. It has the scope to enhance several devices by appropriateadd-on circuits. Even the Fire or Smoke detector can be configured to report to the user.The cost involved is moderate and the status can be sent to the user(s) for the decision43 | P a g e
  44. 44. CHAPTER 8 REFERENCES 1) David Tse, Pramod Viswanth (2005) “Fundamentals of Wireless Communication” Cambridge University Press, Edition-I 2) Goankar Ramesh Goankar (2006), “Fundamentals of Microcontroller and applications in Embedded system with PIC” Cengafe Demalmar Learning Publishers,Edition-1 3) Larry O Cull,Richard Bennett, Sarah Cox (2003), “Embeded C Programming and Microchip PIC” Cengage Demalmar Learning Publishers Edition-I 4) Siegmund Redl, Mathias K.Weber (1995), “Introduction to GSM” Artech house Publishers Edition-1 5) Thodre S. Rapport (2001), “Wireless Communication Principle and Practice” Pearson Educaion Publishers. Edition-2 6) John B.Peatman (1988), “Design with Microcontrollers” McGraw Hill International Edition-1 7) A. Bruce Carlson, Communication Systems, Tata McGraw Hill, 1986 8) Edward C. Jordan and Keith G. Balmain, “Electromagnetic waves and radiating systems”, Prentice Hall, 2nd Edition, 1995.44 | P a g e
  45. 45. 9) FLOYD: Digital Fundamentals, Universal Book Stall, New Delhi, 1993 10)George Kennedy: Electronic Communication Systems, Tata McGraw Hill Publications, 199245 | P a g e

×