Here's my code for sending the text message. I got the code sample from the wiki:
Code: Select all
void SEND_SENSOR_READ(String SnsrVal) {
CellSerial.print("AT+CMGF=1\r"); //Send an SMS in text mode
delay(100);
CellSerial.println("AT + CMGS = \"+1nnnnnnnnnn\""); // phone number to send to
delay(100);
CellSerial.println(SnsrVal); // Sensor value to send
delay(100);
CellSerial.println((char)26); //the ASCII code of the ctrl+z is 26
delay(100);
CellSerial.println();
}
Thanks!
Tom G.