페이지 선택
Generic selectors
Exact matches only
Search in title
Search in content
Search in pages
AT Commands For SMS Control

 

Command Description
AT+CSMS Select message service
AT+CPMS Preferred message storage
AT+CMGF Select bearer service type
AT+CSCA SMS service centre address
AT+CSCB Select cell broadcast message indication
AT+CSMP Set text mode parameters
AT+CSDH Show text mode parameters
AT+CNMA New message acknowledgement to ME/TA
AT+CNMI New message indications to TE
AT+CGSMS Select service for MO SMS messages
AT+CMGL List SMS messages from preferred store
AT+CMGR Read message
AT+CMGS Send message
AT+CMSS Send message from storage
AT+CMGW Write message to memory
AT+CMGD Delete message
AT+CMGMT Change message status
AT+CMVP Set message valid period
AT+CMGRD Read and delete message
AT+CMGSEX Send message
AT+CMSSEX Send multi messages from storage
AT+CMGP Set cdma/evdo text mode parameters

 

 

 

 

AT+CSMS     Select Message Service 

This command is used to select messaging service <service>.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CSMS=?

a) If start HTTP service successfully:

+CSMS: (list of supported <service>s)

OK

 

b) If failed:

ERROR

R) AT+CSMS?

+CSMS: <service>,<mt>,<mo>,<bm>

OK

W) AT+CSMS=<service>

a)

+CSMS: <mt>,<mo>,<bm>

OK

 

b)If failed:

+CMS ERROR: <err>

 

 

<service>

0     SMS at command is compatible with GSM phase 2.

1     SMS at command is compatible with GSM phase 2+.

<mt>

Mobile terminated messages:

0     type not supported.

1     type supported.

<mo>

Mobile originated messages:

0     type not supported.

1     type supported

1     SMS at command is compatible with GSM phase 2+.

<bm>

Broadcast type messages:

0     type not supported.

1     type supported.

 

 

Example

AT+CSMS=0

+CSMS:1,1,1

OK

 

 

 

 

AT+CPMS     Preferred Message Storage 

This command is used to select memory storages <mem1>, <mem2> and <mem3> to be used for reading, writing, etc.

 

T) AT+CPMS=?

a) If start HTTP service successfully:

+CPMS: (list of supported <mem1>s), (list of supported

<mem2>s), (list of supported <mem3>s)

OK

 

b) If failed:

ERROR

R) AT+CPMS?

+CPMS:<mem1>,<used1>,<total1>,<mem2>,<used2>,<total2>

,<mem3>,<used3>,<total3>

OK

W)  AT+CPMS=<mem1>[,<mem2>[,<mem3>]]

a)

+CPMS: <used1>,<total1>,<used2>,<total2>,<used3>,<total3>

OK

 

b)If failed:

+CMS ERROR: <err>

 

 

<mem1>

String type, memory from which messages are read and deleted (commands List Messages

AT+CMGL,

Read Message AT+CMGR and Delete Message AT+CMGD).

“ME”  and  “MT”     FLASH message storage

“SM”     SIM message storage

“SR”     Status report storage (not used in CDMA/EVDO mode)

<mem2>

String type, memory to which writing and sending operations are made (commands Send

Message from Storage AT+CMSS and Write Message to Memory AT+CMGW).

“ME”  and  “MT”     FLASH message storage

“SM”     SIM message storage

<mem3>

String type, memory to which received SMS is preferred to be stored (unless forwarded directly

to TE; refer command New Message Indications AT+CNMI).

“ME”     FLASH message storage

“SM”     SIM message storage GSM phase 2+.

<usedX> Integer type, number of messages currently in <memX>.
<totalX> Integer type, total number of message locations in <memX>.

 

 

Example

AT+CSMS=0

+CSMS:1,1,1

OK

 

 

 

 

AT+CMGF     Select SMS Message Format

This command is used to specify the input and output format of the short messages.

 

T) AT+CMGF=?

a) If start HTTP service successfully:

+CMGF: (list of supported <mode>s)

OK

 

b) If failed:

ERROR

R) AT+CMGF?

+CMGF: <mode>

OK

W) AT+CMGF=<mode>

a)

OK

 

b)If failed:

ERROR

E) AT+CMGF

a)

OK

 

b)If failed:

ERROR

 

 

<mode>

0     PDU mode

1     Text mode

 

 

Example

AT+CMGF=1

OK

 

 

 

AT+CSCA     SMS Service Centre Address

 This command is used to update the SMSC address, through which mobile originated SMS are transmitted.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CSCA=?

a) If start HTTP service successfully:

+CMGF: (list of supported <mode>s)

OK

 

b) If failed:

ERROR

R) AT+CSCA?

+CMGF: <mode>

OK

W) AT+CSCA=<sca>[,<tosca>]

a)

OK

 

b)If failed:

ERROR

 

 

<mode>

0     PDU mode

1     Text mode

 

 

Example

AT+CMGF=1

OK

 

 

 

AT+CSCB     Select Cell Broadcast Message Indication

The test command returns the supported <mode>s as a compound value.

The read command displays the accepted message types.

Depending on the <mode> parameter, the write command adds or deletes the message types accepted.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CSCB=?

a) If start HTTP service successfully:

+CSCB: (list of supported <mode>s)

OK

 

b) If failed:

ERROR

R) AT+CSCB?

