Arduino Projects   |   Raspberry Pi   |   Electronic Circuits   |   AVR   |   PIC   |   8051   |   Electronic Projects

GSM/GPRS Module : All You Need To Know

Written By: 

Nikhil Agnihotri


GSM/GPRS module is used to establish communication between a computer and a GSM-GPRS system. Global System for Mobile communication (GSM) is an architecture used for mobile communication in most of the countries. Global Packet Radio Service (GPRS) is an extension of GSM that enables higher data transmission rate. GSM/GPRS module consists of a GSM/GPRS modem assembled together with power supply circuit and communication interfaces (like RS-232, USB, etc) for computer. The MODEM is the soul of such modules.

Block Diagram showing different parts of typical GSM/GPRS Module

                                                           Fig. 1: Block Diagram Showing Diffrent Parts Of Typical GSM/GPRS Module
Wireless MODEMs
Wireless MODEMs are the MODEM devices that generate, transmit or decode data from a cellular network, for establishing communication between the cellular network and the computer. These are manufactured for specific cellular network (GSM/UMTS/CDMA) or specific cellular data standard (GSM/UMTS/GPRS/EDGE/HSDPA) or technology (GPS/SIM). Wireless MODEMs like other MODEM devices use serial communication to interface with and need Hayes compatible AT commands for communication with the computer (any microprocessor or microcontroller system).

Flow chart showing classification of Wireless Modem based on Network, data or technology

Fig. 2: Flow Chart Showing Classification Of Wireless Modem Based On Network, Data Or Technology

GSM/GPRS MODEM is a class of wireless MODEM devices that are designed for communication of a computer with the GSM and GPRS network. It requires a SIM (Subscriber Identity Module) card just like mobile phones to activate communication with the network. Also they have IMEI (International Mobile Equipment Identity) number similar to mobile phones for their identification. A GSM/GPRS MODEM can perform the following operations:
1.      Receive, send or delete SMS messages in a SIM.
2.      Read, add, search phonebook entries of the SIM.
3.      Make, Receive, or reject a voice call.
The MODEM needs AT commands, for interacting with processor or controller, which are communicated through serial communication. These commands are sent by the controller/processor. The MODEM sends back a result after it receives a command. Different AT commands supported by the MODEM can be sent by the processor/controller/computer to interact with the GSM and GPRS cellular network.
A GSM/GPRS module assembles a GSM/GPRS modem with standard communication interfaces like RS-232 (Serial Port), USB etc., so that it can be easily interfaced with a computer or a microprocessor / microcontroller based system. The power supply circuit is also built in the module that can be activated by using a suitable adaptor.

An Image of Assembled Circuit for GSM/GPRS module with standard communication interfaces like RS-232 or USB

Fig. 3: An Image of Assembled Circuit For GSM/GPRS Module With Standard Communication Interfaces Like RS-232 Or USB

Mobile Station
Mobile Station (Cell phones and SIM)
A mobile phone and Subscriber Identity Module (SIM) together form a mobile station. It is the user equipment that communicates with the mobile network. A mobile phone comprises of Mobile Termination, Terminal Equipment and Terminal Adapter.

Block Diagram showing different functions of cell phone and SIM in Mobile Station

                                           Fig. 4: Block Diagram Showing Diffrent Functions Of Cell Phone And SIM In Mobile Station
Mobile Termination is interfaced with the GSM mobile network and is controlled by a baseband processor. It handles access to SIM, speech encoding and decoding, signaling and other network related tasks. The Terminal Equipment is an application processor that deals with handling operations related to keypad, screen, phone memory and other hardware and software services embedded into the handset. The Terminal Adapter establishes communication between the Terminal Equipment and the Mobile Termination using AT commands. The communication with the network in a GSM/GPRS mobile is carried out by the baseband processor.
Difference between GSM mobile and GSM/GPRS module
A GSM mobile is a complete system in itself with embedded processors that are dedicated to provide an interface between the user and the mobile network. The AT commands are served between the processors of the mobile termination and the terminal equipment. The mobile handset can also be equipped with a USB interface to connect with a computer, but it may or may not support AT commands from the computer or an external processor/controller.
The GSM/GPRS module, on the other hand, always needs a computer or external processor/controller to receive AT commands from. GSM/GPRS module itself does not provide any interface between the user and the network, but the computer to which module is connected is the interface between user and network.
An advantage that GSM/GPRS modules offer is that they support concatenated SMS which may not be supported in some GSM mobile handsets. Also some mobile handsets can’t receive MMS when connected to a computer.
Applications of GSM/GPRS module
The GSM/GPRS module demonstrates the use of AT commands. They can feature all the functionalities of a mobile phone through computer like making and receiving calls, SMS, MMS etc. These are mainly employed for computer based SMS and MMS services.

