Fig-3.13.1: Circuit diagram to decode DTMF code using MT8870⦠..... operating systems are supported in mobile phone such as Symbian, java, android, RT-.
AN AUTOMATED LOAD CONTROL SYSTEM USING GSM NETWORK
Submitted By
Kazi Mijan Hossain
Piplu Chandra Kirtania
ID No: EEEE-110100042
ID No: EEEE-100300034 Supervised By
Ashraful Arefin Assistant Professor Department of Electrical & Electronic Engineering Northern University Bangladesh
February 2015 Department of Electrical & Electronic Engineering
NORTHERN UNIVERSITY BANGLADESH
DECLARATION We, hereby, declare that the work presented in this report is the outcome of the project work performed by us under the supervision of Ashraful Arefin, Assistant Professor, Department of Electrical & Electronic Engineering, Northern University Bangladesh.
We also declare that no part of this project and thereof has been or is being submitted elsewhere for the award of any degree or Diploma.
Signature
Kazi Mijan Hossain ID: EEEE-110100042
Piplu Chandra Kirtania ID: EEEE-100300034
Countersigned
Ashraful Arefin Assistant Professor Department of Electrical & Electronic Engineering Northern University Bangladesh
i
APPROVAL This is to certify that the Project titled “An Automated Load Control System using GSM Network” by Kazi Mijan Hossain, ID: EEEE-110100042, and Piplu Chandra Kirtania, ID: EEEE100300034, has been carried out under our supervision. The project has been carried out in partial fulfillment of the requirements for the degree of Bachelor of Science (B.Sc.) in Electrical & Electronic Engineering in the year of 2015 and has been approved as to its style and contents. The project report has been approved by the following members of the project defense committee.
Board of Examination
_________________________________________ Ashraful Arefin (Supervisor) Assistant Professor Department of Electrical & Electronic Engineering Northern University Bangladesh
_______________________________________________________
Lecturer Department of Electrical & Electronic Engineering Northern University Bangladesh
Lecturer Department of Electrical & Electronic Engineering Northern University Bangladesh
__________________________________________________________
Engr. Md. Badiuzzaman Associate Professor and Head Department of Electrical & Electronic Engineering Northern University Bangladesh ii
ABSTRACT Generally most of the remote control systems use “Infrared Sensor”, which have a limited range and load capacity. An automated load control systems has been developed in this purpose by using GSM network. The main benefit is, this system can be operated from any place in the world where the mobile phone network is available. A number of loads can be controlled. To do this ATmega32 microcontroller has been introduced. In the receiver part, the audio signal, sent from the controller phone is converted to digital data. This digitized signal is sent to the microcontroller. The microcontroller takes decisions according to this digital data regarding which load is going to be turned on or turned off.
iii
ACKNOWLEDGEMENT Thanks to the Almighty, the Creator and the Sustainer who has given us the strength and opportunity to complete the project titled, “An Automated Load Control System Using GSM Network”.
We would like to express our gratitude and appreciation our supervisor, Ashraful Arefin, for his guidance in the execution of the thesis, for keeping us on our toes, and for his kind understanding. Our acknowledgment also goes out to the project presentation assessor.
We would like to thanks our Honorable Head, Faculty of Science and Engineering also. Finally, we express our greetings to all our friends and teachers who have influenced and encouraged of us to develop this project.
The Authors February 2015
iv
TABLE OF CONTENTS Declaration………………………………………………………………………………………
i
Approval…………………………………………………………………………… …………..
ii
Abstract………………………………………………………………………………………….
iii
Acknowledgement………………………………………………………………. .. …………...
iv
Table of Contents………………………………………………………………… …………….
v
List of figure…………………………………………………………………………………….
viii
Chapter 1: Introduction 1.1
Introduction………………………………………………………………………………..
1
1.2
Objective of the project………………………………………………………………….
1
1.3
Methodology………………………………………………………………………………
1
1.4
Block Diagram……………………………………………………………………………
2
1.5
Result………………………………………………………………………………………
2
1.6
Outline of the Project…………………………………………………………………….
2
Chapter 2: GSM Network 2.1
Definition…………………………………………………………………………………..
3
2.2
GSM Architecture………………………………………………………………………….
4
2.3
Mobile Originated-MO call flow in GSM……………………………………………….
7
2.4
GSM Channels…………………………………………………………………………….
8
2.5
GSM Physical Layer………………………………………………………………………
8
2.6
GSM Protocol stack……………………………………………………………………….
12
2.7
GSM Mobile Phone……………………………………………………………………….
14
2.8
GSM RF Planning………………………………………………………….......................
20
v
Chapter 3: Equipment Details 3.1
Transformer………………………………………………………………………………
23
3.2
Diode………………………………………………………………………......................
27
3.3
Resistor………………………………………………………………………………….. .
32
3.4
Cristal Oscillator…………………………………………………………………………
34
3.5
Relay……………………………………………………………………………………..
35
3.6
Capacitor…………………………………………………………………………………
37
3.7
Switch…………………………………………………………………………………….
40
3.8
Socket……………………………………………………………………………….........
40
3.9
Cell phone………………………………………………………………………………..
41
3.10 Signal Connector…………………………………………………………………...........
44
3.11 Terminal block……………………………………………………………………...........
45
3.12 IC-ATMEGA32…………………………………………………………..….…………...
45
3.13 IC-MT8870……………………………………………………………………………….
49
3.14 IC-ULN2803………………………………………………………………………...........
54
3.15 IC-7805…………………………………………………………………………………....
56
3.16 IC-7812………………………………………………………………………….………...
58
Chapter 4: Circuit Constriction and Working Principle 4.1
Circuit Diagram……………………………………………………………………………
60
4.2
Transformer stage………………………………………………………………………….
61
4.3
Voltage regulation stage…………………………………………………. ………………
61
4.4
Signal receiving stage……………………………………………………………………
62
4.5
Signal Conversion stage………………………………………………......……………
62
4.6
Program Compiling stage………………………………………………………………. .
63
4.7
Essential Signal output stage……………………………………………………………. .
64
4.8
Relay stage……………………………………………………………….……………......
65
4.9
Load supply……………………………………………………………………………….
66
4.10 Physical structure of real project………………………………………………. ……….
66
vi
Chapter 5: Conclusion and Future work. 5.1
Conclusion ……………………………………………………………..…………………
67
5.2
Achievement…………………………………………………………………………….....
67
5.3
Future Work………………………………………………………………………………
67
References…………………………………………………………………………………………. 68 Appendix…………………………………………………………………………………………... 69
vii
LIST OF FIGURES Fig-1.4.1:
Block Diagram an Automated Load Control System Using GSM Network……
02
Fig-2.2.1:
GSM Architecture………………………………………………………………
04
Fig-2.3.1:
GSM Physical Layer……………………………………………………………
07
Fig-2.5.1:
GSM Physical layer transmitter modules as depicted………………………….
09
Fig-2.6.1:
GSM protocol stacks……………………………………………………………
13
Fig-2.7.1:
GSM mobile phone block diagram……………………………………………..
15
Fig-2.8.1:
GSM Radio Frequency planning………………………………………………
22
Fig-3.1.1:
Transformer Construction………………………………………………………
24
Fig-3.1.2:
E.M.F Equation of a Transformer………………………………………………
25
Fig-3.2.1:
The Basic Diode Symbol and Static I-V Characteristics……………………….
28
Fig-3.2.2:
A Reverse Biased Junction showing the Increase in the Depletion Layer……..
29
Fig-3.2.3:
Reverse Characteristics Curve for a Diode…………………………………….
30
Fig-3.2.4:
Forward Characteristics Curve for a Diode……………………………………
31
Fig-3.2.5:
Forward Biased Junction Diode showing a Reduction in the Depletion Layer..
32
Fig-3.3.1:
Resistor…………………………………………………………………………
33
Fig-3.4.1:
Cristal Oscillator……………………………………………………………….
34
Fig-3.5.1:
Relay…………………………………………………………………………...
36
Fig-3.7.1:
Switch………………………………………………………………………….
40
Fig-3.9.1:
GSM mobile phone block diagram……………………………………………
42
Fig-3.10.1:
Signal Connector………………………………………………………………
44
Fig-3.12.1:
Pin diagram IC-ATMEGA32………………………………………………….
47
Fig-3.12.2:
Block diagram IC-ATMEGA32………………………………………………
48
Fig-3.13.1:
Circuit diagram to decode DTMF code using MT8870……………………….
51
Fig-3.13.2:
Connection Diagram for MT8870…………………………………………….
52
Fig-3.14.1:
Pin Diagram of IC-ULN2803…………………………………………………
55
Fig-3.14.2:
Circuit diagram of IC ULN 2803……………………………………………..
55
Fig-3.15.1:
Fixed Voltage Regulator……………………………………………………...
57
Fig-3.16.1:
IC -7812………………………………………………………………………
58
Fig-4.1.1:
Circuit diagram of An Automated Load Control System Using GSM Network
60
Fig-4.2.1:
Transformer stage…………………………………………………………….
61
Fig-4.3.1:
Voltage Regulating Stage…………………………………………………….
32
Fig-4.4.1:
Signal Receiving Stage……………………………………………………….
62
viii
Fig-4.5.1:
Signal Conversion Stage……………………………………………………
63
Fig-4.6.1:
Program Compiling Stage…………………………………………………..
64
Fig-4.7.1:
Essential Signal Output Stage………………………………………………
64
Fig-4.8.1:
Relay Stage ………………...………………………………………………
65
Fig-4.10.1:
Physical Structure of the real Project………………………………………
66
ix
C ha pt e r 1 Int r o duc t i o n 1.1.
Introduction:
In rapidly changing dynamically electronics technology world, we are trying to place an idea control two or more load in remote operation from any where in the world, it’s like as a world wide remote control system by applying GSM network. Remote load control using GSM network is an open standard technology, which is used GSM network not creating impact on GSM traffic.
1.2.
Objective of the project:
Our present generation is science and technological generation. This progresses background is strongly keeping our technological up gradation. So we have tried to keep up little bit contribution in the part of technological up gradation process. We want to give a worldwide basis remote control device for our technological generation. Whose work will be saved our time, manually operation bypassed, two or more load operates, easily command throws, and with other features have stock in this device.
1.3.
Methodology: Studying on the GSM Network Studying on the C Program Studying on the Transformer Studying on the Logic gate Studying on the Integrated Circuit(IC) Studying on the Transistor Studying on the Crystal Oscillator Studying on the Relay Coil
1
1.4. Block Diagram:
Signal Sender
----
Mobile
Signal Receiver
Signal Program --- Converter ----- Compiler
AC Load
----
Mobile
Fig-1.4.1: Block Diagram an Automated Load Control System Using GSM Network
1.5. Result: The performance of the system has been tested in lab. So that has been achieved goal. It can successfully load ON and OFF over GSM Network.
1.6. Outline of the Project: In Chapter 2: GSM Network In Chapter 3: Equipments Details In Chapter 4: Circuit Construction and Working Principle In Chapter 5: Conclusion and Future work Reference and Appendix
2
desired
Chapter-2 GSM Network 2.1.
Definition:
Global system for mobile communication (GSM) is a globally accepted standard for digital cellular communication. GSM is the name of a standardization group established in 1982 to create a common European mobile telephone standard that would formulate specifications for a pan-European mobile cellular radio system operating at 900 MHz it is estimated that many countries outside of Europe will join the GSM partnership.
Cellular is one of the fastest growing and most demanding telecommunications applications. Throughout the evolution of cellular telecommunications, various systems have been developed without the benefit of standardized specifications. This presented many problems directly related to compatibility, especially with the development of digital radio technology. The GSM standard is intended to address these problems. From 1982 to 1985 discussions were held to decide between building an analog or digital system. After multiple field tests, a digital system was adopted for GSM. The next task was to decide between a narrow or broadband solution. In May 1987, the narrowband time division multiple access (TDMA) solution was chosen. GSM provides recommendations, not requirements. The GSM specifications define the functions and interface requirements in detail but do not address the hardware. The reason for this is to limit the designers as little as possible but still to make it possible for the operators to buy equipment from different suppliers. The GSM network is divided into three major systems: the switching system (SS), the base station system (BSS), and the operation and support system (OSS). 3
2.2.
GSM Architecture:
GSM Architecture:
Fig-2.2.1: GSM Architecture
4
The Switching System: The switching system (SS) is responsible for performing call processing and subscriber-related functions. The switching system includes the following functional units.
Home location registers (HLR) —The HLR is a database used for storage and management of subscriptions. The HLR is considered the most important database, as it stores permanent data about subscribers, including a subscriber's service profile, location information, and activity status. When an individual buys a subscription from one of the PCS operators, he or she is registered in the HLR of that operator.
Mobile services switching center (MSC) —The MSC performs the telephony switching functions of the system. It controls calls to and from other telephone and data systems. It also performs such functions as toll ticketing, network interfacing, common channel signaling, and others.
Visitor location registers (VLR) —The VLR is a database that contains temporary information about subscribers that is needed by the MSC in order to service visiting subscribers. The VLR is always integrated with the MSC. When a mobile station roams into a new MSC area, the VLR connected to that MSC will request data about the mobile station from the HLR. Later, if the mobile station makes a call, the VLR will have the information needed for call setup without having to interrogate the HLR each time.
Authentication center (AUC) —A unit called the AUC provides authentication and encryption parameters that verify the user's identity and ensure the confidentiality of each call. The AUC protects network operators from different types of fraud found in today's cellular world.
equipment identity register (EIR) —The EIR is a database that contains information about the identity of mobile equipment that prevents calls from stolen, unauthorized, or defective mobile stations. The AUC and EIR are implemented as stand-alone nodes or as a combined AUC/EIR node.
5
The Base Station System (BSS): All radio-related functions are performed in the BSS, which consists of base station controllers (BSCs) and the base transceiver stations (BTSs).
BSC —The BSC provides all the control functions and physical links between the MSC and BTS. It is a high-capacity switch that provides functions such as handover, cell configuration data, and control of radio frequency (RF) power levels in base transceiver stations. A number of BSCs are served by an MSC.
BTS —the BTS handles the radio interface to the mobile station. The BTS is the radio equipment (transceivers and antennas) needed to service each cell in the network. A group of BTSs are controlled by a BSC.
The Operation and Support System: The operations and maintenance center (OMC) is connected to all equipment in the switching system and to the BSC. The implementation of OMC is called the operation and support system (OSS). The OSS is the functional entity from which the network operator monitors and controls the system. The purpose of OSS is to offer the customer cost-effective support for centralized, regional and local operational and maintenance activities that are required for a GSM network. An important function of OSS is to provide a network overview and support the maintenance activities of different operation and maintenance organizations.
Additional Functional Elements: Other functional elements shown in Figure 2 are as follows:
Message center (MXE) —The MXE is a node that provides integrated voice, fax, and data messaging. Specifically, the MXE handles short message service, cell broadcast, voice mail, fax mail, e-mail, and notification.
Mobile service node (MSN) —The MSN is the node that handles the mobile intelligent network (IN) services. 6
Gateway mobile services switching center (GMSC) —A gateway is a node used to interconnect two networks. The gateway is often implemented in an MSC. The MSC is then referred to as the GMSC.
GSM interworking unit (GIWU) —The GIWU consists of both hardware and software that provides an interface to various networks for data communications. Through the GIWU, users can alternate between speech and data during the same call. The GIWU hardware equipment is physically located at the MSC/VLR.
2.3. Mobile Originated-MO calls flow in GSM: GSM physical layer is nothing but the modules through which speech will pass through before they are transmitted in the air. These modules are depicted in the figure below. This page on GSM tutorial covers GSM speech processing modules at layer-1 i.e. Physical layer.
Fig-2.3.1: GSM Physical Layer These modules are speech coding, channel coding, interleaving, ciphering, burst assembly, modulation. Speech coding block uses 13kbps RELP (Residually Excited Linear Predictive coder). Channel coding block uses convolution coding of rate 1/2 with constraint length of 5. Interleaving block does diagonal interleaving, after 456 encoded bits in 20ms duration are broken into 57 bits sub-blocks.
7
There will be about total 8 sub blocks of 57 bits each. Ciphering block uses A3 and A5 encryption algorithms. Encryption is changed call by call to enhance privacy. Burst assembly block frames the burst as required by GSM frame structure. The same is modulated and Gaussian filtered. Modulation block minimizes the occupied BW using GMSK modulation with BT of 0.3. For more details on GSM Physical layer refer our page in articles section with link mentioned below in related links.
2.4.
GSM Channels:
This page on GSM tutorial covers channel types logical GSM channels, physical GSM channels and mapping between them. It also covers GSM no combined channel configuration (51 frames multiform) and GSM combined channel configuration (51 frames multiform). There are two main types of GSM channels viz. physical channel and logical channel. Physical channel is specified by specific time slot/carrier frequency. Logical channel run over physical channel i.e. logical channels are time multiplexed on physical channels; each physical channel (time slot at one particular ARFCN) will have either 26 Frame MF (Multi-frame) or 51 Frame MF structure describe here. Logical channels are classified into traffic channel and control channel. Traffic channel carry user data. Control channels are interspersed with traffic channels in well specified ways.
2.5.
GSM Physical Layer:
This article describes GSM physical layer i.e. layer-1 which sits below GSM layer-2(LAP Dm) we will discuss physical layer with respect to mobile station transmitter in detail. As shown in the block diagram, GSM physical layer composed of two main parts Baseband and RF. Baseband part consists of FEC(forward Error Correction),ciphering, burst formation and modulation. Information’s are passed through this layer before it is pumped into the air from Mobile device. Information is mainly of two types, traffic and control signals. Traffic is divided into speech and data. Control signals are mainly from upper layers and are used for establishing, maintaining and terminating connection of mobile station with the GSM network. All these three types of information’s are treated differently by physical layer in GSM. 8
Fig-2.5.1: GSM Physical layer transmitter modules as depicted
1. Source Encoding: Speech Encoding uses 13kbps RELP (Residually Excited Linear Predictive coder). For speech channel processing (TCH/FS and TCH/HS), 260 bits are occupied on 20 ms block. This source encoding block exists only for speech channel processing. TCH stands for traffic channel. FS stands for full rate speech and HS for half rate speech. For data channel (TCH) processing, 240 bits are sent in 20 ms blocks. For control channel processing, maximum of 184 bits (23 octets) are transmitted. These speech/data as well as signaling information bits are inputted to the next block (FEC).
Based on what information is fed as input to GSM layer 1 i.e. GSM physical layer, cyclic encoder configuration, convolution encoder (coding rate, polynomials) and interleaving is done. This information can be speech, data or control signal.
9
2. Forward Error Correction coding: Let us see how this information’s go through the convolution coding block first.
2a. Channel coding for Speech TCH/FS: 260 bit block is divided using splitter block and passed as mentioned below: For Step
TCH/FS 1.
50
bits
cyclic pass
through
encoder CRC
of and
3
(n,k)=(53,50) bits
are
added,
is gives
used. 53
bits
Step 2. 132 bits Step 3. 78 bits Output of Step 1, i.e. 53 bits are added with 132 bits and 4 tail bits are added, which will give 189 bits. These 189 bits are fed as input to rate 1/2 convolution encoder (C.E.). This gives 378 bits. 378 bits are added with 78 bits, this gives 456 bits in 20ms. These bits of 456 are mapped to bursts using interleaving module.
2b. Channel coding for Data: Here 240 bits are input to the C.E. module after 4 tail bits are added. This gives 488 bits, out of which 32 bits are punctured which produces 456 bits in 20 ms. Passed to GSM interleaving module.
2c. Channel coding for Signaling or control channel: Here signaling information of about 184 bits are fire coded using block encoder (cyclic encoder of (n,k)=(224,185) is used) which gives 224 bits(after 40 parity bits are added) Four zero bits are added, which produces 228 bits. This 228 bits are given as input to rate 1/2 C.E. which produces 456 bits, this is passed to interleaving block. For RACH, n=14 and k=8 is used. For SCH n=35, k=25isused 3. Interleaving : In GSM physical layer, interleaves are of three types based on control, speech or data channel. 10
The function of interleave is interleaving of information bits on to bursts. More than one burst carry data for one channel. The same is explained below for different types of channels.
Interleaving for GSM control channel 456 bits are divided into eight blocks of 57 bits each. Different blocks here carry different bit positions. for example, 1st block contains bit numbers [0,8,16,...448], 2nd block contains bit numbers [1,9,17,...449], 3rd block contains bit numbers [2,10,18,...450], 4th block contains bit numbers [3,11,19,...451], 5th block contains bit numbers [4,12,20,...452], 6th block contains bit numbers [5,13,21,...453], 7th block contains bit numbers [6,14,22,...454], 8th block contains bit numbers [7,15,23,...455], The first 4 blocks(1st to 4th) are mapped to even number bits of 4 bursts. The last 4 blocks (5th to 8th) are mapped to odd number bits of the same 4 bursts. Hence the new control channel data repeats after 4 bursts, hence the interleaving depth is 4. This type of interleave is called as block rectangular interleave. Interleaving is not applied to RACH,FCCH and SCH.
Interleaving for GSM Speech channel Here eight sub blocks of 57 bits are mapped to 8 bursts. The first blocks of 57 bits are mapped to even number bits of four bursts consecutively. The other four sub blocks of 57 bits are mapped to odd number bits of next four fresh bursts and not the one used to map first four blocks. Hence new data starts after 8 bursts which is the interleaving depth. This GSM interleave is also named as block diagonal interleave. 4. Ciphering: Ciphering block in GSM physical layer, uses A3 and A5 encryption algorithms. Encryption is
11
changed call by call to enhance privacy or secrecy. Ciphering or encryption is not applied FCCH, SCH, BCCH, PCH, AGCH, and CBCH as these frames are meant for all Mobiles. Also these frames are very useful to be decoded by all the mobile subscribers to establish and maintain GSM connection.
5. Burst formation: Burst formation block frames the burst as required by GSM frame structure. For more on this read GSM tutorial in tutorials section.
6. Differential encoding and modulation: The data then is passed through differential encoder and modulation. Modulation block minimizes the occupied BW using GMSK modulation with BT of 0.3.
7. RF Transmitter: The modulated baseband information is unconverted and amplified before being transmitted over the air.
2.6.
GSM protocol stacks:
This article describes basics of GSM protocol stack which covers Layer-1, Layer-2 and Layer-3 modules of MS(Mobile Station),BTS(Base Transceiver Station),BSC(Base Station Controller) and MSC(Mobile Switching Center). To gain in depth knowledge one has to understand all the message
formats
of
all
the
modules
such
as
radio,
LAPD,
LAP
Dm
,
RRM,MM,CM,BTSM,BSSMAP,SCCP,MTP as described in 3GPP release documents. Following figure describes the GSM protocol stack at the GSM network elements.
12
Fig-2.6.1: GSM protocol stacks
As mentioned in the figure, FDMA/TDMA is the air interface (radio), also called Um interface. For more on this interface refer GSM tutorial in tutorials section. At MS, FDMA/TDMA is used which is also followed at BTS, BTS takes this format from MS and convert it to 64kbps digital format for the digital link and interfaces with BSC. BSC communicates with MSC in the same format. GSM Layer 2
Layer 2 is the data link layer, which does following three main functions. - Establish, maintain and tear down the link - Flow control -Error detection - Work on the Layer-3 frames At Layer-2 LAPD and LAP Dm is used. LAPD is the ISDN (Integrated Services Digital Network) protocol for D Channel. LAP Dm is the modified version of LAPD for mobile station. LAP Dm does not have CRC for Error detection. This layer uses any of the following formats to carry frames. 1.) Format A for DCCHs (for channels having no information field) 2.)Format B
13
for DCCHs (containing an information field) 3.) Format Bibs for BCCH, PCH, and AGCH. 4.) Format C for random access signals the maximum LAP Dm frame length is 23 bytes i.e. 184bits. Depending on type of frame format LAP Dm will have Address field (8 bits), Control field (8 bits), Frame Length (8 bits), signaling data (23 octets) and fill in data. Address field carry two important parameters C/R and SAPI. C/R indicates whether the frame is command or response and also mentions whether the direction of frame is BS to MS or from MS to BS. SAPI takes either value of 0, 3 or other values. For SAPI of 0 is used for messages from the RRM, MM and CC, and SAPI of value 3 for message from the SMS and Supplementary Services (SS) messages. Control field of this layer-2 contains sequence numbers and type field to differentiate various frames. There are three type of frames supported here, supervisory, unnumbered information transfer and control function (unacknowledged mode), numbered information transfer (multiform acknowledged mode). The frame length field contains the length of the layer 3 message within the information field of the LAP Dm frame. If the message is less than the length specified in parameter N201 (standard specifies this) of the radio interface, fill-in data octets are used to fill up the remaining gap. Value of fill-in data is specified in GSM TS document. LAPD at BTS converts potentially unreliable physical link of MS into reliable link. This connects with BSC's MTP part. This is done with the use of CRC and ARQ techniques. ARQ stands for Automatic Repeat Request. ARQ works on the principle of re-transmission of packet when the erroneous packet is received at the receiver. GSM protocol stack can be explored by studying deep into protocol layers at various network elements viz. MS, BTS, BSC and MSC.
2.7.
GSM Mobile Phone:
This article covers basics of mobile phone internal modules. It gives emphasis to GSM mobile phone. Typically Mobile phone will have display (LCD, touch screen), keypad, microphone, speaker, SIM card, battery, USB port, antenna, memory unit(RAM,ROM), camera, CODEC, RF part,
DAC/ADC,
baseband
part
(L1/Layer1/physical
layer)
running
on
DSP,
Application/protocol layers running on CPU, ON/OFF switch and Bluetooth/GPS features. For 14
Mobile Phone which works on GSM network baseband part (Layer 1) and protocol stack running on CPU differs, which will be based on GSM standard. For CDMA Mobile phone the same Layer 1 and protocol stack will be based on CDMA standard and so on for LTE, HSPA standard based mobile phones. Mobile phone provides connectivity with laptop/other devices using WLAN, Bluetooth and GPS. All these features are based on specific standard specifications designed. GSM Mobile phone is in use earlier days for only voice applications. Now-a-days it has become more popular for SMS/MMS and internet applications due to GPRS feature. After the introduction of Smartphone many applications such as face book, Orcus, Twitter, various games comes built-in with the phone. Now mobile phone has slowly taken the place of laptop for many of the applications. Following figure depicts components in a generic mobile phone irrespective to the technology on which they need to work such as GSM, CDMA, LTE and so on. We will understand Mobile Phone with respect to GSM standard here.
Fig-2.7.1: GSM mobile phone block diagram RF Part as shown in the figure, every mobile phone will have RF part which consists of RF frequency up converter and rf frequency down converter. For GSM system, up converter converts modulated 15
baseband signal (I and Q) either at zero IF (Intermediate frequency) or some IF to RF frequency (890-915 MHz). RF down converter converts RF signal (935 to 960 MHz) to baseband signal (I and Q). For GSM, GMSK modulation is used. There are two approaches employed in GSM Mobile phone receiver, i.e. heterodyne or homodyne. The basic component used for frequency conversion is mixer. To know more read our page on heterodyne vs homodyne. To know more on design of RF frequency converter one can refer our page in the articles section.
Antenna and Tx/Rx Switch Antenna is the metallic object which converts electro-magnetic signal to electric signal and vice versa. Commonly used antennas in the mobile phone are of various types such as helix type, planar inverted F type, and whip or patch type. Micro strip based patch type of antennas are popular among mobile phones due to its size, easy integration on the PCB and multi frequency band of operation. Today’s mobile phones support various GSM bands and also various technologies such as CDMA, LTE, Wi-MAX and also WLAN, Bluetooth and so on. In this scenario this type of patch antennas does the job. To know more on antenna refer antenna tutorial.
Tx/Rx Switch As there is only one antenna used for both transmit and receive at different times, Tx/Rx Switch is used to connect both Tx path and Rx path with antenna at different times. Tx/Rx Switch is controlled automatically by DSP based on GSM frame structure with respect to the physical slot allocated for that particular GSM mobile phone in both downlink and uplink. For FDD systems diplexer is used in place of switch which acts as filter to separate various frequency bands. To know RF switch basics and manufacturers read page on RF switch in terminology section.
16
Baseband Part This part basically converts voice/data to be carried over GSM air interface to I/Q baseband signal. This is the core part which changes modem to modem for various air interface standards viz. CDMA, Wi max, LTE, HSPA and more. It is often named as physical layer or Layer 1 or L1. It is ported usually on DSP (Digital Signal Processor) to meet latency and power requirements of mobile phone. For Speech/audio, codec is used to compress and decompress the signal to match the data rate to the frame it has to fit in. CODEC converts speech at 8 KHz sampling rate to 13 kbps rate for full rate speech traffic channel. To do this RELP (Residually Excited Linear Predictive coder) speech coder is used which packs 260 bits in 20 ms duration to achieve 13 kbps rate. The baseband or physical layer will add redundant bits to enable error detection as well as error correction. Error detection is obtained with CRC and error correction with forward error correction techniques such as convolution encoder (used at transmit part) and viterbi decoder (used at receive part). Other than this interleaving is done for the data of one burst which helps in spreading the error over the time hence helps receiver de-interleave and decode the frame(consecutively data burst) correctly. For more refer our page on GSM Physical Layer.
ADC and DAC ADC (Analog to Digital Converter) and DAC (Digital to Analog Converter) is used to convert analog speech signal to digital signal and vice versa in the mobile handset. At Transmit path, ADC converted digital signal is given to speech coder. There are various ADCs available; among them popular one is sigma delta type. AGC (Automatic Gain Control) and AFC (Automatic Frequency Control) is used in the receiver path to control gain and frequency. AGC helps maintain working of DAC satisfactorily, as it keeps signal within the dynamic range of DAC.AFC keeps frequency error within limit to achieve better receiver performance.
17
Protocol stack Other than physical layer there are other layers involved in GSM mobile phone to make it work with GSM network/base station. To know more on the protocol stack used in mobile refer GSM Protocol Stack. The entire protocol stack is ported on CPU of ARM or of any other type of processors.
Application layer It also runs on CPU. Various applications run in GSM mobile phone. It includes audio, video and image/graphics applications. It supports various audio formats such as MP3, MP4, WAV; rm. JPEG image formats are usually available. It supports video formats e.g.MPEG-1 to MPEG-5. Mobile phone supports CIF, QCIF video standard resolutions.
Operating system Various operating systems are supported in mobile phone such as Symbian, java, android, RTLinux, Palm. It runs on CPU of different manufacturers. For time critical applications RTOS (real-time operating system) is used.
Battery It is the only major source of power to make/to keep mobile phone functional. There are various types of batteries made of Nickel Cadmium, Nickel Metal Hydride, based on lithium, I-ion and so on. The major factors for designers are to reduce battery size, last for more talk time, increase battery life. Battery comes usually with 3.6 or 3.7 voltage and 600mAh or 960 mAh ratings. Battery Charger is usually provided with mobile phone to charge the mobile phone battery. Battery charger is AC to DC converter.
18
Connectivity (WLAN, Bluetooth, USB, GPS) To make data transfer fast enough between mobile phone and other computing devices(laptop, desktop, tablet) or between mobile and mobile various technologies are evolved which include WLAN, Bluetooth, USB. GPS (global positioning system) is used for location assistance and will enable Google map to work efficiently.
Microphone Microphone or mic converts air pressure variations (result of our speech) to electrical signal to couple on the PCB for further processing. Usually in mobile phone mic of type’s condenser, dynamic, carbon or ribbon is used. Speaker It converts electrical signal to audible signal (pressure vibrations) for human being to hear. This is often coupled with audio amplifier to get required amplification of audio signal. It also tied with volume control circuit to change (increase or decrease) the amplitude of the audio signal. Camera Now-a-days with almost all the mobile phone camera feature is available for one to click pictures at various occasions. It is the major specifications in increasing cost of mobile phone. There are various mega pixel cameras for mobile phones are available such as 12 mega pixel, 14 mega pixel and even 41 mega pixel available in smart phones. This has become evident because of advancement in sensor technology. If one wants to buy low cost mobile phone; they usually go for non camera mobile phone. Display There are various display devices used in mobile phone such as LCD(liquid crystal display), TFT(Thin-film transistor) screen, LED(organic light emitting diode),TFD(thin film diode), touch screen of capacitive and resistive type etc.
19
Keypad
Earlier days keypad was simple matrix type keypad which contains numeric digits( 0 to 9), alphabets( a to z),special characters and specific function keys. These has been designed for various applications such as accepting call, rejecting call, cursor movement (left, right, top, down) dialing number, typing name/sms/mms and so on. Now-a-days keypad has been removed from the phone design and it has become part of mobile phone software. It pops on the display screen itself which can be operated by user using touch of a finger tip.
2.8.
GSM RF Planning:
Introduction There are various GSM frequency bands as mentioned below. For our discussion of GSM RF (Radio frequency) planning we will consider GSM 900's P-GSM frequency band.
GSM Frequency bands versus ARFCN GSM Frequency Band
GSM Frequency range
ARFCN(Channel Number)
GSM450 Band
450 to 458MHz (Uplink), 460 MHz to 468 MHz 259 to 293 (Downlink)
GSM 480 band
478 to 486 MHz(Uplink), 488 MHz to 496 MHz(Downlink)
GSM850
824 to 849MHz(Uplink) 869 MHz to 894 MHz 128 to 251 (Downlink)
GSM900(P-GSM)
890 to 915MHz(Uplink) and 935 to 960 MHz(Downlink)
1 to 124
GSM900(E-GSM)
880 to 915 MHz(Uplink) and 925MHz to 960 MHz(Downlink)
975 to 1023, 0 to 124
20
306 to 340
GSM900(R-GSM )
876 to 880 MHz(Uplink) and 921 to 925MHz(Downlink)
GSM1800 (called DCS1800)
1710 to 1785 MHz(Uplink) 1805 MHz to 1880 512 to 885 MHz(Downlink)
GSM1900 (called PCS1900)
1850 to 1910MHz(Uplink) and 1930 MHz to 1990 MHz(Downlink)
940 to 974, 0 to 124
512 to 810
As mentioned in the table above there is about 124 channels in P-GSM. 174 ARFCNs in E-GSM and 374 ARFCNs in DCS1800. Let us understand how we can obtain using following formula. F(Uplink)=890+0.2*n, where n varies as mentioned from 1 to 124 and is referred as ARFCN(Absolute Radio Frequency Channel Number). F(Downlink)=F(Uplink)+45MHz 45MHz is the referred as duplex spacing, which is the difference between uplink and downlink frequency channels.
GSM Radio Frequency planning As frequency spectrum is the scarce resource and need to be optimally used in GSM network or any other cellular network. Hence proper radio frequency planning is required to meet the need. First of all the areas are divided into cells, where in cells can employ unidirectional or directional antennas to broadcast the signals to the mobile users. For our discussion we will assume cell divided into three sectors. Each cell
employ one Base station
(e.g. BTS).
If the number of BTSs allocated are N, and each cell is allocated M channels, Hence total ARFCNs(T) allocated in this GSM system can be obtained as follows.
21
T=3*M*N
Frequency reuse can be applied before radio frequency planning to efficiently use the channels (ARFCNs) in deploying the GSM network. ARFCNs (RF Frequencies) are reused in non adjacent cells. GSM Frequency Re-use patterns
Fig-2.8.1: GSM Radio Frequency planning The frequencies used in GSM radio frequency planning are divided among different frequency groups. GSM uses re-use patterns of 4/12 and 3/9 in most of the GSM installations. 4/12 refers to 12 frequency groups and 4 base stations, which means available GSM network frequencies are divided into 12 frequency groups across 4 BS sites. It has been assumed that there are 3 cells interfaced with each BS. Here frequency groups are designated as A1, B1, C1, D1, A2, B2, C2, D2, A3, B3, C3, D3. The 4/12 GSM frequency layout is shown in the figure.
22
C ha pt e r 3 Equipments Details 3.1. Transformer: Most of the electronic circuits used in Circuitstoday.com have different applications of the transformer. Therefore, it is important to know the working principle, construction and types of transformers used in different analog circuits. Transformer constriction For the simple construction of a transformer, you must need two coils having mutual inductance and a laminated steel core. The two coils are insulated from each other and from the steel core. The device will also need some suitable container for the assembled core and windings, a medium with which the core and its windings from its container can be insulated. In order to insulate and to bring out the terminals of the winding from the tank, apt bushings that are made from either porcelain or capacitor type must be used. In all transformers that are used commercially, the core is made out of transformer sheet steel laminations assembled to provide a continuous magnetic path with minimum of air-gap included. The steel should have high permeability and low hysteresis loss. For this to happen, the steel should be made of high silicon content and must also be heat treated. By effectively laminating the core, the eddy-current losses can be reduced. The lamination can be done with the help of a light coat of core plate varnish or lay an oxide layer on the surface. For a frequency of 50 Hertz, the thickness of the lamination varies from 0.35mm to 0.5mm for a frequency of 25 Hertz.
23
Transformer – Working Principle
A transformer can be defined as a static device which helps in the transformation of electric power in one circuit to electric power of the same frequency in another circuit. The voltage can be raised or lowered in a circuit, but with a proportional increase or decrease in the current ratings. The main principle of operation of a transformer is mutual inductance between two circuits which is linked by a common magnetic flux. A basic transformer consists of two coils that are electrically separate and inductive, but are magnetically linked through a path of reluctance. The working principle of the transformer can be understood from the figure below.
Fig-3.1.1: Transformer Construction
As shown above the transformer has primary and secondary windings. The core laminations are joined in the form of strips in between the strips you can see that there are some narrow gaps right through the cross-section of the core. These staggered joints are said to be ‘imbricate’. Both the coils have high mutual inductance. A mutual electro-motive force is induced in the transformer from the alternating flux that is set up in the laminated core, due to the coil that is 24
connected to a source of alternating voltage. Most of the alternating flux developed by this coil is linked with the other coil and thus produces the mutual induced electro-motive force. The so produced electro-motive force can be explained with the help of Faraday’s laws of Electromagnetic Induction as e=M*dI/dt If the second coil circuit is closed, a current flows in it and thus electrical energy is transferred magnetically from the first to the second coil. The alternating current supply is given to the first coil and hence it can be called as the primary winding. The energy is drawn out from the second coil and thus can be called as the secondary winding. In short, a transformer carries the operations shown below: 1. Transfer of electric power from one circuit to another. 2. Transfer of electric power without any change in frequency. 3. Transfer with the principle of electromagnetic induction. 4. The two electrical circuits are linked by mutual induction.
E.M.F Equation of a Transformer
Fig-3.1.2: E.M.F Equation of a Transformer
25
Transformer EMF Equation Let, NA = Number of turns in primary NB = Number of turns in secondary Ømax = Maximum flux in the core in webers = Bmax X A f = Frequency of alternating current input in hertz (HZ) As shown in figure above, the core flux increases from its zero value to maximum value Ømax in one quarter of the cycle , that is in ¼ frequency second. Therefore, average rate of change of flux = Ømax/ ¼ f = 4f ØmaxWb/s Now, rate of change of flux per turn means induced electro motive force in volts. Therefore, average electro-motive force induced/turn = 4f Ømaxvolt If flux Ø varies sinusoidally, then r.m.s value of induced e.m.f is obtained by multiplying the average value with form factor. Form Factor = r.m.s. value/average value = 1.11 Therefore, r.m.s value of e.m.f/turn = 1.11 X 4f Ømax = 4.44f Ømax Now, r.m.s value of induced e.m.f in the whole of primary winding = (induced e.m.f./turn) X Number of primary turns Therefore, EA = 4.44f NAØmax = 4.44fNABmA Similarly, r.m.s value of induced e.m.f in secondary is EB = 4.44f NB Ømax = 4.44fNBBmA In an ideal transformer on no load, VA = EA and VB = EB , where VB is the terminal voltage
26
Voltage Transformation Ratio (K)
From the above equations we get EB/ EA = VB/ VA = NB/NA = K This constant K is known as voltage transformation ratio. (1) If NB>NA , that is K>1 , then transformer is called step-up transformer. (2) If NB