+CSCB: <mode>,<mids>,<dcss>

OK

 

b)If failed:

ERROR

W) AT+CSCB=<mode>[,<mids>[,<dcss>]]

a)

OK

 

b)If failed:

ERROR

 

c)If failed:

+CMS ERROR: <err>

 

 

<mode>

0     message types specified in <mids> and <dcss> are accepted.

1     message types specified in <mids> and <dcss> are not accepted.

<mids>

String type; all different possible combinations of CBM message

identifiers.

<dcss>

String type; all different possible combinations of CBM data coding

schemes(default is empty string)

 

 

Example

AT+CSCB=?

+CSCB: (0-1)

OK

 

 

 

AT+CSMP     Set Text Mode Parameters

This command is used to select values for additional parameters needed when SM is sent to the network or placed in storage when text format message mode is selected.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CSMP=? OK
R) AT+CSMP?

+CSMP: <fo>,<vp>,<pid>,<dcs>

OK

W) AT+CSMP=[<fo>[,<vp>[,<pid>[,

<dcs>]]]]

a)

OK

 

b)If failed:

ERROR

 

 

<fo>

Depending on the Command or result code: first octet of GSM

03.40 SMS-DELIVER, SMS-SUBMIT (default 17), SMS-STATUS-REPORT, or SMS-COMMAND (default

2) in integer format. SMS status report is supported under text mode if <fo> is set to 49.

<vp>

Depending on SMS-SUBMIT <fo> setting: GSM 03.40,TP-Validity-Period either in integer format

(default 167), in time-string format, or if is supported, in enhanced format (hexadecimal coded

string with quotes), (<vp> is in range 0…255).

<pid> GSM 03.40 TP-Protocol-Identifier in integer format (default 0).
<dcs>

GSM 03.38 SMS Data Coding Scheme (default 0), or Cell Broadcast Data Coding Scheme in

integer format depending on the command or result code.

 

 

Example

AT+CSMP=17,23,64,244

OK

 

 

 

AT+CSDH     Show Text Mode Parameters

 This command is used to select values for additional parameters needed when SM is sent to the network or placed in storage when text format message mode is selected.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CSDH=?

a)

+CSDH: (list of supported <show>s)

OK

 

b)If failed:

ERROR

R) AT+CSDH?

+CSDH: <show>

OK

W) AT+CSDH=<show>

a)

OK

 

b)If failed:

ERROR

E) AT+CSDH

a)

Set default value (<show>=0):

OK

 

b)If failed:

ERROR

 

 

<fo>

Depending on the Command or result code: first octet of GSM

03.40 SMS-DELIVER, SMS-SUBMIT (default 17),

SMS-STATUS-REPORT, or SMS-COMMAND (default 2) in integer

format. SMS status report is supported under text mode if <fo> is set to 49.

<vp>

Depending on SMS-SUBMIT <fo> setting: GSM 03.40,TP-Validity-Period either in integer format

(default 167), in time-string format, or if is supported, in enhanced format (hexadecimal coded

string with quotes), (<vp> is in range 0…255).

<pid> GSM 03.40 TP-Protocol-Identifier in integer format (default 0).
<dcs>

GSM 03.38 SMS Data Coding Scheme (default 0), or Cell Broadcast Data Coding Scheme in

integer format depending on the command or result code.

 

 

Example

AT+CSDH=1

OK

 

 

 

AT+CNMA     New Message Acknowledgement To ME/TA

This command is used to confirm successful receipt of a new message (SMS-DELIVER or SMS-STATUSREPORT) routed directly to the TE.

If ME does not receive acknowledgement within required time (network timeout), it will send RP-ERROR to the network.

 

T) AT+CNMA=?

if text mode(AT+CMGF=1):

OK

if PDU mode (AT+CMGF=0):

+CNMA: (list of supported <n>s)

OK

W) AT+CNMA=<n>

a)

OK

 

b)If failed:

ERROR

 

c)If failed:

+CMS ERROR: <err>

W) AT+CNMA

a)

OK

 

b)If failed:

ERROR

 

c)If failed:

+CMS ERROR: <err>

 

 

<n>

Parameter required only for PDU mode.

0     Command operates similarly as execution command in text mode.

1     Send positive (RP-ACK) acknowledgement to the network. Accepted only in PDU mode.

2     Send negative (RP-ERROR) acknowledgement to the network. Accepted only in PDU mode.

 

 

Example

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

OK

 

+CMT:1380022xxxx,””,02/04/03,11 :06 :38+32<CR><LF>

Testing

(receive new short message)

AT+CNMA(send ACK to the network)

OK

 

AT+CNMA

+CMS ERROR340

(the second time return error, it needs ACK only once)

 

 

NOTE

The execute / write command shall only be used when AT+CSMS parameter <service> equals 1 (= phase 2+) and appropriate URC has been issued by the module, e.:

<+CMT> for <mt>=2 incoming message classes 0, 1, 3 and none;

<+CMT> for <mt>=3 incoming message classes 0 and 3;

<+CDS> for <ds>=1.

This command not support in CDMA/EVDO mode

 

 

AT+CNMI     New Message Indications To TE

This command is used to select the procedure how receiving of new messages from the network is indicated to the TE when TE is active, e.g. DTR signal is ON.

If TE is inactive (e.g. DTR signal is OFF).

