GSM services
GSM services are a standard collection of applications and features available over the Global System for Mobile Communications (GSM) to mobile phone subscribers all over the world. The GSM standards are defined by the 3GPP collaboration and implemented in hardware and software by equipment manufacturers and mobile phone operators. The common standard makes it possible to use the same phones with different companies' services, or even roam into different countries. GSM is the world's most dominant mobile phone standard.

The design of the service is moderately complex because it must be able to locate a moving phone anywhere in the world, and accommodate the relatively small battery capacity, limited input/output capabilities, and weak radio transmitters on mobile devices.

Accessing a GSM network
In order to gain access to GSM services, a user needs three things:
 A billing relationship with a mobile phone operator. This is usually either where services are paid for in advance of them being consumed (prepaid), or where bills are issued and settled after the service has been consumed (postpaid).
 A mobile phone that is GSM compliant and operates at the same frequency as the operator. Most phone companies sell phones from third-party manufacturers.
 A subscriber identity module (SIM card), which is activated by the operator once the billing relationship is established. After activation the card is then programmed with the subscriber's Mobile Subscriber Integrated Services Digital Network Number (MSISDN) (the telephone number). Personal information such as contact numbers of friends and family can also be stored on the SIM by the subscriber.

After subscribers sign up, information about their identity (telephone number) and what services they are allowed to access are stored in a "SIM record" in the Home Location Register (HLR).

Once the SIM card is loaded into the phone and the phone is powered on, it will search for the nearest mobile phone mast (also called a Base Transceiver Station/BTS) with the strongest signal in the operator's frequency band. If a mast can be successfully contacted, then there is said to be coverage in the area. The phone then identifies itself to the network through the control channel. Once this is successfully completed, the phone is said to be attached to the network.

The key feature of a mobile phone is the ability to receive and make calls in any area where coverage is available. This is generally called roaming from a customer perspective, but also called visiting when describing the underlying technical process. Each geographic area has a database called the Visitor Location Register (VLR), which contains details of all the mobiles currently in that area. Whenever a phone attaches, or visits, a new area, the Visitor Location Register must contact the Home Location Register to obtain the details for that phone. The current cellular location of the phone (i.e., which BTS it is at) is entered into the VLR record and will be used during a process called paging when the GSM network wishes to locate the mobile phone.

Every SIM card contains a secret key, called the Ki, which is used to provide authentication and encryption services. This is useful to prevent theft of service, and also to prevent "over the air" snooping of a user's activity. The network does this by utilising the Authentication Center and is accomplished without transmitting the key directly.

Every GSM phone contains a unique identifier (different from the phone number), called the International Mobile Equipment Identity (IMEI). This can be found by dialing *#06#. When a phone contacts the network, its IMEI may be checked against the Equipment Identity Register to locate stolen phones and facilitate monitoring.

Voice all calls

All Outgoing
Once a mobile phone has successfully attached to a GSM network as described above, calls may be made from the phone to any other phone on the global Public Switched Telephone Network.

The user dials the telephone number, presses the send or talk key, and the mobile phone sends a call setup request message to the mobile phone network via the nearest mobile phone base transceiver station (BTS).

The call setup request message is handled next by the Mobile Switching Center, which checks the subscriber's record held in the Visitor Location Register to see if the outgoing call is allowed. If so, the MSC then routes the call in the same way that a telephone exchange does in a fixed network.

If the subscriber is on a prepaid tariff (sometimes known as Pay As You Go (PAYG) or Pay & Go), then an additional check is made to see if the subscriber has enough credit to proceed. If not, the call is rejected. If the call is allowed to continue, then it is continually monitored and the appropriate amount is decremented from the subscriber's account. When the credit reaches zero, the call is cut off by the network. The systems that monitor and provide the prepaid services are not part of the GSM standard services, but instead an example of intelligent network services that a mobile phone operator may decide to implement in addition to the standard GSM ones.

Incoming calls

Gateway MSC contact
When someone places a call to a mobile phone, they dial the telephone number (also called a MSISDN) associated with the phone user and the call is routed to the mobile phone operator's Gateway Mobile Switching Centre. The Gateway MSC, as the name suggests, acts as the "entrance" from exterior portions of the Public Switched Telephone Network onto the provider's network.

