[General] problem reciving SMS after sending SMS using sim900

Status
Not open for further replies.

alzomor

Advanced Member level 2
Joined
Jun 9, 2005
Messages
674
Helped
39
Reputation
78
Reaction score
8
Trophy points
1,298
Location
Germany
www.i-g.org
Activity points
6,406
Dear Sir,

I am using Sim900 for sending and receiving SMS for new M2M home automation project

Here’s my settings

For initialization
AT\r\n
ATE0\r\n
AT+CMGF=1\r\n
AT+CNMI=2,1,0,0,0\r\n


And for receiving SMS I wait for new message indication conataining “+CMTI” and when receiving this I extract the messahe index from the “+CNMI”message and do the following to read the message
"AT+CMGR=index,0\r\n"

Then delete the message using
"AT+CMGD=index,0\r"

And for sending a message is use
"AT+CMGS= \" SIMCardNumber \" \r\n
And then wait for receiving “>” and send message and "\x1a"

I can receive several messages as I didn’t send any but after sending a message I didn’t get the “+CMTI” new message index from the module.
In order to receive more messages after sending a message I restart the module and do the initialization again.

is there any suggestions to overcome this problem

Regards
Hossam Alzomor
 

Hai,
Are you getting +CMGS response after sending message and are you able to send more than one message?

I think you have to send 0x1a, not "0x1a" to end the message.

Also, if you use AT+CNMI=2,2,0,0,0, Sim 900 will send the message directly to the device instantly on reception.

Hope this helps,
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…