If set <mt> = 3 or <ds> = 1, make sure <mode> = 1, If set <mt>=2,make sure <mode>=1 or 2, otherwise it will return error.

 

T) AT+CNMI=?

+CNMI: (list of supported <mode>s),(list of supported

<mt>s),(list of supported <bm>s),(list of supported

<ds>s),(list of supported <bfr>s)

OK

R) AT+CNMI?

+CNMI: <mode>,<mt>,<bm>,<ds>,<bfr>

OK

W) AT+CNMI=<mode>[,<mt>[,<bm> [,<ds> [,<bfr>]]]]

a)

OK

 

b) If failed:

ERROR

 

c) If failed:

+CMS ERROR: <err>

E) AT+CNMI

Set default value:b)

OK

 

 

<mode>

0     Buffer unsolicited result codes in the TA. If TA result code buffer is full, indications

can be buffered in some other place or the oldest indications may be discarded and replaced

with the new received indications.

1     Discard indication and reject new received message unsolicited result codes when

TA-TE link is reserved (e.g. in on-line data mode). Otherwise forward them directly to the TE.

2     Buffer unsolicited result codes in the TA when TA-TE link

is reserved (e.g. in on-line data mode) and flush them to the TE after reservation.

Otherwise forward them directly to the TE.

<mt>

The rules for storing received SMS depend on its data coding

scheme, preferred  memory storage (AT+CPMS) setting  and  this

value:

0     No SMS-DELIVER indications are routed to the TE.

1     If SMS-DELIVER is stored into ME/TA, indication of the memory location is routed to

the TE using unsolicited result  code:

+CMTI: <mem3>,<index>.

2     SMS-DELIVERs (except class 2 messages and messages in the message

waiting indication group (store message)) are routed directly to the TE using unsolicited result

code:

+CMT:[<alpha>],<length><CR><LF><pdu> (PDU mode enabled); or

+CMT:<oa>,[<alpha>],<scts>[,<tooa>,<fo>,<pid>,<dcs>,<sca>,<t osca>,<length>]

<CR> <LF><data>

(text mode enabled, about parameters in italics, refer command Show Text Mode Parameters

AT+CSDH).

3     Class 3 SMS-DELIVERs are routed directly to TE using

unsolicited result codes defined in <mt>=2. Messages of other data coding schemes result in

indication as defined in <mt>=1.

<bm>

(not used in CDMA/EVDO mode)

The rules for storing received CBMs depend on its data coding scheme, the setting of Select

CBM Types (AT+CSCB) and this value:

0     No CBM indications are routed to the TE.

2     New CBMs are routed directly to the TE using unsolicited result code:

+CBM: <length><CR><LF><pdu> (PDU mode enabled); or

+CBM: <sn>,<mid>,<dcs>,<page>,<pages><CR><LF><data> (text mode enabled)

<ds>

(not used in CDMA/EVDO mode)

0     No SMS-STATUS-REPORTs are routed to the TE.

1     SMS-STATUS-REPORTs are routed to the TE using unsolicited result code:

+CDS: <length><CR><LF><pdu> (PDU mode enabled); or

+CDS:    <fo>,<mr>,[<ra>],[<tora>],<scts>,<dt>,<st> (text mode

enabled)

2     If SMS-STATUS-REPORT is stored into ME/TA, indication

of the memory location is routed to the TE using unsolicited result code:

+CDSI: <mem3>,<index>.

<bfr>

0     TA buffer of unsolicited result codes defined within this command is flushed to the TE

when <mode> 1 to 2 is entered (OK response shall be given before flushing the codes).

1     TA buffer of unsolicited result codes defined within this command is cleared

when <mode> 1 to 2 is entered.

 

 

Example

AT+CNMI=2,1 (unsolicited result codes after received messages.)

OK

 

 

 

AT+CGSMS     Select Service For MO SMS Messages

 The write command is used to specify the service or service preference that the MT will use to send MO SMS messages.

The test command is used for requesting information on which services and service preferences can be set by using the AT+CGSMS write command

The read command returns the currently selected service or service preference.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CGSMS=?

+CGSMS: (list of supported <service>s)

OK

R) AT+CGSMS?

+CGSMS: <service>

OK

W) AT+CGSMS=<service>

a)

OK

 

b) If failed:

ERROR

 

c) If failed:

+CMS ERROR: <err>

 

 

<service>

A numeric parameter which indicates the service or service preference to be used

0     GPRS(value is not really supported and is internally mapped to 2)

1     circuit switched(value is not really supported and is internally mapped to 3)

2     GPRS preferred (use circuit switched if GPRS not available)

3     circuit switched preferred (use GPRS if circuit switched not available)

 

 

Example

AT+CGSMS?

+CGSMS: 3

OK

 

 

 

AT+CMGL     List SMS Messages From Preferred Store

This command is used to return messages with status value <stat> from message storage <mem1> to the TE.

If the status of the message is ‘received unread’, the status in the storage changes to ‘received read’.

 

T) AT+CMGL=?

+CMGL: (list of supported <stat>s)

OK

W) AT+CMGL=<stat>

a)If    text    mode    (AT+CMGF=1),   command    successful   and

SMS-SUBMITs and/or SMS-DELIVERs:

+CMGL:<index>,<stat>,<oa>/<da>,[<alpha>],[<scts>][,<tooa>/

<toda>,<fo>,<pid>,<dcs>,<sca>,<tosca>,<length>]<CR><LF>

