Does your unit crash or restart on receiving the SMS? If so, the network may not get the confirmation that the message was received; therefore, it assumes that the message was not received - and re-sends it.
Please refer to the traces below. I am querying one time from my base station and till i get response i am not sending any new SMS.
[b]First SMS [/b]
Trace IP 1 Inside smsDataHandler
Trace IP 2 New Message Received
Trace IP 2 +919972498121
Trace IP 2 09/07/28,12:39:08+22
Trace IP 2 #00Q0!
Trace IP 2 Memory allocated
Trace IP 1 After copying to Structure
Trace IP 2 +919972498121
Trace IP 2 09/07/28,12:39:08+22
Trace IP 2 #00Q0!
[b]second SMS[/b]
Trace IP 1 Inside smsDataHandler
Trace IP 2 New Message Received
Trace IP 2 +919972498121
Trace IP 2 09/07/28,12:39:08+22
Trace IP 2 #00Q0!
Trace IP 2 Memory allocated
Trace IP 1 After copying to Structure
Trace IP 2 +919972498121
Trace IP 2 09/07/28,12:39:08+22
Trace IP 2 #00Q0!
My system never restarts after receiving single or multiple SMS
After receiving SMS i dynamicaly store and process after some.
My smsdatahandler returns FALSE after copying to dynamic link
During processing the dynamic link i am unsubscribing and subscribing the sms
I think you are programming with the typical uC. In Wavecom OS, must of the services work as “events” not as “interruptions”. Using dynamic links, is useful if you generate them on an interruption that may stop temporally critical operations.
In many ways, an “event” is very much like and “interrupt” in a “normal” microcontroller system.
The big difference, as I see it, is that you don’t provide the “main” loop in Open-AT (that is part of the Wavecom OS) - you just provide the event handlers…
It’s rather like Windows programming in that respect…
What I mean is:
In events, if incoming SMS events arrive, no more events will be handled until last action on the callback is taken.
In interrupts, if an incoming interrupt arrive, a new one can freeze it before you handle it. That’s why is typical to unsubscribe/disable new interrupts while you handle an interrupt.
I found the problem and was due to bug in my code
Mistakenly i subscribed SMS twice that was given this problem. In one point of my code i missed for checking my smssubcribe flag and i was subscribing again that led to this problem.
IS unsubscribing sms will not give SMSs to application or for a whole module (modem + Openat)?
If the above case is true will it keeps pending and send after sms subscribe is done?
“Cause I was not clear for above doubts from the document i have”
I can’t process single SMS and reply because my application will keeping reading data from externally connected device and after reading cycle finish it checks the SMS or SMSs received and respond to the sms or SMSs received.
During reading the Device my application will only stores the sms and it should not send SMS while reading device.
OK, I see what you mean, but that does depend on the particular processor - some will block further occurrences of the same interrupt until an existing occurrence has been fully serviced…