Professional Documents
Culture Documents
SIM800 Series - STK - Application Note - V1.02
SIM800 Series - STK - Application Note - V1.02
Note _V1.02
Smart Machine Smart Decision
Version 1.02
Date 2018-03-15
Status Release
General Notes
SIMCom offers this information as a service to its customers, to support application and
engineering efforts that use the products designed by SIMCom. The information provided is based
upon requirements specifically provided to SIMCom by the customers. SIMCom has not
undertaken any independent search for additional relevant information, including any information
that may be in the customer’s possession. Furthermore, system validation of this product designed
by SIMCom within a larger electronic system remains the responsibility of the customer or the
customer’s system integrator. All specifications supplied herein are subject to change.
Copyright
This document contains proprietary technical information which is the property of Shanghai
SIMCom Wireless Solutions Ltd, copying of this document and giving it to others and the using or
communication of the contents thereof, are forbidden without express authority. Offenders are
liable to the payment of damages. All rights reserved in the event of grant of a patent or the
registration of a utility model or design. All specification supplied herein are subject to change
without notice at any time.
Contents
Appendix ..................................................................................................21
Version History
Date Version Description of change Author
2013-08-01 1.00 New version Ping.zhang
2016-11-17 1.01 Scope Wenjie.lai
2018-03-15 1.02 Charpter 2.10.2, change AT+STKMENU to Wenjie.lai
AT+STKMENU?
Scope
This document presents the AT command of STK operation and application examples.
This document can apply to SIM800 series modules with STK function.
1 STK Function
Although the base band of GSM/GPRS module is powerful enough to provide mobile phone
applications, there are chances that other devices are used for main controller and GSM/GPRS
base band serves as only a communication module. It may be because of MIPS requirement or
domain-specific applications. For example, a PDA with phone capability may use a powerful
processor as CPU and requires only communication functions of GSM/GPRS base band. The
following figure is the basic building blocks of such applications.
TE
RF B aseB and
SIM
ME
The terms used follow those in the ETSI/3GPP specifications. So that TE represents the
application device, which is the controller and serves for special functionalities. ME represents the
GSM/GPRS module, which provides GSM/GPRS service to the TE.
SIM is another seperated IC, and may not reside in GSM/GPRS modules. However, there
should be direct interfaces between SIM and GSM/GPRS BaseBand as defined in 3GPP
specification TS 11.11. So the SIM is conceptually a part of ME. (ME, SIM, and TE comprise a
MT, which is Mobile Terminal).
The SAT supported includes class 2 and class 3 (optional). No letter classes are supported.
SAT is defined in GSM 11.14. The AT commands listed in chapter2 are implemented to
support SAT functions. It should be noted that there are some special handling of SAT commands.
The AT commands are designed to achieve maximum flexibilities for TE. The basic
operation for ME is to forward Proactive commands and to receive Envelop/Terminal Responses
between SIM and TE.
TE
Proactive
+STK IN D
ME com m and
SIM
Envelop
/Term inal
A T+STK TR
R esponse
/A T+STK EN V
However, some commands must be handled by ME. The commands of SAT are categorized
into 3 groups:
Handled by TE only: ME transparently forwards the command to TE.eg. DISPLAY TEXT.
Handled by ME: TE is notified, but not involved in the SAT procedure.eg. POLL INTERVAL
Handled by both TE and ME together.
Command Description
AT+STKTRS This command is used to send STK Terminal Response
AT+STKENVS This command is used to send STK Envelope command
AT+STKCALL Trigger STK Call
AT+STKSMS Trigger STK SMS
AT+STKSS Trigger STK SS
AT+STKUSSD Trigger STK USSD
AT+STKDTMF Trigger STK DTMF
AT+STKMENU Show STK main menu
AT+STKPCIS Switch SKR URC string
+STKPCI This unsolicited result code is used to indicate Proactive Command
Indication.
2.1.1 Description
2.1.2 Format
Command Response
OK
AT+STKTRS==<result>[,<text>]
ERROR
+STKTRS: <result_length>,<text_length>
AT+STKTRS=?
OK
2.1.3 Field
2.2.1 Description
2.2.2 Format
Command Response
AT+STKENVS=<command>[,<data OK
>] ERROR
AT+STKENVS=? OK
2.2.3 Field
2.3.1 Description
2.3.2 Format
Command Response
AT+STKCALL=0 OK
AT+STKCALL=4
AT+STKCALL=16
AT+STKCALL=18
AT+STKCALL=32
AT+STKCALL=34
AT+STKCALL=? OK
2.3.3 Field
Note:
Above are the possible terminal response valuesto be responded by the application. It is ME’s
responsibility to respond other terminal response values.
According to spec 11.14 , 0x12 ("No response from user") is not a possible terminal response
value for STK CALLSETUP. So we will translate 0x12("No response from user") to 0x20("ME
currently unable to process this command").
2.4.1 Description
To deliver a SMS
2.4.2 Format
Command Response
AT+STKSMS=0 OK
AT+STKSMS=4
2.4.3 Field
Note: Above are the possible terminal response values to be responded by the application. It is
ME’s responsibility to respond other terminal response values.
2.5.1 Description
To setup a SS.
2.5.2 Format
Command Response
AT+STKSS=0 OK
AT+STKSS=4
AT+STKSS=50
AT+STKSS=? OK
2.5.3 Field
Note: Above are the possible terminal response values be responded by the application. It is
ME’s responsibility to respond other terminal response values.
2.6.1 Description
To setup a USSD.
2.6.2 Format
Command Response
AT+STKUSSD=0 OK
AT+STKUSSD=4
AT+STKUSSD=50
AT+STKUSSD=? OK
2.6.3 Field
Note: Above are the possible terminal response values be responded by the application. It is
ME’s responsibility to respond other terminal response values.
2.7.1 Description
2.7.2 Format
Command Response
AT+STKDTMF=0 OK
AT+STKDTMF=4
AT+STKDTMF=32
AT+STKDTMF=? OK
2.7.3 Field
Note: Above are the possible terminal response values be responded by the application. It is
ME’s responsibility to respond other terminal response values.
2.8.1 Description
2.8.2 Format
Command Response
+STKPCI: < pci_type > [,<proactive_command>,…]
2.8.3 Field
< pci_type>
-0 The SAT command is handled by TE
-1 The SAT command is handled by ME
-2 No other command (end of session)
<proactive command>
-DISPLAY TEXT,< Data coding scheme>,<text string>
-GET INKEY, < Data coding scheme>,<text string>
-GET INPUT, < Data coding scheme>,<text string>,<Min length>,<Max length>[,<default
text>]
-PLAY TONE,<alpha id>,<tone>,<duration>
-SET UP MENU,<the number of item >,<alpha id>
-SELECT ITEM, <the number of item >,<alpha id>
-ITEM,<index>,<id>,<item string>
-SEND SHORT MESSAGE,<alpha id>,<addr>,<sms tpdu>
-SEND SS,<alpha id>,<ss string>
-SEND USSD,<alpha id>,<ussd string>
-SETUP CALL,<alpha id>,<addr>
-SET UP IDLE MODE TEXT,<data coding scheme>,<text string>
-SEND DTMF,<alpha id>,<dtmf string>.
<Command Qualifier>
- DISPLAYTEXT
bit 1: 0 = normal priority
1 = high priority
bits 2-7: = RFU
bit 8: 0 = clear message after a delay
1 = wait for user to clear message
- GET INKEY,
bit 1: 0 = digits (0-9, *, # and +) only
1 = alphabet set
2.9.1 Description
2.9.2 Format
Command Response
AT+STKPCIS=<switch> OK
ERROR
AT+STKPCIS? +STKPCIS: <switch>
OK
2.9.3 Field
2.10.1 Description
2.10.2 Format
Command Response
AT+STKMENU? [+STKMENU:<index>,<id>,<text>]
[+STKMENU:<index>,<id>,<text>]
[+STKMENU:<index>,<id>,<text>]
[…]
OK
AT+STKMENU=? OK
2.10.3 Field
The following tables provide some examples for STK usage. Different SIM card has different
STK function. It is not necessary that the following examples are suitable for all of the SIM cards.
In the "Grammar" columns of following tables, input of AT commands are in black , module
return values are in blue.
Grammar Description
+STKPCI: 0,SET UP Proactive command SETUP MENU ,there
MENU,12,8051687403901A4E13533A are 12 items
Grammar Description
AT+STKTRS=00 Response to proactive command SETUP
OK MENU
AT+STKMENU? Query main menu
+STKMENU: 1,F0,806211662F51687403901A Item 1,ID is "F0"
+STKMENU: 2,F3,808D857EA753F77C3F Item 2,ID is "F3"
+STKMENU: 3,F8,806D3B52A84FE1606F
+STKMENU: 4,FF,804E1A52A163A88350
+STKMENU: 5,0A,808D448D3963A88350
+STKMENU: 6,0B,8081EA52A9670D52A1
+STKMENU:
7,0C,8079FB52A865B04E1A52A1
+STKMENU: 8,10,805F6994C38BBE7F6E
+STKMENU: 9,18,8097F34E506392884C699C
+STKMENU: 10,21,8065B095FB8D448BAF
+STKMENU: 11,25,8065E07EBF4F1195F2
+STKMENU:
12,FE,8000530049004D53614FE1606F
OK
+STKPCI: 2 End of session
Grammar Description
AT+STKENVS=D3,F0 Select item which ID is "F0"
OK
+STKPCI: 0,SELECT ITEM,2,0 Proactive command select item, there are 2
+STKPCI: items
0,ITEM,1,01,8054C1724C4FE1606F7EA7522B Sub item 1, ID is "01"
+STKPCI: Sub imte 2, ID is "02"
0,ITEM,2,02,8066F465B054C1724C4FE1606F
+STKPCI: 2 End of session
Grammar Description
AT+STKTRS=00,01 Select item which id is "01"
OK
+STKPCI: 0,DISPLAY TEXT, Proactive command DISPLAY TEXT
129,085C0A656C768451687403901A5BA26237 129: high priority, wait for user to clear
FF1A611F8C2260A8900962E94E2D56FD79FB message
52A8901A4FE1FF0151687403901A52A960A86 08: Unicode encoding
210529FFF01
AT+STKTRS=00 Respond to DISPLAY TEXT
OK
+STKPCI: 2 End of session
Grammar Description
AT+STKENVS=D3,F3 Select item which ID is "F3"
OK
+STKPCI: 0,SELECT ITEM,7,0 Proactive command SELECT ITEM, there
+STKPCI: 0,ITEM,1,01,8053F77C3F7BA17406 are 7 sub itmes
+STKPCI: 0,ITEM,2,02,8062FC97F367E58BE2 Sub item 2, ID is "02"
+STKPCI: 0,ITEM,3,03,8059D3540D67E58BE2
+STKPCI: 0,ITEM,4,04,8053F77C3F6D4F89C8
+STKPCI:
0,ITEM,5,05,8077ED4FE17FA453D1
+STKPCI: 0,ITEM,6,06,807FA47EC47BA17406
+STKPCI: 0,ITEM,7,07,8065B0589E8BB05F55
Appendix
A Related Documents
Abbreviation Description
SAT SIM Application Toolkit
EVB Evaluation Board
STK SIM Toolkit Command begin tag
URC Unsolicited request code
TE Terminal Equipment
TA Terminal Adapter
DTE Data Terminal Equipment or plainly "the application" which is running on an
embedded system
DCE Data Communication Equipment or facsimile DCE(FAX modem, FAX board)
ME Mobile Equipment
MS Mobile Station