AT Command Reference Guide for EDGE Wireless ... - wless.ru
AT Command Reference Guide for EDGE Wireless ... - wless.ru
AT Command Reference Guide for EDGE Wireless ... - wless.ru
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Chapter 13 – Short Message Service (SMS) <strong>Command</strong>s<br />
13.8 <strong>AT</strong>+CMGW Write Short Messages to Memory<br />
Description:<br />
The execute and write commands transmit a short message (either SMS-DELIVER or<br />
SMS-SUBMIT) from TE to memory storage . Memory location of the<br />
stored message is returned. Message status will be set to ‘stored unsent’ unless otherwise<br />
given in parameter .<br />
After invoking the execute or write command wait <strong>for</strong> the prompt “>” and then start to write<br />
the message. To save the message simply enter . After the prompt a timer will<br />
be started to observe the input.<br />
To abort writing use . Abortion is acknowledged with “OK”, though the message will<br />
not be saved.<br />
Test <strong>Command</strong> Syntax: <strong>AT</strong>+CMGW=<br />
Response:<br />
OK<br />
Exec <strong>Command</strong> Syntax: If text mode (see <strong>AT</strong>+CMGF=1):<br />
<strong>AT</strong>+CMGW<br />
Response:<br />
Text can be entered. /<br />
+CMGW: <br />
OK<br />
If writing fails<br />
ERROR<br />
+CMS ERROR<br />
Write <strong>Command</strong> Syntax: If text mode (see <strong>AT</strong>+CMGF=1):<br />
<strong>AT</strong>+CMGW=/[, [/][, ]] Text can be entered. /<br />
Response:<br />
+CMGW: <br />
OK<br />
If writing fails see notes below.<br />
Write <strong>Command</strong> Syntax: If PDU mode (see <strong>AT</strong>+CMGF=0):<br />
<strong>AT</strong>+CMGW=[, ] PDU can be entered. /<br />
Response:<br />
+CMGW: <br />
OK<br />
If writing fails see notes below.<br />
Notes:<br />
• If writing fails, <strong>for</strong> example, if a message is too long, the result code depends on the current setting of the<br />
<strong>AT</strong>^SM20 command:<br />
If the <strong>AT</strong>^SM20 =1 (factory default) any failure to send a message is responded with “OK”. Users<br />
should be aware, that despite the “OK” response, the message will not be written to the selected SMS storage.<br />
If the <strong>AT</strong>^SM20 equals 0 any failure to write a message is responded with “ERROR”.<br />
If writing fails due to timeout, then <strong>AT</strong>^SM20 =1 causes “+CMS ERROR: Unknown error” to be<br />
returned; <strong>AT</strong>^SM20 =0 causes “+CMS ERROR: timer expired” to be returned.<br />
• Note that some providers do not recognize an @ symbol used in a short message. A widely used alternative is<br />
typing “*” as defined in GSM 03.40 (GPP TS 23.40).<br />
• For baudrates lower than 19200 it is recommended to use the line termination character only (refer to <strong>AT</strong>S3=<br />
, default ) be<strong>for</strong>e entering the text or PDU. Use of the line termination character followed by the<br />
response <strong>for</strong>mating character (see <strong>AT</strong>S4= , default ) may cause problems.<br />
• SMS-COMMANDs and SMS-ST<strong>AT</strong>US-REPORTs cannot be stored in text mode.<br />
• All characters entered behind the “>” prompt will be recognized as GSM characters. For example, “Backspace”<br />
(ASCII character 8) does not delete a character, but will be inserted into the short message as an additional<br />
physical character. As a result, the character you wanted to delete still appears in the text, plus the GSM code<br />
equivalent of the Backspace key.<br />
• In text mode, the maximum length of a short message depends on the used coding scheme: It is 160 characters<br />
if the 7 bit GSM coding scheme is used, and 140 characters according to the 8 bit GSM coding scheme.<br />
• The length of 8-bit data coded short messages has to be greater than 0.<br />
Multi-Tech Systems, Inc. <strong>AT</strong> <strong>Command</strong>s <strong>for</strong> <strong>EDGE</strong> Modems (S000371B) 178