AT Commands

AT commands are used to control MODEMs. AT is the abbreviation for Attention. These commands come from Hayes commands that were used by the Hayes smart modems. The Hayes commands started with AT to indicate the attention from the MODEM. The dial up and wireless MODEMs (devices that involve machine to machine communication) need AT commands to interact with a computer. These include the Hayes command set as a subset, along with other extended AT commands.
AT commands with a GSM/GPRS MODEM or mobile phone can be used to access following information and services:
1.      Information and configuration pertaining to mobile device or MODEM and SIM card.
2.      SMS services.
3.      MMS services.
4.      Fax services.
5.      Data and Voice link over mobile network.
The Hayes subset commands are called the basic commands and the commands specific to a GSM network are called extended AT commands.
Command, Information response and Result Codes:
The AT commands are sent by the computer to the MODEM/ mobile phone. The MODEM sends back an Information Response i.e. the information requested by or pertaining to the action initiated by the AT command. This is followed by a Result Code. The result code tells about the successful execution of that command.

Data Flow Chart showing execution of AT Commands between PC and Modem

Fig. 5: Data Flow Chart Showing Execution Of AT Commands Between PC And Modem 
There are also unsolicited Result Codes that are returned automatically by the MODEM to notify the occurrence of an event. For example the reception of a SMS will force MODEM to return an unsolicited result code.

AT Commands' Syntax

Case Sensitivity -
The AT commands are generally used in uppercase letters. However some MODEMs and mobile phones allow both uppercase and small case letters.
Single Command -
The AT commands include a prefix AT which indicates the beginning of the command to MODEM; and a carriage return which indicates the end of the command.

Figure showing Command format of Single AT Commands

 Fig. 6: Figure Showing Command Format Of Single AT Commands

However string ‘AT’ itself is not the part of the command. For example in ATD, D is the command name not ATD.
The extended AT commands have a ‘+’ in the command name.
For example:   AT+CGMI<Carriage return>
Command Line -
Multiple AT commands can be sent to MODEM in a single command line. The commands in a line are separated by a semi-colon (;).

Figure showing format for sending multiple commands in Single AT

Fig. 7: Figure Showing Format For Sending Mutiple Commands In Single AT

Figure showing Command format of Single AT Commands
For example:   AT+CGMI; +CBS<Carriage return>
String in Command Line -
Strings in a command line are enclosed in double quotes.
For example:   AT+CGML=”ALL”<Carriage return>

AT Commands continued

Information Response and Result Code –
The Information Response and Result Codes, returned by the MODEM, have a carriage return and line feed in the beginning as well as at the end.

Table shows various results and description retired in AT command

For example:
<Carriage return><Line feed>OK<Carriage return><Line feed>
<Carriage return><Line feed>ERROR<Carriage return><Line feed>
<Carriage return><Line feed>+CBC: 0, 60<Carriage return><Line feed> etc.
Sequence of Execution -
In the command line, the command appearing first is executed first. The execution then follows for second appeared command and so on. The execution of commands in a command line takes place in sequential manner.
If an error occurs in the execution of a command, an error result code is returned by the MODEM and the execution of the command line is terminated irrespective of presence of other commands next in the command line.
Types of commands:
There are four types of AT commands:
1)        Test commands
2)        Read commands
3)        Set commands
4)        Execution commands
For more details, see AT Commands.
Different Result Codes:
Successful Execution of a command
Execution of a command failed
Message service failure, is returned with an error code
Unsolicited Result Codes
Notify receipt of SMS status report of a new message to computer
Notify receipt of SMS status report of a new message and its location in memory to computer
Notify forwarding of a new SMS to computer
Notify receipt of SMS status report of a new message and its location in memory to computer
Fig. 9: Table Showing Various Results And Description Retured In AT Command

Interfacing Modem