<data>[<CR><LF>

+CMGL:<index>,<stat>,<oa>/<da>,[<alpha>],[<scts>][,<tooa>/

<toda>,<fo>,<pid>,<dcs>,<sca>,<tosca>,<length>]<CR><LF>

<data>[…]]

OK

 

b) If text mode (AT+CMGF=1), command successful and SMS- STATUS-REPORTs:

+CMGL:<index>,<stat>,<fo>,<mr>,[<ra>],[<tora>],<scts>,<dt>,

<st>[<CR><LF>

+CMGL:<index>,<stat>,<fo>,<mr>,[<ra>],[<tora>],<scts>,<dt>,

<st>[…]]

OK

 

c) If text mode (AT+CMGF=1), command successful and SMS- COMMANDs:

+CMGL: <index>,<stat>,<fo>,<ct>[<CR><LF>

+CMGL: <index>,<stat>,<fo>,<ct>[…]]

OK

 

d) If text mode (AT+CMGF=1), command successful and CBM storage:

+CMGL:<index>,<stat>,<sn>,<mid>,<page>,<pages>

<CR><LF><data>[<CR><LF>

+CMGL:<index>,<stat>,<sn>,<mid>,<page>,<pages>

<CR><LF><data>[…]]

OK

 

e) If PDU mode (AT+CMGF=0) and Command successful:

+CMGL:<index>,<stat>,[<alpha>],<length><CR><LF><pdu>[< CR><LF>

+CMGL:<index>,<stat>,[<alpha>],<length><CR><LF><pdu>

[]]

OK

 

f)If failed:

+CMS ERROR: <err>

 

 

<stat>

1.Text Mode:

“REC UNREAD”     received unread message (i.e. new message)

“REC READ”     received read message

“STO UNSENT”     stored unsent message

“STO SENT”     stored sent message

“ALL”     all messages

2.PDU Mode:

0     received unread message (i.e. new message)

1     received read message

2     stored unsent message

3     stored sent message

4     all messages

<index>

Integer type; value in the range of location numbers supported by

the associated memory and start with zero.

<oa>

Originating-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <tooa>.

<da>

Destination-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <toda>.

<alpha>

String type alphanumeric representation of <da> or <oa> corresponding to the entry found in

MT phonebook; implementation of this feature is manufacturer specific; used character set

should be the one selected with command Select TE Character Set AT+CSCS.

<scts> TP-Service-Centre-Time-Stamp in time-string format (refer <dt>).
<da>

Destination-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <toda>.

<tooa>

TP-Originating-Address, Type-of-Address octet in integer format.

(default refer <toda>).

<toda>

TP-Destination-Address, Type-of-Address octet in integer format. (when first character of <da> is

+ (IRA 43) default is 145,

otherwise default is 129). The range of value is from 128 to 255.

<length>

Integer type value indicating in the text mode (AT+CMGF=1) the length of the message body

<data> in characters; or in PDU mode (AT+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)

<data>

In the case of SMS: TP-User-Data in text mode responses; format:

1. If <dcs> indicates that GSM 7 bit default alphabet is used and

<fo> indicates that TP-User-Data-Header-Indication is not set:

a     If TE character set other than “HEX”: ME/TA converts GSM alphabet into current TE

character set.

b     If TE character set is “HEX”: ME/TA converts each 7-bit character of GSM 7 bit default

alphabet into two IRA character long hexadecimal numbers. (e.g. character (GSM 7 bit default

alphabet 23) is presented as 17 (IRA 49 and 55))

2. If <dcs> indicates that 8-bit or UCS2 data coding scheme is

used, or <fo> indicates that TP-User-Data-Header-Indication is set: ME/TA converts each 8-bit

octet into two IRA character long hexadecimal numbers.

(e.g. octet with integer value 42 is presented to TE as two characters 2A (IRA 50 and 65))

3. If <dcs> indicates that GSM 7 bit default alphabet is used:

a     If TE character set other than “HEX”: ME/TA converts GSM alphabet into current TE

character set.

b     If TE character set is “HEX”: ME/TA converts each 7-bit character of the GSM 7 bit default

alphabet into two IRA character long hexadecimal numbers.

4. If <dcs> indicates that 8-bit or UCS2 data coding scheme is used: ME/TA converts each 8-bit

octet into two IRA character long hexadecimal numbers.

<fo>

Depending on the command or result code: first octet of GSM

03.40 SMS-DELIVER, SMS-SUBMIT (default 17), SMS-STATUS-REPORT, or SMS-COMMAND (default

2) in integer format. SMS status report is supported under text mode if <fo> is set to 49.

<mr>

Message Reference

GSM 03.40 TP-Message-Reference in integer format.

<ra>

Recipient Address

GSM 03.40 TP-Recipient-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(refer to command AT+CSCS);type of address given by <tora>

<tora>

Type of Recipient Address

GSM 04.11 TP-Recipient-Address Type-of-Address octet in integer format (default refer <toda>)

<dt>

Discharge Time

GSM 03.40 TP-Discharge-Time in time-string format: ”

yy/MM/dd,hh:mm:ss+zz”,where characters indicate year (two last

digits),month,day,hour,minutes,seconds and time zone.

<st>

Status

GSM 03.40 TP-Status in integer format

0…255

<ct>

Command Type

GSM 03.40 TP-Command-Type in integer format

