Hi,
I am working on project which requires to access SIM service menu (SIM toolkit). I am using SIM900 Arduino GSM shield.
I referred the "AT commands manual" of SIM900 as well.
(http://elecfreaks.com/estore/download/EF02020-SIM900_AT%20Command%20Manual_V1.03.pdf)
I found AT commands of SIM toolkit on page 118.
While playing with those commands, I was able to access to the menu. I created simple Arduino program so that I can test AT commands using serial monitor. I have included Arduino code, AT commands I used(red) and results(blue) below.
#include <SoftwareSerial.h>
#define RX 2
#define TX 3
String cmd;
SoftwareSerial Gsm = SoftwareSerial(RX, TX); // Set up a new serial port
void setup() {
Serial.begin(115200);
Gsm.begin(19200);
}
void loop() {
if(Serial.available() > 0)
{
cmd = Serial.readStringUntil('\n');//Read input until \n
if(cmd.length()>0)
sendCmd(cmd);
}
if (Gsm.available()>0){
Serial.print((char)Gsm.read());// Print serial data if available
}
}
void sendCmd(String command){
Gsm.println(command);// Send AT command to GSM module
}
Commands I sent and results:
AT*PSSTK=? // Get all supported commands
*PSSTK: "COMMAND REJECTED","NOTIFICATION","SETUP CALL","DISPLAY TEXT","GET INKEY","GET INPUT","PLAY TONE","SELECT ITEM","SETUP MENU","REMOVE MENU","MENU SELECTION","ALL CALLS DISCONNECTED","USER ACTIVITY","IDLE SCREEN AVAILABLE","SETUP CALL TERMINATED","GET ITEM LIST","LANGUAGE NOTIFICATION","SETUP IDLE MODE TEXT"
AT*PSSTK="SETUP MENU",1,1 // Visit to menu. I am not aware of the meaning of arguments: 1,1 ![]()
OK
*PSSTK: "END SESSION"
AT*PSSTK="GET ITEM LIST",8 // View menu items. 8: number of available options. If number<available options, list will be trimmed. Else, no issue. Therefore I did not care of this parameter as long as it is higher than available options. ![]()
*PSSTK: "GET ITEM LIST",1,1,4,"Smart Services",0,0,0
*PSSTK: "GET ITEM LIST",2,2,4,"Fun Zone",0,0,0
*PSSTK: "GET ITEM LIST",3,3,4,"News n Info",0,0,0
*PSSTK: "GET ITEM LIST",4,4,4,"Messaging",0,0,0
*PSSTK: "GET ITEM LIST",5,5,4,"Live Life",0,0,0
*PSSTK: "GET ITEM LIST",6,6,4,"Client Support",0,0,0
*PSSTK: "GET ITEM LIST",7,7,4,"Easy Roaming",0,0,0
*PSSTK: "GET ITEM LIST",8,8,4,"Emergency",0,0,0
OK
AT*PSSTK="MENU SELECTION",6 // Select 6th item
OK
*PSSTK: "SELECT ITEM",1,4,"Client Support",0,0,2,0,0,5
AT*PSSTK="GET ITEM LIST",10 // View available options.
*PSSTK: "GET ITEM LIST",1,1,4,"Balance",0,0,0
*PSSTK: "GET ITEM LIST",2,2,4,"Credit Gifting",0,0,0
*PSSTK: "GET ITEM LIST",3,3,4,"Give me balance",0,0,0
*PSSTK: "GET ITEM LIST",4,4,4,"Reload",0,0,0
*PSSTK: "GET ITEM LIST",5,5,4,"Reload a Friend",0,0,0
OK
ATPSSTK="SELECT ITEM",6,1,0,0 // Select 1st option. I did not know correct syntax. I played with this command and found this. ATPSSTK="SELECT ITEM",<selected menu#>,<selection option#>,0,0 8)
OK
*PSSTK: "SELECT ITEM",1,4,"Balance",0,0,3,0,0,2
AT*PSSTK="GET ITEM LIST",10 // View available options
*PSSTK: "GET ITEM LIST",1,1,4,"Prepay",0,0,0
*PSSTK: "GET ITEM LIST",2,2,4,"Postpay",0,0,0
OK
AT*PSSTK="SELECT ITEM",6,1,2,0 // I think that this is the way to select 2nd one :![]()
OK
*PSSTK: "NOTIFICATION",4,18,0,255,"",0,0
I was unable to find out what should I do next. When I selected "postpay" using a mobile phone, it displays "wait" and then I get an SMS shortly including balance. Here I get nothing. I think that SIM900 asking for permission to send request with PSSTK: "NOTIFICATION",4,18,0,255,"",0,0
I was unable to find out the next AT command I should use.
Also I cannot go back or exit from this menu once I visited to the menu. I tried using ATPSSTK="REMOVE MENU" but SIM900 returns ERROR for that command.
Also I need to find out the way to provide user inputs for this menu as well (Eg: for RELOAD/ CREDIT GIFTING....). Can someone help me with this?
![]()
Thank you
Kasun