Interfacing MODEM/Mobile phone with Windows platform
The Windows (XP and lower versions) comes with an application called HyperTerminal for data communication through serial port of the computer. The interfacing of the GSM/GPRS module with the serial port of the computer involves following steps:
1)             Connect RS-232 port of GSM module with the serial port of the computer. Insert a SIM card in the module.
2)             Open HyperTerminal from Start -> All Programs -> Accessories -> Communications -> HyperTerminal.
3)             Enter a name for the connection and press OK.
4)             Now select the communication port (COM) at which GSM module is connected.

5)             Create a new connection set on HyperTerminal. Set parameters, like baud rate as 9600, handshaking mode as none, parity bit as none, stop bit as 1 and data bit as 8. 




Great Article... ... This article is mostly focused on GSM modem but there are lots of mobile which can be use as  the GSM modem.. so i wanna to know abt that mobile.. so plz update that contents...

updated successfully!!!!

great article!!!

it is a good article and it is having lot of information

and i need to know full AT commands and its functioin  so i hope to update the contents


Sir may i know what is the cost of modem which u shown on screen....and where its available.......

Ur site is superb....marvelous 

Cost must be 900-2000 Indina rupees 

this modem costs around 2500 rupees in pakistan,,,,,,


Nice article it will help many beginners....keep it up.

can you tell me where can i buy it in Pakistan.

 Nice article.......


 Can anybody give me circuit diagram to build GSM MODEM..

no circuit needed for this just consult the Data Sheet of SIM300DZ GSM Module and connect battery antenna and Tx, Rx Done!!



is this modem available somewhere exept qadri electronics in karachi??

Yes you can get this in Matrix Eletronics - Never goto Advance Eletronics they are too expensive 

In our Project we required the internal processing of GSM modem,Through which steps our GSM modem Process the picture(MMS) and send it to the GSM Netwok.


i have a gsm module (wavecom 2403A/2303A WismoQuick), how should i do to make a circuit as a simple and easy to understand for my students? thank you

really nice article................

 well can anybody just tell me if we can also interface a microcontroller with cdma phone

a very ueful article for the beginners

like me

can it be possible in vehicle tracking by using gps and gsm module without pc? 

yes i hav done dat befor , is prettyn simple . all u need is any GPS enabled cell phone. then u hav develop a J2ME application whch willl be deployed on d mobile phone . u need a web application dat wil consume Google Map services , then use a GCF(Generic Connection Framework)- HTTP connection  to talk to d web servlet . den also interface the phone to a Micro-Controller Unit using Serial Connection protocol.

sir if i want to make a project on it  then from where i get the all component?

is there any shop in india for this?

pls reply sir.

i m waiting

this is an excellent site to hobbyist and beginners thank u for good information

at same time would u please entered a project, how to interface a photo diode to microcontroller using gsm modem and send an alert message to a mobile

This modem is available in INDIA @ 3400/-

Its name is Sim300 which is mostly used...!!! 

i like it!
nice for lastyear student to make project!
the modem  code is Sim300

hey bro can u send me code for inerfacing gsm sim300 to ATmega 128 for messaging.

hey bro can u send me code for inerfacing gsm sim300 to ATmega 128 for messaging.

at [email protected]

I need some GSM industry based project i am pursuing very good  related to health system......hope any1 got idea about this

i want to send sms to microcontroller via gsm mobile.

how it works???

plz..... reply

