Specifications

Chapter 17 – Audio Commands
Multi-Tech Systems, Inc. AT Commands for EDGE Modems (S000371B) 209
16.9 AT^SPBG Display Phonebook Entries in
Alphabetical Order
Description: AT^SPBG sorts the entries of the current phonebook in alphabetical order by name (the first six
characters matter). The sort order is described in Section 16.1, Sort Order for Phonebooks.
There are two ways to use AT^SPBG:
If the optional parameter <RealLocReq> equals 0 or is omitted, the sorted entries will be
sequentially numbered. As these numbers are not identical with the location numbers
stored in the various phonebooks, AT^SPBG can be used for reading only. For example, it
helps you find entries starting with matching characters. Do not use the serial numbers to
dial out or modify entries.
If parameter <RealLocReq>=1 is given by the write command, the response parameter
<location> additionally appended to each entry indicates the actual location number. This
number can be used for editing with AT+CPBW or dialing with ATD><mem><n>. The first
index number of each entry is only the serial number of the sorted list.
Before using the write command, it is recommended to query the number of records currently
stored in the active phonebook (refer to test command <used>). The test command also
includes the <nlength> and <tlength>. Note that if SIM storage is selected, the length may not be
available. If storage does not offer format information, the format list shows empty parentheses.
Test Command Syntax: AT^SPBG=?
Response: ^SPBG: (1-<used>), <nlength>, <tlength>
OK
ERROR
+CME ERROR
Write Command Syntax: AT^SPBG=<index1>[, <index2>][, <RealLocReq>]
Response: [^SPBG: <index1>, <number>, <type>, <text>[, <location>]]
[^SPBG: <index2>, <number>, <type>, <text>[, <location>]]
OK
ERROR
+CME ERROR
Parameter Description:
<index1>
First index number in the sorted list where reading starts. See the test command response for supported range.
If <index 1> exceeds the upper bound <used>, “+CME ERROR: “invalid index” will be returned.
<index2>
Last index number in the sorted list where to stop reading. See the test command response for supported range.
If <index2> is not given via write command, only the entry located at <index1> will be displayed.
If both <index1> and <index2> are in the range indicated by the test command parameter <used>, the list of
entries will be output and terminated with OK.
If <index2> exceeds the range indicated by the test command parameter <used>, the list of entries will be output
but terminated with a “+CME ERROR: “invalid index”.
<RealLocReq>
Is a display of the “real” <location> of the entry required?
0 Do not show an entry’s “real” location number. Parameter <location> will not be displayed. Default.
1 Show the “real” location number as parameter <location> at the end of each entry.
<number>
String type phone number in format specified by <type>.
The number parameter may be an empty string.
<type>
Type of address octet that defines the type of number (ton) and the numbering plan identification (npi) used.
Please consider that for types other than 129 or 145 dialing from phonebook with ATD><mem><n> is, depending
on the network, not always possible (refer to GSM 04.08 subclause 10.5.4.7 for details). See AT+CPBW <type>.
Possible values are:
145 Dialing string <number> includes international access code character ‘+’
161 National number. Network support of this type is optional.
209 Dialing string <number> has been saved as ASCII string and includes non-digit characters other
than “*”, “#” or “+”. Note that phonebook entries saved with this type cannot be dialed.
255 Dialing string <number> is a command to control a Supplementary Service; i.e., “*”, “#” codes are
contained. Network support of this type is optional.
129 Otherwise