LK Capi
LK Capi

Reputation: 13

How to retrieve the parts of the same long SMS received from the AT+CMGL command

I have an application interfaced with a GSM Modem where I receive many SMS and display them in a user interface using AT+CMGL command in text mode. When I have short messages, everything is fine. I can retrieve all messages.

AT+CMGL="ALL"

+CMGL: 0,"REC UNREAD","+111111","","23/01/03,16:57:38+04"
This is message 1
+CMGL: 2,"REC UNREAD","+111111","","23/01/03,16:58:03+04"
This is message 2
+CMGL: 1,"REC UNREAD","+111111","","23/01/03,16:58:04+04"
This is message 3

OK

When I have long messages divided in many parts, because an SMS has a limited number of characters, I see them like many short messages.

AT+CMGL="ALL"

+CMGL: 0,"REC UNREAD","+111111","","23/01/03,18:16:20+04"
This is message 1 : message 1 message 1 message 1 message 1 message 1 message 1 message 1 message 1
+CMGL: 1,"REC UNREAD","+111111","","23/01/03,18:16:21+04"
This is second part of message 1
+CMGL: 2,"REC UNREAD","+111111","","23/01/03,18:19:04+04"
This is message 2

OK

Is there an indication (a parameter in AT+CMGL command) that show me all parts of the same message. How can I retrieve all parts of the same Message so I can regroup them and display it in my user interface.

Thank You in advance for your time and your help :)

Best regards!

Upvotes: 1

Views: 306

Answers (1)

hlovdal
hlovdal

Reputation: 28180

The AT+CMGL command has two modes, text mode and PDU mode. The technical name for splitting up long messages into several "normal" length sms messages is multi-part. AT+CMGL only supports multi-part in PDU mode.

For more details see the 3GPP 27.005 specification.

Upvotes: 1

Related Questions