Hello all,
I am trying to send sms from SIM900 not GSM sheild, but SIM900 send AT Commands too in the text message.
I have receive following text in message:
AT+CMGF=1
AT + CMGS = "+917045610408"
Hello World
please help me out
I have used following programe
#include <SoftwareSerial.h>
SoftwareSerial SIM900(9, 10);
void setup()
{
SIM900.begin(2400);
delay(2000); // give time to log on to network.
SIM900.println("AT+CMGF=1\r");
delay(100);
SIM900.println("AT + CMGS = "" + destinationNumber +""");
delay(100);
SIM900.println(outMessage);
delay(100);
SIM900.println((char)26);//ctrl+z
delay(100);
}
void sendSMS()
{
SIM900.println("AT+CMGF=1\r");
delay(100);
SIM900.println("AT + CMGS = "" +917045610408""");
delay(100);
SIM900.println("Hello World");
delay(100);
SIM900.println((char)26);//ctrl+z
delay(100);
}
void loop()
{
sendSMS();
do
while(1);
}