AT Commands Phone Terminal Terminated
101
AT+CMGW
Write Message To Memory
<toda>:
GSM 04.11 TP-Address Type-Of-Address octet; in integer format.
<toda>
Description
129
ISDN / telephony numbering plan, national/international
unknown
Default setting if ‘+’ is not in <da>
145
ISDN / telephony numbering plan, international number
Default setting if ‘+’ is in <da>
161
ISDN / telephony numbering plan, national number
128-255
Valid values, see GSM 04.08 section 10.5.4.7
<mr>:
Integer; GSM 03.40 TP-Message-Reference.
Description:
Stores a message to message storage <mem2> (see
). The memory location
<index> of the stored message is returned. By default, message status will be set to
‘stored unsent’, but parameter <stat> also allows other status values. If writing fails,
is returned.
Execution command:
AT+CMGW=
<length>[,<stat>]
<pdu><‘ctrl-z/ESC’>
Execution command
response:
+CMGW: <index>
Test command:
AT+CMGW=?
Shows if the command is supported.
Parameters:
<length>:
Integer; with
=’0’, this value indicates the length of the actual TP data
unit (in octet units).
<stat>:
<stat>
Description
0
Received unread (new) message
Default setting
1
Received read message
2
Stored unread message (only applicable to SMs)
3
Stored sent message (only applicable to SMs)
<pdu>:
In case of SMS
: GSM 04.11 SC address followed by GSM 03.40 TPDU in
hexadecimal format. ME/TA converts each octet of TP data unit into two
IRA-character long hexadecimal numbers.
In case of CBS
: GSM TPDU in hexadecimal format.
<index>:
Integer; value in the range of location numbers supported by the associated memory.