0…255

<sn>

Serial Number

GSM 03.41 CBM Serial Number in integer format

<mid>

Message Identifier

GSM 03.41 CBM Message Identifier in integer format

<page>

Page Parameter

GSM 03.41 CBM Page Parameter bits 4-7 in integer format

<pages>

Page Parameter

GSM 03.41 CBM Page Parameter bits 0-3 in integer format

<pdu>

In the case of SMS: SC address followed by TPDU in hexadecimal format: ME/TA converts each

octet of TP data unit into two IRA character long hexadecimal numbers. (e.g. octet with integer

value 42 is presented to TE as two characters 2A (IRA 50 and 65)).

 

 

Example

AT+CMGL=”ALL”

+CMGL: 1,”STO UNSENT”,”+10011″,,,145,4

Hello World

OK

 

 

 

 

AT+CMGR     Read Message

This command is used to return message with location value <index> from message storage <mem1> to the TE.

 

T) AT+CMGR=? OK

 

 

 

 

 

 

 

 

 

 

W) AT+CMGR=<index>

a) If    text mode (AT+CMGF=1), command successful and SMS- DELIVER:

+CMGR:

<stat>,<oa>,[<alpha>],<scts>[,<tooa>,<fo>,<pid>,<dcs>,

<sca>, <tosca>, <length>]<CR><LF><data>

OK

 

b) If text mode (AT+CMGF=1), command successful and SMS- SUBMIT:

+CMGR:<stat>,<da>,[<alpha>][,<toda>,<fo>,<pid>,<dcs>,[<vp>], <sca>, <tosca>,<length>]

<CR><LF><data>

OK

 

c) If text mode (AT+CMGF=1), command successful and SMS- STATUS-REPORT:

+CMGR: <stat>,<fo>,<mr>,[<ra>],[<tora>],<scts>,<dt>,<st>

OK

 

d) If text mode (AT+CMGF=1), command successful and SMS- COMMAND:

+CMGR:<stat>,<fo>,<ct>[,<pid>,[<mn>],[<da>],[<toda>],<leng

th>]<CR><LF><data>

OK

 

e) If text mode (AT+CMGF=1), command successful and CBM storage:

+CMGR:<stat>,<sn>,<mid>,<dcs>,<page>,<pages><CR><LF>

<data>

OK

 

f) If PDU mode (AT+CMGF=0) and Command successful:

+CMGR:<stat>,[<alpha>],<length><CR><LF><pdu>

OK

 

g) If failed:

+CMS ERROR: <err>

E) AT+CSDH

a)

Set default value (<show>=0):

OK

 

b)If failed:

ERROR

 

 

<stat>

1. Text Mode:

“REC UNREAD”     received unread message (i.e. new message)

“REC READ”     received read message

“STO UNSENT”     stored unsent message

“STO SENT”     stored sent message

“ALL”      all messages

2. PDU Mode:

0     received unread message (i.e. new message)

1     received read message

2     stored unsent message

3     stored sent message

4     all messages

<index>

Integer type; value in the range of location numbers supported by

the associated memory and start with zero.

<oa>

Originating-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <tooa>.

<pid>

Protocol Identifier

GSM 03.40 TP-Protocol-Identifier in integer format

0…255

<alpha>

String type alphanumeric representation of <da> or <oa> corresponding to the entry found in

MT phonebook; implementation of this feature is manufacturer specific; used character set

should be the one selected with command Select TE Character Set AT+CSCS.

<dcs>

Depending on the command or result code: SMS Data Coding Scheme (default 0), or Cell

Broadcast Data Coding Scheme in integer format..

<sca>

RP SC address Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <tosca>.

<tosca>

RP SC address Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <tosca>.

<scts> TP-Service-Centre-Time-Stamp in time-string format (refer <dt>).
<da>

Destination-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <toda>.

<tooa>

TP-Originating-Address, Type-of-Address octet in integer format.

(default refer <toda>).

<toda>

TP-Destination-Address, Type-of-Address octet in integer format. (when first character of <da> is

+ (IRA 43) default is 145,

otherwise default is 129). The range of value is from 128 to 255.

<length>

Integer type value indicating in the text mode (AT+CMGF=1) the length of the message body

<data> in characters; or in PDU mode (AT+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)

<data>

In the case of SMS: TP-User-Data in text mode responses; format:

1. If <dcs> indicates that GSM 7 bit default alphabet is used and

<fo> indicates that TP-User-Data-Header-Indication is not set:

a     If TE character set other than “HEX”: ME/TA converts GSM alphabet into current TE character set.

b     If TE character set is “HEX”: ME/TA converts each 7-bit character of GSM 7 bit default

alphabet into two IRA character long hexadecimal numbers. (e.g. character (GSM 7 bit default

alphabet 23) is presented as 17 (IRA 49 and 55))

2. If <dcs> indicates that 8-bit or UCS2 data coding scheme is

used, or <fo> indicates that TP-User-Data-Header-Indication is set: ME/TA converts each 8-bit

octet into two IRA character long hexadecimal numbers.

(e.g. octet with integer value 42 is presented to TE as two characters 2A (IRA 50 and 65))

3. If <dcs> indicates that GSM 7 bit default alphabet is used:

a     If TE character set other than “HEX”: ME/TA converts GSM alphabet into current TE

character set.

b     If TE character set is “HEX”: ME/TA converts each 7-bit character of the GSM 7 bit default

