Hi guys. I have this SHIELD but i am not able to send sms.
I have connected:
--------------------------------------+
External power: 4.5V 1A
GSMRX to PIN 19 of arduino
GSMTX to PIN 18 of arduino
--------------------------------------+
I'm using a arduino mega 2560
Arduino Mega:
--------------------------------------+
tried with; USB power and / or external power 12V
--------------------------------------+
I have insert a valid sim in the shield. There is the sufficent credit.
I have tried different libraries, with edit gsm.h and hwserial.h uncommented #define MEGA
I use this sketch for sending a sms:
When i try to call the sim insert into sim900, it ring...
#include "SIM900.h"
#include <SoftwareSerial.h>
//If not used, is better to exclude the HTTP library,
//for RAM saving.
//If your sketch reboots itself proprably you have finished,
//your memory available.
//#include "inetGSM.h"
//If you want to use the Arduino functions to manage SMS, uncomment the lines below.
#include "sms.h"
SMSGSM sms;
//To change pins for Software Serial, use the two lines in GSM.cpp.
//GSM Shield for Arduino
//www.open-electronics.org
//this code is based on the example of Arduino Labs.
//Simple sketch to send and receive SMS.
int numdata;
boolean started=false;
char smsbuffer[160];
char n[20];
void setup()
{
//Serial connection.
Serial.begin(9600);
Serial.println("GSM Shield testing.");
//Start configuration of shield with baudrate.
//For http uses is raccomanded to use 4800 or slower.
if (gsm.begin(2400)){
Serial.println("\nstatus=READY");
started=true;
}
else Serial.println("\nstatus=IDLE");
if(started){
//Enable this two lines if you want to send an SMS.
// if (sms.SendSMS("MY NUMBER HERE", "Arduino SMS"))
// Serial.println("\nSMS sent OK");
}
};
void loop()
{
if(started){
//Read if there are messages on SIM card and print them.
if(gsm.readSMS(smsbuffer, 160, n, 20))
{
Serial.println("letto");
Serial.println(n);
Serial.println(smsbuffer);
}
delay(1000);
}
}
but i have this output:
GSM Shield testing.
ATT: OK
RIC: AT
ATT: OK
RIC: AT
ATT: OK
RIC: AT
ATT: OK
RIC: AT
ATT: OK
RIC: AT
DB:ELSE
ATT: OK
RIC: AT
ATT: OK
RIC: AT
ATT: OK
RIC: AT
ATT: OK
RIC: AT
ATT: OK
RIC: AT
DB:ELSE
ATT: OK
RIC: AT
ATT: OK
RIC: AT
....
.....
ERROR: SIM900 doesn't answer. Check power and serial pins in GSM.cpp
status=IDLE
*** I have read HERE, at the end of page "12V", but i have powered with 4.5v using jack on the shield and a external power.
but i have powered with 4.5v using jack on the shield and a external power.
If you are supplying power using the round barrel connector on the Arduino, you need to supply at least 7 volts. No way a voltage regulator can produce 5V output from 4.5V input.
I have tried different libraries, with edit gsm.h and hwserial.h uncommented #define MEGA
Show the changes you made, and provide links to the libraries you are using.
Arduino is powered using VIN PIN 12V and usb connected for debug (using serial monitor)
GSM GPS shield is connected with a round barrel connector 4.5v 1A.
Had a similar issue. This is clearly comms issue between your mega and the GSM module.
Try this bit in the GSM.cpp file at the top. Mod your PINs on the mega as well. PIN 10-TX 11-RX
mazahyr:
Had a similar issue. This is clearly comms issue between your mega and the GSM module.
Try this bit in the GSM.cpp file at the top. Mod your PINs on the mega as well. PIN 10-TX 11-RX
I solved temporarily using this TUTORIAL.
Im studying for make a sketch or a library.
None GSM Shields library's is not caompatible with my shield GSM/GPS.