Is pretty simple  , i  hav done SMS based e-votin system , sms remote control , sms based e banking application for diferent firms and individual befor. i do it in 2 ways 1. conect the Sagem phone(My x7 ,My V55,V56) modem to the 8051 serial inteface (green to GND,white to p3.0,blue line to p3.1 then send AT command strings to the d modem. set the d nodem on text mode first(AT+CMGF=1 & CARRIAGE RETURN(ASCII(13)) , AT+CMGL="REC UNREAD" CARRIAGE RETURN(ASCII(13)) ,, any  new message will be red from the d phone modem via d controller UART lines 2. In the second method , i do use J2me on any Nokia phone using Messaging APIs(Message connections framework. but it requires 2 applications runing on 2 phones with the same message port number. then interface 1 one to the MCU using serialconnections  protocol.

hi .can u please elaborate on the fist method.m working on a bord whic contains 708KR microcontroller and one M10 GSM module.these 2 can communicate nw. i want to establish  the communication between the GSM & 2 do it can any one help?


Hello Everyone,



I am currently working on SMS gateway.can any one have code to establish a connection between modem and pc in c sharp.



Vishavdeep Goyal

is pretty simple , i hav done dat befor wit JSF  and also wit dot net . all u need  to do is to implement AT commands using Microsoft Communication control 6.0 in the d dot net framework or u can  develop a DLL that listens  for an incoming message using this strings(AT + CMGS ="Recipientn phone number" + chr(13) ,then the message body +  chr(26) UNREAD".  But u need  to dedicated an internet computer which will hav a GSM phone modem interfaced to it. then develop and publish a web service/ a web server side app using ASP.NET or JSF which will take take parameters like( userID , Message body , recipient phone number). the URL of ur web server app will be made available to user , such that  users can made HTTP request wit the  above parameters. mscomm1.setSettings("9600,N,8,1");





the above code wil initialise the d computer on serial communication.

 for the d Phone Modem to  send SMS , it must be in

TEXT mode using AT+CMGF=1 + chr(13)

mscomm1.setOutput("AT+CMGF=1" + chr(13) ;

// the above wil set d modem on text mode , then on the Request event handler paste

//Querry a database to kno  if the user is authorised  using the userID as criteria


mscom1.setOutput("AT+CMGS=" + "/"+ Recipient phone number+/"" + chr(13)) ;

mscomm1.setOutput(message body + chr(26)) ;




 ... cheers ucontroller , the programing and embeded system guru. talk to me tru Gtalk wit this ID([email protected] add me to ur chat. am always on line 24/7 

what is the function mscomm1.setOutput all about .can u define it for my main programming

i am working for home security system GSM based...,sir, how can i construct it using microcontroller..,


tanx a lot..

helo sir..
im also doing a project about home security using microcontroller
do you have the program for that..??
cn u please e-mail me if u do..
[email protected]

Really helpfull article.


Can I make calls using gsm modems?

I don't have windows xp. I use windows 7 and Linux. How can I use Hyper terminal here??

Please help me asap.

Is pretty simple . solution from ucontroller (the embeded system guru of the continent  add me on Gtalk to kno more tins from me usin d ID below [email protected] or face book ID - Tsokoh Frank)

all u need to do is to use an XP system , they are 2 files to be copied - 1. a setup from ur windows NT folder , from Drive C go to program file -> Windows NT folder copy Hyperterm  and save it in a flash drive , then d second file is dll file from ur system 32 directory,  go to Drive C->Windows->System32 folder den copy Hyperterm.dll and save in a flash drive. den take d flash to ur Windows7 or Vista computer paste the setup in the same windows NT folder , paste the Hyperterm.dll file in the System 32 folder. finaly paste the setup also in ur desktop and double click, u wil see ur Hyperterminal runnig sucessfully.. cheers flex ur Hyperterminal

i read all of the content. but, i want to knw that how we can send the command through the microcontroller the syntax for same...its just in the form of data as we trasmitting serially.............???????or we have to defind some thing??????can u just give me one of example for same...??


This is Sandesh Shanmugam persuing my master's in Biomedical Engineering at Manipal University India .I have included your GSM working diagram  as a reference  for my project thesis.I hereby request you to to grant me permission in including your material as a reference for my project thesis.
Thanking you 
Sandesh Shanmugam

This is one kind of good article... This is mostly used to GSM Technology.. But i want to like that gsm is using to AVR

This is the best article I have read .... Its awesome...


Please let me know the GSM module shown in the Image here.... I am trying to use GSM communcation in my Project.

It's about time soemnoe wrote about this.


I want to to use max232 bt I m unable to do so......

Actually I m interfacing sim300 dz with ma pc via db9 port so plz help me.

thanx in anticipation...

a nice and helpful article..!!!



hello friends i am making projects sms based notice board display.i am using 40x4 lcd display..can anyone help me to provide circuit diagram and code...plz reply me on my email id [email protected].....

awesome explanation ..thank u so much :)



is this given data is sufficient for this project sir

hello sir

i want to receive message using sim300 gsm modem.i have given serial programming using serial

interrupt.i have an problem. i amn't catching the +cmti indication and my gsm modem gives string  athyperterminal  "under voltage warnning".please sir help me as soon as possible.

thanks in adavance 




Nice guidance to develop a complex System

Hello there, I want to design a project that works with GSM and microcontroller using assembly language, for sending message and making calls to my cellphone, please me guys, I'm trying but I'm struggling

Hi i have sparkfun's SM5100B eval board and GSM module. I am having problems with interfacing it with atmel AT89C51. 

Will this module work with Atmel AT89c51?

I am displaying the text on LCD.


1)Rx and Tx ports of module to MAX232 which connect it to the Tx and Rx of 8051

2)LCD module is up and running

Please help



hello , i am making project on sms based notice board ,, please help me with coding ,, its urgent ,, please please .. plz mail to [email protected]

the coding is there on this page itself.. under the 'Code' tab.. plz check again.

Is  it  possible  to  interface  GPS  and  GSM  with  one  microcontroller  of  8051  with  1  UART ?


hello sir,

i have also this doubt. please help me.

u can... but u cannot get any feed back or text alert from gsm. u can get gps location and u can send it through gsm

Article could have been a bit breef for amatuers like me. xD

But still a Neat and good article. yes

Thankyou sir! the information provided was really meaningful for me!


Hi, as I know SIM300 can not used to send MMS (Multimedia Messaging Service), but SIM900 can.


Can you please show how to send MMS using SIM900 and PIC microcontroller? I searched alot of in the internet but unfortunatly I couldn´t find any information about that !!

Sir i have gsm sim 300 modem i have connected it to pc and this modem is detected by pc when i type AT then it displays Ok on hyperterminal but when i am trying to send sms then no sms can able to send from modem please help me.

i want to transmit a code AT+CMGS=1 at once by a to transmit it?


how we can interface a gsm mobile with microcontroller...

i want to send the data of  microcontroller to an gsm device using a gsm device which is interfaced with microcontroller


how  can i  interface gsm mobile with 8051

i want to send data of 8051 to other gsm mobile using an interfaced gsm mobile

can anyone help me??

can anyone suggest any other friendly GSM modem other than the SIM 300, which suppports TCP/IP.

can anyone suggest any other friendly GSM modem other than the SIM 300, which suppports TCP/IP.

can anyone help me with the program for gsm based load contro or automation system!!! or pls help me to read the message from the gsm module via c code !!! i know the atcommands ie- at+cmgr and cmgl! pls help me with the c program! i am using atmega32!!! thanks

can anyone help me with the program for gsm based load contro or automation system!!! or pls help me to read the message from the gsm module via c code !!! i know the atcommands ie- at+cmgr and cmgl! pls help me with the c program! i am using atmega32!!! thanks

Can I use phones like Nokia 3310 instead of the SIM300DZ? I would like to developed SMS based device controlling using one of the available PIC.

how can i get the number inside the pic micro controller pls give any sample coding in working ccs compile formate pls send me sir my mail id: [email protected]


please give me example programs for communicaing the gsm with pic micro controller  


Can anyone tell me the gsm module NAME used for SMS MMS AND CALLS

I am now checking the suppliers of SIM300DZ GSM Module I am seeing the name and description of the module but the picture of what suppliers are showing, by no means look any where close to what is being shown on your site Please advise.

Thank You


Mouse over to zoom in

hi guys, i'm working with module sim 908 interface with pic18f2550 ,  anyone has similar project can share schematic circuit for me , i got confused about circuits


Here is my gmail: [email protected]



Here again


Iam trying to purchase the sim 300from a supplier but the image that they are displaying is entirely different form what is on your site . Iam not seeing the components of the modulejust an outside lable the cost is US $30.00 please advise 

Sir, where I have toput the codes? I mean which program you are using to code this?

Hi everyone, I wanna to build this module, anyone can tell me how?

Hi everyone, I wanna to build this module, anyone can tell me how?

I need to inteface the modem with atmega IC using microc . If  anyone have the coding or coding technique,please share with me.



I would like to get the wiring diagram of the GSM/GPRS module since I need it to be simulated...Thanks

Could u send me the wiring diagram
Plz send me the circuit diagram

i want to know about specification of gsm module

In my gsm message is not sending. What should i do???

Please can any body help me out with Gprs AT commands to send email or to upload the data in website which is created using html. Urgent needed.

how to interfacing 8051 microcontroller to gsm module

can we communicate betweeen two GSM/GPRS module. if anyone know please let me know how it works ?.

hello sir and every body i want to interface gsm with a methane sensor how can i do it . my purpose is that when methane sensor will get methane it will send sms to a mobile phone user .how can i do it?????????thank u every one