SIM900 GSM/GPRS shield adds the GPRS/GSM capability to pcDuino. It uses AT commands to communicate with pcDuino through the application UART port. With the help of SIM900 GPRS/GSM shield, it can achieve some basic functions of a mobile phone, such as SMS and voice communication. This shield supports four frequency bands, so it can be used worldwide. It also break out the 12 GPIOs, 2PWMs, and 1 ADCs of the GSM module to respective headers for easy use.
Step 1: Feature of SIM 900 GSM/GPRS Shield
Based on SIMCom‘s SIM900 Module
Quad-Band 850 / 900/ 1800 / 1900 MHz – would work on GSM networks in all countries across the world.
Control via AT commands – Standard Commands: GSM 07.07 & 07.05 | Enhanced Commands: SIMCOM AT Commands.
Short Message Service – so that you can send small amounts of data over the network (ASCII or raw hexadecimal).
Embedded TCP/UDP stack – allows you to upload data to a web server.
Speaker and Headphone jacks – so that you can send DTMF signals or play recording like an answering machine.
SIM Card holder and GSM Antenna – present onboard.
12 GPIOs, 2 PWMs and an ADC (all 2.8 volt logic) – to augment your Arduino.
Low power consumption – 1.5mA(sleep mode)
Industrial Temperature Range – -40°C to +85 °C
Step 2: Interface
Power select – select the power supply for GPRS shield(external power or 5v of arduino)
Power jack – connected to external 4.8~5VDC power supply
Antenna interface – connected to external antenna
Serial port select – select either software serial port or hareware serial port to be connected to GPRS Shield
Hardware Serial – D0/D1 of Arduino/Seeeduino
Software serial – D7/D8 of Arduino/Seeeduino only
Status LED – tell whether the power of SIM900 is on
Net light – tell the status about SIM900 linking to the net
UART of SIM900 – UART pins breakout of SIM900
Microphone – to answer the phone call
Speaker – to answer the phone call
GPIO,PWM and ADC of SIM900 – GPIO,PWM and ADC pins breakout of SIM900
Power key – power up and down for SIM900
Pins usage on pcDuino
D0 – Unused if you select software serial port to communicate with GPRS Shield
D1 – Unused if you select software serial port to communicate with GPRS Shield
D2 – Unused
D3 – Unused
D4 – Unused
D5 – Unused
D6 – Unused
D7 – Used if you select software serial port to communicate with GPRS Shield
D8 – Used if you select software serial port to communicate with GPRS Shield
D9 – Used for software control the power up or down of the SIM900
D10 – Unused
D11 – Unused
D12 – Unused
D13 – Unused
D14(A0) – Unused
D15(A1) – Unused
D16(A2) – Unused
D17(A3) – Unused
D18(A4) – Unused
D19(A5) – Unused
Note: A4 and A5 are connected to the I2C pins on the SIM900. The SIM900 however cannot be accessed via the I2C .
Step 3: Part List
1 x pcDuino V2
1 x SIM900 GSM/GPRS Shield.
A regular mobile phones and 2 SIM CARDS (one put in the cell phone and the other one in SIM900 GSM/GPRS Shield):
1 x Linker Base shields
2 x L inker Button Module
1 x Linker LED Module
3 x Jumper wire
Step 4: Sample Code
#define key1 2
#define key2 3
#define led 4
//Initialize serial and wait for port to open:
int rate = 19200;
; // wait for serial port to connect. Needed for Leonardo only
printf(“SIM900 SHD test !\n”);
int value1 = digitalRead(key1);
int value2 = digitalRead(key2);
value1 = digitalRead(key1);
Serial.println(“ATD + +861562289XXXX;”);
value2 = digitalRead(key2);
value2 = digitalRead(key2);
Step 5: Result
1.Install SIM900 shield on pcDuino.
2. Press and hold PWRKEY button of SIM900 shield for around 2 seconds, we can observe that red LED ready on, and green LED blinking.
3. If the blinking patten of green LED is ON for 100ms and OFF for 500ms, it means that the SIM card is not registered with the network yet.
4. If the blinking pattern of green LED is on for 100ms and OFF for 1 second, it means the the SIM card is registered with the network, and we are ready to use the service.
Install Linker Base shield on top of the SIM900 GSM/GPRS Shield, and hook up Linker LED module, and Linker button module in the following way:
Linker button module 1 —> GPIO D2 of pcDuino
Linker button module 2 —> GPIO D3 of pcDuino
Linker LED module 3 -> GPIO D4 of pcDuino
Open the Arduino IDE that is included with pcDuino, enter sample code, compile, and run the code:
When the code is running, we can see that Linker LED is blinking, which indicates that the shield is ready for commands. Now we press Linker Button 1 to place call, and the Linker LED turns steady on to indicate that a call has been place.
Press Linker Button 2 to hang up the phone. Linker LED will be off for 2 seconds, and will blink again to signal that the shield is ready for commands again.
If you do want to do voice communication, please prepare a headset.
Original post from Learning center: http://learn.linksprite.com/pcduino/sim900_shd-can-make-your-pcduino-a-phone-device/
Twitter: @pcDuino_No1 https://twitter.com/pcDuino_NO1
Facebook: pcDuino https://www.facebook.com/YannyGuoYunyan
Google: pcDuino https://plus.google.com/u/0/communities/114287966294070087720