alphabet into two IRA character long hexadecimal numbers.

4. If <dcs> indicates that 8-bit or UCS2 data coding scheme is used: ME/TA converts each 8-bit

octet into two IRA character long hexadecimal numbers.

<fo>

Depending on the command or result code: first octet of GSM

03.40 SMS-DELIVER, SMS-SUBMIT (default 17), SMS-STATUS-REPORT, or SMS-COMMAND (default

2) in integer format. SMS status report is supported under text mode if <fo> is set to 49.

<vp>

Depending on SMS-SUBMIT <fo> setting: TP-Validity-Period either in integer format (default 167)

or in time-string format (refer <dt>).

<mr>

Message Reference

GSM 03.40 TP-Message-Reference in integer format.

<ra>

Recipient Address

GSM 03.40 TP-Recipient-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(refer to command AT+CSCS);type of address given by <tora>

<tora>

Type of Recipient Address

GSM 04.11 TP-Recipient-Address Type-of-Address octet in integer format (default refer <toda>)

<dt>

Discharge Time

GSM    03.40    TP-Discharge-Time    in    time-string    format: ”

yy/MM/dd,hh:mm:ss+zz”,where characters indicate year (two last

digits),month,day,hour,minutes,seconds and time zone.

<st>

Status

GSM 03.40 TP-Status in integer format

0…255

<ct>

Command Type

GSM 03.40 TP-Command-Type in integer format

0…255

<sn>

Serial Number

GSM 03.41 CBM Serial Number in integer format

<mn>

Message Number

GSM 03.40 TP-Message-Number in integer format

<mid>

Message Identifier

GSM 03.41 CBM Message Identifier in integer format

<page>

Page Parameter

GSM 03.41 CBM Page Parameter bits 4-7 in integer format

<pages>

Page Parameter

GSM 03.41 CBM Page Parameter bits 0-3 in integer format

<pdu>

In the case of SMS: SC address followed by TPDU in hexadecimal format: ME/TA converts each

octet of TP data unit into two IRA character long hexadecimal numbers. (e.g. octet with integer

value 42 is presented to TE as two characters 2A (IRA 50 and 65)).

 

 

Example

AT+CMGR=1

+CMGR: “STO UNSENT”,”+10011″,,145,17,0,0,167,”+8613800100500″,145,11

Hello World

OK

 

 

 

 

AT+CMGS     Send Message

 This command is used to send message from a TE to the network (SMS-SUBMIT).

 

T) AT+CMGS=? OK

W) If text mode (AT+CMGF=1):

AT+CMGS=<da>[,<toda>]<CR>T

ext is entered.

<CTRL-Z/ESC>

If PDU mode(AT+CMGF=0): AT+CMGS=<length><CR> PDU is entered

<CTRL-Z/ESC>

a) If sending successfully:

+CMGS: <mr>[,<time_stamp>]

OK

 

b) If cancel sending:

OK

 

c) If sending fails:

ERROR

 

d) If sending fails:

+CMS ERROR: <err>

 

 

<da>

Destination-Address, Address-Value field in string format; BCD

numbers (or GSM 7 bit default alphabet characters) are converted

to characters of the currently selected TE character set, type of address given by <toda>.

<toda>

TP-Destination-Address, Type-of-Address octet in integer format.

(when first character of <da> is + (IRA 43) default is 145, otherwise default is 129). The range of

value is from 128 to 255.

<length>

integer type value indicating in the text mode (AT+CMGF=1) the length of the message body

<data> > (or <cdata>) in characters; or in PDU mode (AT+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>

Message Reference

GSM 03.40 TP-Message-Reference in integer format.

 

 

Example

AT+CMGS=”13012832788″<CR>(TEXT MODE)

> ABCD<ctrl-Z/ESC>

+CMGS: 46

OK

 

 

NOTE

In text mode, the maximum length of an SMS depends on the used coding scheme: It is 160 characters if the 7 bit GSM coding scheme is used.

 

 

 

 

AT+CMSS     Send Message From Storage

This command is used to send message with location value <index> from preferred message storage

<mem2> to the network (SMS-SUBMIT or SMS-COMMAND).

 

T) AT+CMSS=? OK

W) AT+CMSS=

<index> [,<da>[,<toda>]]

a)

+CMSS: <mr>[,<time_stamp>]

OK

 

b)If failed:

ERROR

 

c)If sending fails:

+CMS ERROR: <err>

E) AT+CSDH

a)

Set default value (<show>=0):

OK

 

b)If failed:

ERROR

 

 

<index>

Integer type; value in the range of location numbers supported by

the associated memory and start with zero.

<da>

Destination-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <toda>.

<mr>

Message Reference

GSM 03.40 TP-Message-Reference in integer format.

<toda>

TP-Destination-Address, Type-of-Address octet in integer format. (when first character of <da> is

+ (IRA 43) default is 145,

otherwise default is 129). The range of value is from 128 to 255.

 

 

Example

AT+CMSS=3

+CMSS: 0

OK

 

AT+CMSS=3,”13012345678″

+CMSS: 55

OK

 

NOTE

In text mode, the maximum length of an SMS depends on the used coding scheme: It is 160 characters if the 7 bit GSM coding scheme is used.

 

 

 

 

AT+CMGW     Write Message To Memory

 This command is used to store message (either SMS-DELIVER or SMS-SUBMIT) to memory storage