As noted above, the phone is free to roam anywhere in the operator's network or on the networks of roaming partners, including in other countries. So the first job of the Gateway MSC is to determine the current location of the mobile phone in order to connect the call. It does this by consulting the Home Location Register (HLR), which, as described above, knows which Visitor Location Register (VLR) the phone is associated with, if any.

Routing the call
When the HLR receives this query message, it determines whether the call should be routed to another number (called a divert), or if it is to be routed directly to the mobile.

 If the owner of the phone has previously requested that all incoming calls be diverted to another number, known as the Call Forward Unconditional (CFU) Number, then this number is stored in the Home Location Register. If that is the case, then the CFU number is returned to the Gateway MSC for immediate routing to that destination.
 If the mobile phone is not currently associated with a Visited Location Register (because the phone has been turned off) then the Home Location Register returns a number known as the Call Forward Not Reachable (CFNRc) number to the Gateway MSC, and the call is forwarded there. Many operators may set this value automatically to the phone's voice mail number, so that callers may leave a message. The mobile phone may sometimes override the default setting.
 Finally, if the Home Location Register knows that the phone is roaming in a particular VLR area, then it will request a temporary number (called an MSRN) from that VLR (using the IMSI as the reference number). This number is relayed back to the Gateway MSC, and then used to route the call to the MSC where the called phone is roaming.

Locating and ringing the phone 

When the call arrives at the Visited MSC, the MSRN is used to determine which of the phones in this area is being called, that is the MSRN maps back to the IMSI of the original phone number dialled. The MSC pages all the mobile phone masts in the area that the IMSI is registered in order to inform the phone that there is an incoming call for it. If the subscriber answers, a speech path is created through the Visiting MSC and Gateway MSC back to the network of the person making the call, and a normal telephone call follows.

It is also possible that the phone call is not answered. If the subscriber is busy on another call (and call waiting is not being used) the Visited MSC routes the call to a pre-determined Call Forward Busy (CFB) number. Similarly, if the subscriber does not answer the call after a period of time (typically 30 seconds) then the Visited MSC routes the call to a pre-determined Call Forward No Reply (CFNRy) number. Once again, the operator may decide to set this value by default to the voice mail of the mobile so that callers can leave a message.

If the subscriber does not respond to the paging request, either due to being out of coverage, or their battery has gone flat/removed, then the Visited MSC routes the call to a pre-determined Call Forward Not Reachable (CFNRc) number. Once again, the operator may decide to set this value by default to the voice mail of the mobile so that callers can leave a message.

A roaming user may want to avoid these forwarding services in the visited network as roaming charges will apply.

Voice charges

In the United States and Canada, callers pay the cost of connecting to the Gateway MSC of the subscriber's phone company, regardless of the actual location of the phone. As mobile numbers are given standard geographic numbers according to the North American Numbering Plan, callers pay the same to reach fixed phones and mobile phones in a given geographic area. Mobile subscribers pay for the connection time (typically using in-plan or prepaid minutes) for both incoming and outgoing calls. For outgoing calls, any long distance charges are billed as if they originate at the GMSC, even though it is the visiting MSC that completes the connection to the PSTN. Plans that include nationwide long distance and/or nationwide roaming at no additional charge over "local" outgoing calls are popular.

Mobile networks in Europe, Asia (except Hong Kong, Macau (Macao) and Singapore), Australia, and Argentina only charge their subscribers for outgoing calls. Incoming calls are free to the mobile subscriber with the exception of receiving a call while the subscriber is roaming as described below. However, callers typically pay a higher rate when calling mobile phones. Special prefixes are used to designate mobile numbers so that callers are aware they are calling a mobile phone and therefore will be charged a higher rate.

From the caller's point of view, it does not matter where the mobile subscriber is, as the technical process of connecting the call is the same. If a subscriber is roaming on a different company's network, the subscriber, instead of the caller, may pay a surcharge for the connection time. International roaming calls are often quite expensive, and as a result some companies require subscribers to grant explicit permission to receive calls while roaming to certain countries.

Speech encoding
During a GSM call, speech is converted from analogue sound waves to digital data by the phone itself, and transmitted through the mobile phone network by digital means. (Though older parts of the fixed Public Switched Telephone Network may use analog transmission.)

