Technical data
WMO2 G900 / G1800 / G1900
WCOM/GSM/WMO2/WMO2ATDOC Friday 21 May 1999
WAVECOM confidential © 53
Examples:
Application to GSM AT+CNMI=0,1,0,0,0 <mt>=1
GSM to application OK
GSM to application +CMTI: "SM", 1 Message received
Application to GSM AT+CNMI=0,2,0,0,0 <mt>=2
GSM to application OK
GSM to application +CMT:"123456","98/10/01,12:30:00+00", 129, 4,
32, 240, "15379", 129,5<CR><LF>
Received Message
Message received
Application to GSM AT+CNMI=0,0,0,1,0 <ds>=1
GSM to application OK
Application to GSM AT+CMGS="+33146290800"<CR>
Message to send <ctrl-Z>
Send a message in text
mode
GSM to application +CMGS: 7
OK
Successful transmission
GSM to application +CDS: 2, 116, "+33146290800",145,
"98/10/01,12:30:07+04",
"98/10/01 12:30:08+04", 0
Message was delivered
correctly
4.6.9 Read message +CMGR
This command allows the application to read stored messages.
Command syntax: AT+CMGR=<index>
Response syntax for text mode:
+CMGR:<stat>,<oa>,[<alpha>,] <scts> [,<tooa>,<fo>,
<pid>,<dcs>,<sca>,<tosca>,<length>] <CR><LF> <data>
(for SMS-DELIVER only)
+CMGR:<stat>,<da>,[<alpha>,] [,<toda>,<fo>,<pid>,<dcs>, [<vp>], <sca>,
<tosca>,<length>]<CR><LF> <data>
(for SMS-SUBMIT only)
Response syntax for PDU mode:
+CMGR: <stat>, [<alpha>] ,<length> <CR><LF> <pdu>
A message read with status "REC UNREAD" will be updated in memory
with the status "REC READ" because it has been read.
Example:
GSM to application +CMTI: "SM",1 New message received
Application to GSM AT+CMGR=1 read the message
GSM to application +CMGR: "REC UNREAD",
"0146290800","98/10/01,18:22:11+00" ,
<CR><LF>
ABCdefGHI
OK
Application to GSM AT+CMGR=1 read again the message
GSM to application +CMGR: "REC READ",
"0146290800","98/10/01,18:22:11+00",
<CR><LF>
ABCdefGHI
OK
message is read now,
Application to GSM AT+CMGR=2 Read a bad index
GSM to application +CMS ERROR: 321 error: invalid index
Application to GSM AT+CMGF=0 ;+CMGR=1 in PDU mode
GSM to application +CMGR: 2,,<length> <CR><LF> <pdu>
OK
Message is stored but unsent,
no <alpha> field