Ks0254 keyestudio Sim800c Shield: Difference between revisions
Keyestudio (talk | contribs) |
Keyestudio (talk | contribs) No edit summary |
||
Line 11: | Line 11: | ||
<br> | <br> | ||
==Specifications== | ==Specifications== | ||
* Power Supply <Vin>: 7-12V | * Power Supply <Vin>: 7-12V | ||
Line 94: | Line 93: | ||
<br> | <br> | ||
'''Note:''' As for arduino IDE 1.0 and latest versions, WProgram.h has been renamed Arduino.h, so this program requires arduino IDE 1.0 or latest version to compile successfully. | '''Note:''' As for arduino IDE 1.0 and latest versions, WProgram.h has been renamed Arduino.h, so this program requires arduino IDE 1.0 or latest version to compile successfully. <br> | ||
<span style=color:red> Pay close attention that the code is compatible with Arduino1.5.6 version but not compatible with Arduino1.8.5.</span><br> | |||
In the use of library functions, since the received serial data is too large, so it needs to change the original Arduino serial cache buffer more larger. <br> | In the use of library functions, since the received serial data is too large, so it needs to change the original Arduino serial cache buffer more larger. <br> | ||
'''<span style="color: red;">There are two methods as below:</span> '''<br> | '''<span style="color: red;">There are two methods as below:</span> '''<br> | ||
Line 100: | Line 101: | ||
'''2.'''If your Arduino compiler is below 1.5.5 version, open the '''HardwareSerial.cpp''' file inside the Arduino\hardware\arduino\cores\arduino, modify the '''# define SERIAL_BUFFER_SIZE 64''' as '''# define SERIAL_BUFFER_SIZE 140'''. If it is advanced than 1.5.5 version, then open '''HardwareSerial.h''' file and do the same modification.<br> | '''2.'''If your Arduino compiler is below 1.5.5 version, open the '''HardwareSerial.cpp''' file inside the Arduino\hardware\arduino\cores\arduino, modify the '''# define SERIAL_BUFFER_SIZE 64''' as '''# define SERIAL_BUFFER_SIZE 140'''. If it is advanced than 1.5.5 version, then open '''HardwareSerial.h''' file and do the same modification.<br> | ||
<br> | |||
==Example Use== | ==Example Use== | ||
* 1) Upload the code to UNO R3 board then stack the shield onto UNO R3. | * 1) Upload the code to UNO R3 board then stack the shield onto UNO R3. | ||
Line 109: | Line 111: | ||
<br>[[File:KS0254 SIM800C.jpg|600px|frameless|thumb]]<br> | <br>[[File:KS0254 SIM800C.jpg|600px|frameless|thumb]]<br> | ||
<br> | <br> | ||
==Package Includes== | ==Package Includes== | ||
* Keyestudio SIM800C Shield *1pcs | * Keyestudio SIM800C Shield *1pcs | ||
Line 129: | Line 131: | ||
<br> | <br> | ||
==Get One Now == | ==Get One Now == | ||
*[https://www.keyestudio.com/keyestudio-sim800c-shield-for-arduino-uno-r3-and-mega-2560-gprs-gsm-p0306.html '''Official Website'''] | *[https://www.keyestudio.com/keyestudio-sim800c-shield-for-arduino-uno-r3-and-mega-2560-gprs-gsm-p0306.html '''Official Website'''] |
Revision as of 11:12, 28 April 2019
Introduction
This is a GPRS/GSM expansion board for Arduino.
The shield supports the frequency of EGSM 900MHz /DCS 1800MHz and GSM850 MHz /PCS 1900MHz, integrated with GPRS, DTMF and other functions.
It also supports DTMF. When enable the DTMF function, get the character feedback converted from the pressed button during the call, which can be used for remote control.
It is controlled by the AT command, you can directly start the function through the computer serial port and Arduino motherboard.
The SIM800C GPRS shield has a built-in SIM800H chip from SIMCom, with good stability.
Specifications
- Power Supply <Vin>: 7-12V
- Low power consumption: 0.7mA current in sleep mode
- Low battery consumption (100mA @ 7V-GSM mode)
- GSM 850/900/1800/1900MHz
- GPRS multi-slot class 1 ~ 12
- GPRS mobile station class B
- GSM phase 2/2 + standard
- Class 4 (2W @ 850/900 MHz)
- Class 1 (1W @ 1800 / 1900MHz)
- Controlling via AT command
- USB /Arduino control switch
- Serial baud rate self-adaption
- Support DTMF
- LED indicator for power supply status, network status and operating mode.
Technical Details
- Dimensions: 77mm x 52mm x 27mm
- Weight: 26g
- Antenna length: 180mm
PINOUT
Test Code
Below is an example code.
Click here to download the libraries.
Click here to download the code
Or you can directly copy and paste the code below to Arduino IDE.
#include <sim800cmd.h> //initialize the library instance //fundebug is an application callback function,when someone is calling. Sim800Cmd sim800demo(fundebug); //the setup routine runs once when you press reset: void setup() { //initialize the digital pin as an output. pinMode(13,OUTPUT); //initialize SIM800H,return 1 when initialize success. while((sim800demo.sim800init()) == 0); } //the loop routine runs over and over again forever: void loop() { //Signal strength unsigned char csq = 0; //To obtain the signal strength, return 1 when obtain success. if( sim800demo.callReadCSQ(&csq) ) { //Make Voice Call sim800demo.dialTelephoneNumber("15912345678;");// enter the phone you need to call while(1); } digitalWrite(13,HIGH);//turn the LED on by making the voltage HIGH delay(500); digitalWrite(13,LOW);//turn the LED off by making the voltage LOW delay(500); } //application callback function void fundebug(void) { }
Code to Note:
1. Before compile the code, do remember to add the necessary libraries inside the libraries directory of Arduino IDE.
Download the libraries from below link:
https://drive.google.com/open?id=1u9Jrkv3jfkR9pSCzgjZI4CIA0JESgJH3
2. In the code sim800demo.dialTelephoneNumber("15912345678;"), here you can change the phone number you want to dial.
Note: As for arduino IDE 1.0 and latest versions, WProgram.h has been renamed Arduino.h, so this program requires arduino IDE 1.0 or latest version to compile successfully.
Pay close attention that the code is compatible with Arduino1.5.6 version but not compatible with Arduino1.8.5.
In the use of library functions, since the received serial data is too large, so it needs to change the original Arduino serial cache buffer more larger.
There are two methods as below:
1.unzip the hardware.zip, if your Arduino compiler is below 1.5.5 version, cut the HardwareSerial.cpp file into Arduino\hardware\arduino\cores\arduino, replace the original file. If it is advanced than 1.5.5 version, cut the HardwareSerial.h file into Arduino\hardware\arduino\sam\cores\ arduino,replace the original file.
2.If your Arduino compiler is below 1.5.5 version, open the HardwareSerial.cpp file inside the Arduino\hardware\arduino\cores\arduino, modify the # define SERIAL_BUFFER_SIZE 64 as # define SERIAL_BUFFER_SIZE 140. If it is advanced than 1.5.5 version, then open HardwareSerial.h file and do the same modification.
Example Use
- 1) Upload the code to UNO R3 board then stack the shield onto UNO R3.
- 2) Connect the SIM card (2G network), antenna and headphone with mic head to the shield.
- 3) Connect the jumper cap to the D0 D1, and slide the switch to EXTERN side.
- 4) Power on the UNO R3 board and shield, you should see the PWR led is normally on.
- 5) Long press the To Start button, if STA light is on and NET light flashes, release the button.
- 6) Wait for 1-2 minutes, it will call the number set well. After the phone is connected, you can speak through the headphone.
Package Includes
- Keyestudio SIM800C Shield *1pcs
- Antenna line *1pcs
Resources
Download the PDF:
https://drive.google.com/open?id=19HsvMjCASyCPpUQKPDnxhaCXgJU7_WrV
Download the code:
https://drive.google.com/open?id=1O81GsGh-GNUxSWq5bpeqcuwfHsbpECsN
Download all the libraries:
https://drive.google.com/open?id=1u9Jrkv3jfkR9pSCzgjZI4CIA0JESgJH3