<mem2>.

 

T) AT+CMGW=? OK

W) If text mode (AT+CMGF=1):

AT+CMGW=<oa>/<da>[,<tooa>/

<toda>[,<stat>]]<CR>Text       is

entered.

<CTRL-Z/ESC>

If PDU mode(AT+CMGF=0):

AT+CMGW=<length>[,<stat>]<C

R>PDU is entered.

<CTRL-Z/ESC>

a)If write successfully:

+CMGW: <index>

OK

 

b)If cancel write:

OK

 

c)If write fails:

ERROR

 

d)If write fails:

+CMS ERROR: <err>

 

 

<index>

Integer type; value in the range of location numbers supported by

the associated memory and start with zero.

<oa>

Originating-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <tooa>.

<tooa>

TP-Originating-Address, Type-of-Address octet in integer format.

(default refer <toda>).

<da>

Destination-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default alphabet

characters) are converted to characters of the currently selected TE character set, type of

address given by <toda>.

<toda>

TP-Destination-Address, Type-of-Address octet in integer format.

(when first character of <da> is + (IRA 43) default is 145, otherwise default is 129).

The range of value is from 128 to 255.

<length>

Integer type value indicating in the text mode (AT+CMGF=1) the length of the message body <data> > (or

<cdata>) in characters; or in PDU mode (AT+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).

<stat>

1. Text Mode:

“STO UNSENT”     stored unsent message

“STO SENT”     stored sent message

2. PDU Mode:

2     stored unsent message

3     stored sent message

 

 

Example

AT+CMGW=”13012832788″ <CR> (TEXT MODE)

ABCD<ctrl-Z/ESC>

+CMGW:1

OK

 

 

NOTE

In text mode, the maximum length of an SMS depends on the used coding scheme: It is 160 characters if the 7 bit GSM coding scheme is used.

 

 

 

 

AT+CMGD      Delete Message

This command is used to delete message from preferred message storage <mem1> location <index>.

If <delflag> is present and not set to 0 then the ME shall ignore <index> and follow the rules for <delflag> shown below.

 

T) AT+CMGD=?

+CMGD: (list of supported <index>s)[,(list of supported

<delflag>s)]

OK

W) AT+CMGD=<index>[,<delflag>]

a)

OK

 

b)If failed:

ERROR

 

c)If failed:

+CMS ERROR: <err>

 

 

<index>

Integer type; value in the range of location numbers supported by

the associated memory and start with zero.

<delflag>

0     (or omitted) Delete the message specified in <index>.

1     Delete all read messages from preferred message storage,

leaving unread messages and stored mobile originated messages (whether sent or not) untouched.

2     Delete all read messages from preferred message storage and sent mobile originated messages,

leaving unread messages and unsent mobile originated messages untouched.

3     Delete all read messages from preferred message storage, sent and unsent mobile originated

messages leaving unread messages untouched.

4     Delete all messages from preferred message storage including unread messages.

 

 

Example

AT+CMGD=1

OK

 

 

NOTE

If set <delflag>=1, 2, 3 or 4, <index> is omitted, such as AT+CMGD=,1.

 

 

 

 

AT+CMGMT      Change Message Status

This command is used to change the message status. If the status is unread, it will be changed read. Other statuses don’t change.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CMGMT=? OK
W) AT+CMGMT=<index>

a)

OK

 

b)If failed:

ERROR

 

c)If failed:

+CMS ERROR: <err>

 

 

<index>

Integer type; value in the range of location numbers supported by

the associated memory and start with zero.

 

 

Example

AT+CMGMT=1

OK

 

 

 

 

AT+CMVP     Set Message Valid Period

This command is used to set valid period for sending short message. Note: This command not support in CDMA/EVDO mode

 

T) AT+CMVP=?

+CMVP: (list of supported <vp>s)

OK

R) AT+CMVP?

+CMVP:<vp>

OK

W) AT+CMVP=<vp>

a)

OK

 

b) If failed:

ERROR

 

c) If failed:

+CMS ERROR: <err>

 

 

<vp>

Validity period value:

0 to 143     (<vp>+1) x 5 minutes (up to 12 hours)

144 to 167     12 hours + (<vp>-143) x 30 minutes

168 to 196     (<vp>-166) x 1 day

197 to 255     (<vp>-192) x 1 week

 

 

Example

AT+CMVP=167

OK

 

 

 

 

AT+CMGRD     Read And Delete Message

This command is used to read message, and delete the message at the same time. It integrate AT+CMGR and AT+CMGD, but it doesn’t change the message status.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CMGRD=? OK

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

W) AT+CMGRD=<index>

a) If     text     mode(AT+CMGF=1),command     successful     and SMS-DE-LIVER:

+CMGRD:<stat>,<oa>,[<alpha>],<scts>[,<tooa>,<fo>,<pid>,<d cs>, <sca>,<tosca>,<length>]<CR><LF>

<data>

OK

 

b) If text mode(AT+CMGF=1),command successful and SMS-SU- BMIT:

+CMGRD:<stat>,<da>,[<alpha>][,<toda>,<fo>,<pid>,<dcs>,[<v p>], <sca>,<tosca>,<length>]<CR><LF>

<data>

OK

 

c) If text mode(AT+CMGF=1),command successful and SMS-STA- TUS- REPORT:

