Microcontroller › 8051 › how to read the received message/number from microcontroller › how to read sms using gsm
April 1, 2016 at 9:58 am
#13834
nilesh
Participant
Hi,
You need to write some code .I hope you successfully interface UART and modem.When you receive the msg on GSM collect the data in the buffer and at the end of the msg you will get +CMT. check +CMT and set the flag. I am going to write some rough logic.
if((MSSG[3] == '+')&& (MSSG[2] == 'C')&& (MSSG[1] == 'M')&& (MSSG[0] == 'T'))
{
sms_rcv = 1;
}
if(sms_rcv)
{
sms_rcv = 0;
delayMs(1000);
parse_msg(); // here check the buffer in which you received the data.and send it on LCD
del_sms();
}