Use with another shield

The GSM shield communicates with an attached Arduino through the Software Serial library. By default, this communication uses digital pins 2 and 3. On the Uno this works without modification, but to use the Leonardo, Yun, or Mega boards, some slight changes are required.

GSM on Arduino Leonardo and Yun

The GSM library uses digital pin 8 to communicate with the Leonardo or the Yun. Thus, you need to route the signal from pin 2 of the GSM shield to pin 8 of the Arduino, and at the same time prevent this signal from connecting to pin 2 of the Arduino. The following two steps accomplish this:

On the GSM shield, connect a jumper wire between digital pins 2 and 8. This routes the signal from pin 2 of the GSM shield to pin 8 of the Arduino.

To prevent this signal from interfering with or being interfered by pin 2 of the Arduino, bend the male header attached to pin 2 on the GSM shield to the side so it does not connect to the Leonardo or Yun.

NOTE: 
Use an external stabilized power supply to 5V and 2400mA or more.

GSM on Arduino Mega

The GSM library uses digital pin 10 to communicate with the Mega. Thus, you need to route the signal from pin 2 of the GSM shield to pin 10 of the Arduino, and at the same time prevent this signal from connecting to pin 2 of the Arduino. The following two steps accomplish this:

On the GSM shield, connect a jumper wire between digital pins 2 and 10. This routes the signal from pin 2 of the GSM shield to pin 10 of the Arduino.

To prevent this signal from interfering with or being interfered by pin 2 of the Arduino, bend the male header attached to pin 2 on the GSM shield to the side so it does not connect to the Mega.

To Modify the communication pin

If you use the GSM Shield with an other Shield that uses the same communication pin, then you must change this pin following the steps suggested from this guide. 
This guide is useful for Example if you use the Arduino Mega with GSM Shield and the Ethernet Shied because both the shields use the pin 10 to communicate with the board. 
- Select the GSM3IO.h library (\arduino-1.7.7\libraries\GSM\src\GSM3IO.h). 
- Open it with "Notepad" or "Notepad++". 
- Modify the row correspondent of your board, in this guide we are using an Arduino Mega 2560, then we will modify the 20 row so: changing RXPIN 10 with RXPIN 11, as shown down:

 
 
#elif defined(__AVR_ATmega2560__) || defined(__AVR_ATmega1280__)
#define __TXPIN__ 3
#define __RXPIN__ 11 //Before it was rx pin 10
#define __RXINT__ 4
 
 

Note: 
Verify the pins usable on your board. 
- Save the changes. 
Now you can use your shields and you can upload your sketches but remember you that you must to connect a jumper wire between digital pins 2 and the pin just changed (in the example pin 11) and bend the male header attached to pin 2 on the GSM shield to the side so it does not connect to your board, as shown in the picture. 
GSM Shield