+CMGRD: <stat>,<fo>,<mr>,[<ra>],[<tora>],<scts>,<dt>,<st>

OK

 

 

d) If     text     mode(AT+CMGF=1),command     successful     and SMS-CO-MMAND:

+CMGRD:<stat>,<fo>,<ct>[,<pid>,[<mn>],[<da>],[<toda>],<len gth><CR><LF><data>]

OK

 

e) If text mode(AT+CMGF=1),command successful and CBM sto- rage:

+CMGRD:<stat>,<sn>,<mid>,<dcs>,<page>,<pages><CR><LF><data>

OK

 

f) If PDU mode(AT+CMGF=0) and command successful:

+CMGRD: <stat>,[<alpha>],<length><CR><LF><pdu>

OK

 

b) If failed:

ERROR

 

c) If failed:

+CMS ERROR: <err>

 

 

Refer to command AT+CMGR.

 

 

Example

AT+CMGRD=6

+CMGRD:”REC READ”,”+8613917787249″,,”06/07/10,12:09:38+32″,145,4,0,0,“+86138002105

00″,145,4

How do you do

OK

 

 

 

 

AT+CMGSEX      Send Message

This command is used to send message from a TE to the network (SMS-SUBMIT).

Note: This command not support in CDMA/EVDO mode

 

T) AT+CMGSEX=? OK

W) If text mode (AT+CMGF=1):

AT+CMGSEX=<da>[,<toda>][,<

mr>,<msg_seg>,<msg_total>]<

CR>Text is entered.

<CTRL-Z/ESC>

a)If sending successfully:

+CMGSEX: <mr>

OK

 

b)If cancel sending:

OK

 

c)If sending fails:

ERROR

 

d)If sending fails:

+CMS ERROR: <err>

 

 

<da>

Destination-Address, Address-Value field in string format; BCD numbers (or GSM 7 bit default

alphabet characters) are converted to characters of the currently selected TE character set, type

of address given by <toda>.

<toda>

TP-Destination-Address, Type-of-Address octet in integer format.

(When first character of <da> is + (IRA 43) default is 145, otherwise default is 129).

The range of value is from 128 to 255.

<mr>

Message Reference

GSM 03.40 TP-Message-Reference in integer format. The maximum length is 255.

<msg_seg> The segment number for long sms
<msg_total>

The total number of the segments for long sms. Its range is from 2 to 255.

 

 

Example

AT+CMGSEX=”13012832788″, 190, 1, 2<CR>(TEXT MODE)> ABCD<ctrl-Z/ESC>

+CMGSEX: 190

OK

 

AT+CMGSEX=”13012832788″, 190, 2, 2<CR>(TEXT MODE)> ABCD<ctrl-Z/ESC>

+CMGSEX: 191

OK

 

 

NOTE

In text mode, the maximum length of an SMS depends on the used coding scheme: For single SMS, it is 160 characters if the 7 bit GSM coding scheme is used;

For multiple long sms, it is 153 characters if the 7 bit GSM coding scheme is used.

 

 

 

 

AT+CMSSEX      Send Multi Messages From Storage

This command is used to send messages with location value <index1>,<index2>,<index3>… from preferred message storage <mem2> to the network (SMS-SUBMIT or SMS-COMMAND).

The max count of index is 13 one time.

Note: This command not support in CDMA/EVDO mode

 

T) AT+CMSSEX=? OK

W) AT+CMSSEX=

<index> [,<index >[,]]

a)

+CMSSEX: <mr>[,<mr>[,]]

OK

 

b) If failed:

ERROR

 

c) If sending fails:

[+CMSSEX: <mr>[,<mr>[,…]]]

+CMS ERROR: <err>

 

 

<index>

Integer type; value in the range of location numbers supported by

the associated memory and start with zero.

<mr>

Message Reference

GSM 03.40 TP-Message-Reference in integer format.

 

 

Example

AT+CMSSEX=0,1

+CMSSEX: 239,240

OK

 

 

NOTE

In text mode, the maximum length of an SMS depends on the used coding scheme: It is 160 characters if the 7 bit GSM coding scheme is used.

 

 

 

 

AT+CMGP     Set CDMA/EVDO Text Mode Parameters

The command is used to select values for additional parameters needed when SM is sent to the network or placed in storage when text format message mode is selected.

NOTE: take effect in CDMA/EVDO mode

 

T) AT+CMGP=? OK
R) AT+CMGP?

+CMGP: <tid>,<vpf>,<vp>,<ddtf>,<ddt>

OK

W) AT+CMGP=[Tid][,<vpf>,<vp>[,<

ddtf>,<ddt>]]

OK
 

 

<tid>

Teleservice ID,value

maybe 4095,4096,4097,4098,4099,4100,4101,4102

Default 4098

<vpf>

Valid Period Format 0, Absolute

1, Relative

<vp>

Valid Period

“YY/MM/DD,HH/MM/SS”  if vpf=0, Integer not exceed 248 if vpf=1

<ddtf>

Deferred Delivery Time Format 0, Absolute

1, Relative

<ddt>

Deferred Delivery Time

“YY/MM/DD,HH/MM/SS”  if ddtf=0, Integer not exceed 248 if ddtf=1

 

 

Example

AT+CMGP=4098,0,11/04/22,16:21:00,1,12

OK

 

 

 

 

Adsense

EMW3070

Viewed Page List