The digital algorithm used to encode speech signals is called a codec. The speech codecs used in GSM are called Half-Rate (HR), Full-Rate (FR), Enhanced Full-Rate (EFR), Adaptive Multirate (AMR) and Wideband AMR also known as HD voice. All codecs except AMR operate with a fixed data rate and error correction level.

Data transmission 

The GSM standard also provides separate facilities for transmitting digital data. This allows a mobile phone to act like any other computer on the Internet, sending and receiving data via the Internet Protocol.

The mobile may also be connected to a desktop computer, laptop, or PDA, for use as a network interface (just like a modem or Ethernet card, but using one of the GSM data protocols described below instead of a PSTN-compatible audio channel or an Ethernet link to transmit data). Some GSM phones can also be controlled by a standardised Hayes AT command set through a serial cable or a wireless link (using IRDA or Bluetooth). The AT commands can control anything from ring tones to data compression algorithms.

In addition to general Internet access, other special services may be provided by the mobile phone operator, such as SMS.

Circuit-switched data protocols
A circuit-switched data connection reserves a certain amount of bandwidth between two points for the life of a connection, just as a traditional phone call allocates an audio channel of a certain quality between two phones for the duration of the call.

Two circuit-switched data protocols are defined in the GSM standard: Circuit Switched Data (CSD) and High-Speed Circuit-Switched Data (HSCSD). These types of connections are typically charged on a per-second basis, regardless of the amount of data sent over the link. This is because a certain amount of bandwidth is dedicated to the connection regardless of whether or not it is needed.

Circuit-switched connections do have the advantage of providing a constant, guaranteed quality of service, which is useful for real-time applications like video conferencing.

General Packet Radio Service (GPRS)

The General Packet Radio Service (GPRS) is a packet-switched data transmission protocol, which was incorporated into the GSM standard in 1997. It is backwards-compatible with systems that use pre-1997 versions of the standard. GPRS does this by sending packets to the local mobile phone mast (BTS) on channels not being used by circuit-switched voice calls or data connections. Multiple GPRS users can share a single unused channel because each of them uses it only for occasional short bursts.

The advantage of packet-switched connections is that bandwidth is only used when there is actually data to transmit. This type of connection is thus generally billed by the kilobyte instead of by the second, and is usually a cheaper alternative for applications that only need to send and receive data sporadically, like instant messaging.

GPRS is usually described as a 2.5G technology; see the main article for more information.

Short Message Service (SMS)

Short Message Service (more commonly known as text messaging) has become the most used data application on mobile phones, with 74% of all mobile phone users worldwide already as active users of SMS, or 2.4 billion people by the end of 2007.

SMS text messages may be sent by mobile phone users to other mobile users or external services that accept SMS. The messages are usually sent from mobile devices via the Short Message Service Centre using the MAP protocol.

The SMSC is a central routing hubs for Short Messages. Many mobile service operators use their SMSCs as gateways to external systems, including the Internet, incoming SMS news feeds, and other mobile operators (often using the de facto SMPP standard for SMS exchange).

The SMS standard is also used outside of the GSM system; see the main article for details.

Supplementary Services 
See also GSM codes for supplementary services.

 Call forwarding.
 Barring of Outgoing Calls.
 Barring of Incoming Calls.
 Advice of Charge (AoC). This GSM service estimates the call cost for display on the user's mobile phone. This helps users by preventing bill shock and reduces the load on the mobile network operator's customer service department. However, in practice, this GSM service is rarely used because the calculation is more complex than the standard allows. Instead, some operators provide subscribers with balance and/or call-cost notifications sent at predetermined times, such as at the beginning or end of every call. These notifications may be read out loud using a speech-synthesis system, or may be transmitted in textual form.
 Call Hold.
 Call Waiting.
 Multiparty service.
 Calling Line Identification Presentation (CLIP)/ Restriction (CLIR).
 Closed User Group (CUG).
 Explicit Call Transfer (ECT). This service allows a user who has two calls to connect these two calls together and release its connections to both other parties.

See also
GSM USSD codes - Unstructured Supplementary Service Data: list of standard GSM codes for network and SIM related functions

References

External links
 GSM Call Flows and Sequence Diagrams Detailed call flow diagrams describing GSM call setup, location update and handover.
 GSM Call Flows and Tutorial Detailed call flow diagrams
GSM standard