GSM/GPRS Module
M35
AT Commands Manual
M35
_AT_Commands_Manual Confidential / Released
91
/
186
OK
8.8. AT+CMGS Send SMS Message
Parameter
AT+CMGS Send SMS Message
Test Command
AT+CMGS=?
Response
OK
Write Command
1) If text mode (
+CMGF=1
):
AT+CMGS=<da>[,<toda>]
<CR>
text is entered
<ctrl-Z/ESC>
ESC quits without sending
2) If PDU mode (
+CMGF=0
):
AT+CMGS=<length>
<CR>
PDU is given
<ctrl-Z/ESC>
Response
TA sends message from a TE to the network (SMS-SUBMIT).
Message reference value
<mr>
is returned to the TE on
successful message delivery. Optionally (when
+CSMS
<service>
value is 1 and network supports)
<scts>
is
returned. Values can be used to identify message upon
unsolicited delivery status report result code.
1) If text mode (
+CMGF=1
) and sent successfully:
+CMGS:
<mr>
OK
2) If PDU mode (
+CMGF=0
) and sent successfully:
+CMGS:
<mr>
OK
3)If error is related to ME functionality:
+CMS ERROR: <err>
Reference
GSM 07.05
<da>
GSM 03.40 TP-Destination-Address Address-Value field in string format; BCD numbers (or
GSM default alphabet characters) are converted to characters of the currently selected TE
character set (specified by
+CSCS
in TS 07.07); type of address given by
<toda>
<toda>
GSM 04.11 TP-Destination-Address Type-of-Address octet in integer format (when first
character of
<da>
is + (IRA 43) default value is 145, otherwise default value is 129)
<length>
Integer type value indicating in the text mode (
+CMGF=1
) the length of the message body
<data>
(or
<cdata>
) in characters; or in PDU mode (
+CMGF=0
), the length of the actual
TP data unit in octets (i.e. the RP layer SMSC address octets are not counted in the length)
<mr>
GSM 03.40 TP-Message-Reference in integer format