beautypg.com

Read message +cmgr – Multi-Tech Systems CDMA Wireless Modem User Manual

Page 59

background image

Chapter 8 – Short Messages Commands

Multi-Tech Systems, Inc. CDMA Wireless AT Commands - PN S000294C

59

Syntax:

Command syntax: AT+CNMI=,,,,

Command

Possible Responses

AT+CNMI=2,1,0,0,0
Note: =1

OK

AT+CMTI : “MT”,1
Note: message received

AT+CNMI=2,2,0,0,0
Note: =2

OK

+CMT : “8585551212”,”98/10/01,12 :30
00”,129,1,2,0,5
Hello
Note: message received

AT+CNMI=2,0,0,1,0
Note: =1

OK

AT+CMGS=”8585551212”
Message to send
Note: Send a message in text mode

+CMGS : 7
OK
Note: Successful transmission

+CDS : 2, 116, ”8585551212”, 129, “98/10/01,12 :30
:07”, “98/10/01 12 :30 :08”, 32768
Note: message was correctly delivered

Read Message +CMGR

Description: This command allows the application to read stored messages. The messages are read

from the memory selected by +CPMS command. A message read with status “REC
UNREAD” will be updated in memory with the status “REC READ”.
Note: The parameter for SMS Status Reports is always “READ”.

Values:

Status of message in memory. Possible values are as follows:

Text Mode Possible Values

Status of Messages in Memory

“UREAD”

received unread messages

“READ”

received read messages

“USENT”

stored unsent messages

“SENT”

stored sent messages

“ALL”

all messages

Note: For SMS Status Reports, only “ALL” and “READ” values of the parameter will
list messages ; other values will only return OK.

:

Origination/destination address value in string format.

:

Message

Reference

:

Service Center Time Stamp in string format : “yy/MM/dd,hh :mm :ss±zz”
(Year/Month/Day,Hour:Min:Seconds±TimeZone)

:

Discharge Time in string format: “yy/MM/dd,hh :mm :ss±zz” (Year [00-99],
Month [01-12], Day [01-31], Hour, Minute, Second and Time Zone [quarters
of an hour] )

:

Status of a SMS-STATUS-REPORT (See Chapter 20)

:

Language

:

Encoding

:

Message priority:

0 – Normal
1 – Interactive
2 – Urgent
3 – Emergency

:

Call Back Number

:

Length of the text message (in bytes).

:

Message

text