Microcontroller › 8051 › how to read the received message/number from microcontroller
- This topic has 5 replies, 5 voices, and was last updated 9 years, 8 months ago by
Anonymous.
-
AuthorPosts
-
March 24, 2012 at 8:08 am #1549
Chandan
ParticipantDear Sir,
We, a group of four are involved in a GSM-microcontroller interfaced project in which we are trying to receive acknowledgement from the specific number. ie,
I command the GSM to dial a particular number through 89c51 and after some time I need an acknowledgement from the same number either via call or SMS. I need the phone number for valid verification. In this regard can you please help us how to extract the number through AT commands.
April 21, 2012 at 6:27 pm #7531AJISH ALFRED
ParticipantThe GSM modem can be configured like the following to response immediate when a SMS is received, the SMS’s details are immediately sent serially
AT+CMGF=1 To format SMS as a TEXT message AT+CNMI=1,2,0,0,0 Set how the modem will response when a SMS is received When a new SMS is received by the GSM modem serially send the following data
+CMT : “+91xxxxxxxxxx” , , “04/08/30,23:20:00+40”
This the text SMS message sent to the modemIf you take a close look, it can be found that the 8th character is the starting of the mobile number after a character ‘+’ has been received for the first time.
So just wait till the ‘+’ is received for the first time, then count the next 7 characters received, start storing from the 8 th charater onwards into an array till the 20 th character and you have the mobile number in that array, like +91xxxxxxxxxx
March 26, 2016 at 2:17 am #13826raju
Participantsir,
how to read sms using gsm & 8051 & display on 16×2 lcd.
April 1, 2016 at 9:58 am #13834nilesh
ParticipantHi,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 LCDdel_sms();}August 16, 2016 at 6:13 am #14110Anonymous
GuestSorry… did not get your point….
can you please explain this bit clearly…
August 16, 2016 at 2:04 pm #14113Anonymous
GuestEnable the uart interrupt.once msg recived you will get symbol < .collect the msg in uart receive buffer.
-
AuthorPosts
- You must be logged in to reply to this topic.