Digicom pocket GSM User Manual

http://www.digicom.it
DUAL-BAND MODEM
Dual-Band EGSM900/DCS1800
Data Transmission up to 9.6Kbps V.32 and V.110
SMS support PDU and Text mode
Voice and Fax support
Flash Upgradable
rev. 3.1 12/2004
POCKET GSM
I
PocketGSM Index
INDEX
PREFACE II
ENVIRONMENTAL CONDITIONS II CLEANING THE TERMINAL II VIBRATIONS OR DROPPING II
DECLARATION CE OF CONFORMITY II
1. INTRODUCTION 1.1
1.1. TECHNICAL FEATURES 1.1
1.2. WARNINGS 1.1
2. INSTALLATION 2.1
2.1. PIN-OUT CONNECTOR 2.1
2.2. SIM CARD 2.2
2.3. CONNECTION TO THE EXTERNAL ANTENNA 2.2
2.4. POWER SUPPLY 2.4
2.5. LED INDICATORS 2.5
2.6. CONNECTOR FOR THE VOICE MANAGEMENT 2.6
3. FUNCTIONAL EXAMPLES 3.1
4. AT COMMANDS 4.1
4.1. COMMANDS NOTES 4.1
4.2. AT COMMANDS DESCRIPTION 4.2
4.2.1. GENERAL COMMANDS 4.2
4.2.2. 07.07 GSM COMMANDS 4.11
4.2.3. PHONEBOOK COMMANDS 4.18
4.2.4. VOICE COMMANDS 4.20
4.2.5. SMS CONTROL COMMANDS (GSM 07.05) 4.24
4.2.6. GPIO COMMANDS (GENERAL PURPOSE INPUT OUTPUT) 4.30
4.2.7. GPRS COMMANDS (GSM 07.07) 4.37
APPENDIX A A.1
II
PREFACE
All rights reserved; no part of this publication may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, electronic, otherwise, without the prior written permission of Digicom S.p.A. The following installation rules should be respected in order to have the best working order of the equipment and for the user’s safety.
ENVIRONMENTAL CONDITIONS
Enviromental temperature Relative humidity
from -20 to +55°C from 20 to 80% n.c. Rapid changes of temperature or humidity should be avoided. This equipment, including cables, should be installed in an area free from:
Dust, humidity, heat from direct sun light.Objects which irradiate heat. These could cause damage to the container or other problems.Objects which produce a strong electtromagnetic field (loudspeakers, etc.)Liquids or chemical corrosive substances.
CLEANING THE TERMINAL
Use a clean and soft cloth. Wet the cloth with water or natural detergent if it is necessary to remove any stains. Never use chemical products such as petrol or solvents.
VIBRATIONS OR DROPPING
Caution against vibrations and dropping.
DECLARATION OF CONFORMITY
We, Digicom S.p.A. registered office at: via Volta 39 - 21010 Cardano al Campo (Varese - Italy) declare under our sole responsability that the product: Name: POCKET GSM Type: Modem Dual-Band GSM 900/1800MHz satisfies the basic requirement of the below indicated Directive:
1999/5/CE of March 9 1999, R&TTE
as having been designed in conformity with the requirements of following Reference Standards: EN 60950 EN 301 489-1 EN 301 489-7 EN 301-419-1 EN 301-511
PocketGSM Preface
PocketGSM Introduction
1.1
1. INTRODUCTION
Congratulation on choosing digicom PocketGSM.
Pocket GSM is a GSM Dual-Band modem (EGSM900/DCS1800), perfect for DA T A, SMS, FAX and VOICE applications. It has been designed to operate on any digital GSM network both directly and in roaming. PocketGSM is compliant with GSM Class 4 (900Mhz) and Class 1 (1800 Mhz). The dual band functionality depends on the network. Please refer to GSM provider for the availability of the service.
1.1. TECHNICAL FEATURES
Power Supply
Power Supply: from 5 to 32 Vdc
Temperature
Operating: from -20°C to +55°C Storage: from -20°C to +70°C
Connectors
Power Supply & I/O: Mini-Fit™ 12 pin (Molex 556912A1) Data interface: 9 pin RS232 (V24/V28) Antenna: SMA female Audio: RJ6 female (telephone handset) SIM: Plug-In 3V
Size
Size: 87x75x25mm Weight: about 130gr
1.2. WARNINGS
Satefy
Read carefully these instructions and notes before powering PocketGSM. For each situation please follow the specific instructions.
PocketGSM Introduction
1.2
PocketGSM is a low power radio transmitter and receiver. When it is ON, it sends receives radio frequency (RF) signals. PocketGSM produces magnetic fields. Do not place it next to magnetic support such as floppy disks, tapes, et. . Operating your modem close to other electrical equipment such as television, phone, radios and personal computer, may cause interference.
Interference
PocketGSM, like all wireless devices, is subject to interferences that may reduce its performances.
Road Safety
Do not use PocketGSM while driving. In case of use on cars, it is necessary to check that electronic equipment is shielded against RF signal. Do not place PocketGSM over the air bag or in the air bag deployment area.
Aircraft Safety
Switch off PocketGSM in aircraft by disconnecting the Power cable. Using GSM devices on aircraft is illegal.
Hospital Safety
Do not use PocketGSM near health equipment, especially pacemaker and hearing aids, to avoid potential interferences. PocketGSM is a not mobile phone, do not use it in direct contact with the human body. Switch it off in hospitals, and medical center. Hospitals or health care facilities may be using equipment that could be sensitive to external RF energy.
Explosive Materials
Do not use PocketGSM in refuelling points, near fuel or chemicals. Do not use the PocketGSM where blasting is in progress. Observe restrictions, and follow any regulation or instruction.
Instructions for use
Do not use PocketGSM in direct contact with the human body, do not touch the antenna if not necessary when the phone is in use. Use approved accessories and batteries only. Do not connect incompatible products.
PocketGSM Installation
2.1
2. INSTALLATION
The GSM modem installation must be carried out between a range of temperature indicated in the manual.
Attention: the power supply voltage must not exceed the indicated maximum value as this may cause
a damage of the product.
2.1. PIN-OUT CONNECTOR
Connect the serial port of your device to PocketGSM through a 9 pin RS232 right standard connector . This table describes the position of the signals on Pocket GSM connector:
9 pin female connector (DCE) Pin Description Initials
1 Data Carrier Detect DCD 2 Receive Data RD 3Transmitted Data TD 4 Data Terminal Ready DTR 5 Signal Ground GND 6 Data Set Ready DSR 7 Request To Send RTS 8 Clear T o Send CTS 9 Ring Indicator RI
In case your application supports TD and RD (transmission and reception)signals only, it is possible to connect it to the Pocket GSM. In this case it is important to configure PocketGSM to ignore the not present criteria.
[ For further information about commands, see the chapters “Functional Examples” and “AT
Commands”; you’ll find the “AT Commands” chapter in the user’s manual present on Digicom website ]
The modem can receive AT commands at the speeds between 300 and 115200 bit/s.
51
96
PocketGSM Installation
2.2
2.2. SIM CARD
Plug-in SIM are supported by PocketGSM. To prevent damaging or losing information avoid touching the sim gold area.
Attention: Check with your GSM provider if your SIM is enable for data and fax traffic, if not ask him for
this service, he will give you other two numbers (one for data calls and the other for fax calls).
Insert the SIM
Probably the SIM card will be supplied in a card holder compliant with the devices using the full-size SIM.
1. Remove the SIM carefully from the SIM holder.
2. Turn off Pocket GSM, by disconnecting the power connector.
3. Discover the SIM slot and press on the release pin with a finger or a pencil.
4. Insert the SIM card into the holder. Be sure the angled corner is top right.
5. Close the SIM holder and press it up to the end. Do not force the SIM holder and verify the correct position. .
2.3. CONNECTION TO THE EXTERNAL ANTENNA
To connect the external antenna go on as follows:
1. Tu rn off your Pocket GSM by disconnecting the power connector.
2. Connect the SMA male connector to the external antenna of Pocket GSM, screwing it clockwise.
3. Place the antenna and check there is a good quality signal.
PocketGSM Installation
2.3
You can check the signal:
Using a cellular phone
Insert the SIM of the PocketGSM in a cellular phone and check the quality of the signal.
Through the Led STATUS
Power on the modem and verify the STATUS Led. If it is red blinking, it means the modem is recognized by the GSM network. In this way you can check the signal but not its quality.
Attention: even if you see the STATUS Led blinking, it may not be sufficient for data transmission.
Through the AT+CSQ command
By using this command it is possible to detect a more precise signal. Power on PocketGSM and connect it to a Personal cpmputer, using a serial cable. With a hyperterminal send to the modem the command AT+CSQ. The modem will answer with +CSQ: x,y; where “x” is the signal quality, “y” is the BER (But Error Rate). The value of “x” can be included between 0 to 31; the higher value indicates a better signal. From 0 to 9 : poor From 10 to 15 : good From 16 to 31 : excellent 99 = Unknown or uncalculable BER values higher than 2 may compromise the good operation of the device. In this case place the antenna in a better position.
[ For further information about commands, see the chapters “Functional Examples” and “AT
Commands”; you’ll find the “AT Commands” chapter in the user’s manual present on Digicom website ]
Attention: for better performances of the supplied stilo antenna, we suggest to position it upwards. Try
to fix Pocket GSM and its antenna at least one meter from the floor. In case you use a different antenna, do not fix it directly to the mechanics of the product or on metal surfaces.
PocketGSM Installation
2.4
2.4. POWER SUPPLY
The inputs, outputs and power supply use a Minifit 12 pin connector:
Frontal view PIN Description
1 OUTPUT 2 (Open Collector) (GPO2) 2 OUTPUT 1 (Open Collector) (GPO1) 3 DIGITAL INPUT 4 (GPIO5) 4 DIGITAL INPUT 3 (GPIO4) 5 DIGITAL INPUT 2 (GPIO0) 6 DIGITAL INPUT 1 (GPI3) 7 N.C. 8 N.C.
9 Power supply from 5 to 32Vdc 10 GND 11 ANALOG INPUT 2 (ADC2) 12 ANALOG INPUT 1 (ADC1)
pin 9 : positive [from +5 to +32Vdc]
pin 10 : negative [GND] The modem has a special protection in case you accidentally invert the polarity. The modem power supply must be included between 5 and 32 Vdc with ground negative.
Attention: the power supply voltage must not exceed the indicated maximum value as this may cause
a damage of the product.
PocketGSM Installation
2.5
2.5. LED INDICATORS
Through two led indicators you can control the status of Pocket GSM:
LED STATUS DESCRIPTION
POWER OFF No power supply
ON Power supply on
STATUS OFF No power supply
ON PocketGSM is in one of the following status:
- network search mode;
- SIM card not present;
- PIN not inserted;
- emergency mode.
SLOW BLINKING PocketGSM detected by the GSM network
FAST BLINKING PocketGSM connected to another device
PocketGSM is ready to work only after it has been registered by the GSM network and with a good quality signal. To verify that PocketGSM is ready for calls and SMS, follow these commands:
COMMAND DESCRIPTION
AT+CPIN? Verifies the presence of the SIM and the PIN code AT+CREG? Verifies the registration to the GSM network AT+COPS? Verifies the current GSM operator AT+CSQ Verifies the quality of GSM signal
[ For further information about commands, see the chapters “Functional Examples” and “AT
Commands”; you’ll find the “AT Commands” chapter in the user’s manual present on Digicom website ]
PocketGSM Installation
2.6
2.6. CONNECTOR FOR THE VOICE MANAGEMENT
For the voice functionality, Pocket GSM is equipped with a double ended audio interface on RJ6 female connector with the same Pin-out of a standard telephone handset The interface can be connected both to a handset or to a loud speaking telephone.
VOICE connector Pin-Out (RJ6)
1 Microphone ( + ) 2 Speaker ( + ) 3 Speaker ( - ) 4 Microphone ( - )
The modem includes AC coupling and biasing for electret microphone.
Suggested characteristics for the microphone
Polarizzazione : 2V – 0.5mA Impedance: 2K Sensitivity : from –40dBm to –50dBm SNR (Signal to Noise Ratio) : > 50dBm
Suggested characteristics for the speaker
Type : 10mW, electro-magnetic Impedance : from 32 to 150
Suggest configuration
AT+SPEAKER=0 AT+ECHO=0 AT+SIDET=1,3
[ For further information see the chapter “AT Commands” present in the user’s manual on Digicom
website ]
4
3
2
1
PocketGSM Functional Examples
3.1
3. FUNCTIONAL EXAMPLES
Pocket GSM can be programmed through a set of AT commands for the execution of all its functionalities. If you are using a PocketGSM/GPRS, information for the GPRS functionality are present in “AT Commands” chapter. It is present in the user’s manual on Digicom web site. Here the description of some applications. For the complete AT command set, see the chapter “AT Commands”.
Attention: In the factory configuration the AT commands are managed at 9600bit/s only (the PocketGSM/
GPRS at 115200bit/s only). Before going on with your settings, you must set your terminal emulator (e.g. HyperTerminal) or your application as follows: 9600,8,N,1 (with PocketGSM/GPRS: 115200,8,N,1) then you can modify the interface speed with the values included between 300 and 115200bit/s with the command AT+IPR.
[ For further information see the chapter “AT Commands” present in the user’s manual on Digicom
website ]
A) PIN management B) PocketGSM ready to work C) Serial cable not completed D) Data transfer E) SMS Management (Text mode)
PocketGSM Functional Examples
3.2
A) PIN MANAGEMENT
Due to security reasons, usually SIM cards require the insertion of PIN code. With Pocket GSM you can insert the PIN code through the AT+CPIN command. If your application has other security systems, you can disable the PIN request using a mobile phone.
Examples:
Command: AT+CPIN? (Verify the SIM and the PIN status) Answer: ERROR (SIM card reading failed) Answer: +CPIN: READY (PIN code present: SIM ready) Answer: +CPIN: SIM PIN (PIN code insertion is required) Answer: +CPIN: SIM PUK (PUK code insertion is required) Answer: +CPIN: SIM PIN2 (PIN2 code insertion is required)
In case the PIN code is not present, it must be inserted before using the SIM card:
Command: AT+CPIN=4321 (PIN insertion) Answer: OK (PIN code right) Answer: ERROR (PIN code wrong)
Attention: remember that if the PIN code is wrongly inserted for three times, the SIM card will block. To
unblock it you must insert the PUK code.
[ For further information see the chapter “AT Commands” present in the user’s manual on Digicom
website ]
PocketGSM Functional Examples
3.3
B) POCKET GSM READY TO WORK
PocketGSM can work only after it has been detected by the network and with a good GSM signal. To verify PocketGSM is ready to manage calls and SMS, follow these commands:
Command: AT+CPIN? Answer: +CPIN: READY (SIM is ready)
Command: AT+CREG? Answer: +CREG: 0,1 (GSM modem is registered by the network)
OK
Command: AT+COPS? Answer: +COPS: 0,2,22288 (PocketGSM is registered at operator 22288)
OK
Command: AT+CSQ Answer: +CSQ: 15,0 (GSM signal: good)
OK
The CSQ value can be included between 0 and 31, where 0 = –113dBm and 31 = –51dBm. Every unit corresponds to 2 dBm.
From 0 to 9 = not sufficient From 10 to 15 = good From 16 to 31 = excellent
[ For further information see the chapter “AT Commands” present in the user’s manual on Digicom
website ]
PocketGSM Functional Examples
3.4
C) SERIAL CABLE NOT COMPLETED
In case your application (eg. PLC) supports only TD and RD signals (Trasmission and Reception), it is however possible to connect it to the PocketGSM. In this case you will use a non-completed serial cable; for this reason it is important to configure PocketGSM so that it ignores the serial criteria not present. Usually PocketGSM, during the communication phase, checks the following criteria: 108 (Data Terminal Ready) and 105 (Request To Send): to disable them use the commands AT&D and AT+IFC.
Examples:
Command: AT&D0 (Criterion 108 ignored) Command: AT&D2 (Criterion 108 managed as per specification) Answer: OK
Command: AT+IFC=0,0 (Criterion 105 ignored: flow control OFF) Command: AT+IFC=2,2 (Criterion 105 managed as per specification: flow control ON) Answer: OK
D) DATA TRANSFER
PocketGSM can call and be called by analog (PSTN), digital (ISDN) and GSM devices. Usually DATA connections with analog modems are at 9600bit/s (V.32 protocol); ISDN connections use V.110 protocol with speed at 9600bit/s. The data transfer with another GSM device is carried out using V.32 or V.110 protocols.
DATA Calls
Using the ATD command it is possible to make a call. For example, to call the number 0123456789 you must send to the modem the command ATD0123456789<Enter>. Depending on the AT+CBST command setting it is possible to program PocketGSM for analog, digital or GSM calls:
AT+CBST=0,0,1 connection with analog or GSM modems in multistandard (V.32) AT+CBST=7,0,1 connection with analog or GSM modems only in V.32 at 9600bit/s AT+CBST=71,0,1 connection with digital or GSM modem only in V.110 at 9600bit/s
PocketGSM Functional Examples
3.5
Attention: check with your telephone operator if your SIM is enabled for DATA and eventually for FAX.
In fact most SIMs are enabled for Voice(call and reception) while for DATA and FAX only the call is enabled. To enable the reception of DATA and FAX traffic it is necessary to ask the telephone operator that will assign two additional numbers (one to receive DATA calls and one to receive FAX calls).
Examples:
Command: AT+CBST=7,0,1 V.32 call at 9600bit/s Answer: OK Command: ATD0123456789 Answer: CONNECT 9600
Command: AT+CBST=71,0,1 V.110 call at 9600bit/s Answer: OK Command: ATD0123456789 Answer: CONNECT 9600
DATA calls reception
Generally in PocketGSM the automatic answer is disabled (S0=0): in this case the modem will answer only after it received the ATA command. In case you want to enable the automatic answer, you must set the S0 register with the number of rings after which to answer (eg. S0=2 automatic answer after two rings). PocketGSM factory configuration has the AT+CBST=0,0,1 setting, in this way it will be able to answer to any call coming from an analog, ISDN or GSM modem.
[ For further information see the chapter “AT Commands” present in the user’s manual on Digicom
website ]
E) SMS MANAGEMENT (TEXT mode)
PocketGSM manages the SMS in TEXT and PDU format.
Send an SMS (TEXT mode)
You find here the necessary commands to send SMS in TEXT mode.
PocketGSM Functional Examples
3.6
1) Reading and Setup of the Services Center
To activate the SMS management, you must insert the identifier number of the Services Center for your GSM operator. In the most recent SIM cards, the identifier is already present in memory: to verify you can use a mobile phone or, with Pocket GSM, you can act as follows:
Command: AT+CSCA? (reading of Services Center) Answer: +CSCA: “+393205858500”,145 (Services Center present)
OK
If the Services Center number is not present, ask the telephone operator, then insert the identifier as follows:
Command: AT+CSCA=”+393359609600” (eg. TIM Services Center) Answer: OK Command: AT+CSAS (Save the number of Services Center) Answer: OK
Attention: the above mentioned numbers (Services Centers) could be modified by the telephone
operator. In case of error after you send the SMS, check the identifier of the Services Center with your Telephone Operator.
2) Define the mode
Command: AT+CMGF=1 (TEXT mode) Answer: OK
Command: AT&W (Save the configuration) Answer: OK
3) Send a message:
Command: AT+CMGS=”+393217654321”<enter> Answer: >
PocketGSM Functional Examples
3.7
Text: First SMS message with Pocket GSM<ctrl z> Answer: +CMGS: <sms index>
OK
After you digit yuor message, press <ctrl z> (Hex =1A). In this example the message “First SMS message with Pocket GSM” is sent to number +393217654321.
Attention In case of error after you send the SMS, check the identifier of the Services Center with your
Telephone Operator.
Read the SMS (TEXT mode)
The factory configuration of PocketGSM detects the coming of a new SMS. When an SMS arrives, PocketGSM send to the DTE (eg. PC) the following message: +CMTI: “SM”,2 (2 indicates the memory location of the SIM card where the SMS has been stored). To read the message use the AT+CMGR command:
Command: AT+CMGR=2 Answer: +CMGL: 2,"REC UNREAD","+393217654321",,"01/01/75,12:05:46+04"
Second SMS message with PocketGSM
To display all the messages present in the SIM memory:
Command: AT+CMGL=”ALL” Answer: +CMGL: 1,"REC READ","+393217654321",,"01/01/75,12:05:46+04"
First SMS message with Pocket +CMGL: 2,"REC UNREAD","+393217654321",,"01/01/75,12:06:26+04" Second SMS message with PocketGSM OK
PocketGSM Functional Examples
3.8
Through the AT+CNMI command it is possible to program the PocketGSM so as it sends immediately the received message to the DTE (eg. PC):
Command: AT+CNMI=2,2 Answer: OK
With this configuration PocketGSM sends immediately the message to the DTE, when it receives it from the network:
+CMT: "+393217654321",,"01/01/75,12:06:14+00" First SMS message with Pocket GSM
Cancel the SMS
For example, to cancel the second message:
Command: AT+CMGD=2 Answer: OK
[ For further information see the chapter “AT Commands” present in the user’s manual on Digicom
website ]
PocketGSM AT Commands
4.1
4. AT COMMANDS
PocketGSM supports a complete A T commands set to configure and test the modem and all its functionalities. These commands are based on the following recommandations:
ETSI GSM 07.07: Digital cellular telecommunications system (Phase 2); AT command
set for GSM Mobile Equipment (ME);
ETSI GSM 07.05: Digital cellular telecommunications system (Phase 2); Use of DTE-
DCE interface for Short Message Service (SMS) and Cell Broadcast Service (CBS);
ITU-T Recommandation V.25ter: Serial asynchronous automatic dialling and control.
The factory configuration of PocketGSM accepts AT commands only at 9600bit/s (the PocketGSM/GPRS only at 115200bit/s). Before going on you must set your terminal emulator (e.g. HyperTerminal) or your application with these values:
Bit per second = 9600 (with PocketGSM/GPRS : 115200)
data bit = 8
parity = None
stop bit = 1
flow control = Hardware (RTS/CTS) Use the commands AT+IPR, A T+ICF , A T+IFC to change the modem interface speed and
the flow control.
4.1. COMMANDS NOTES
Please read these before using PocketGSM:
The commands always start with AT ; it means Attention, and end with <CR> (Hex=0D)
character.
The answer messages in extended format (ATV1 command) start and end with
<CR><LF> (Hex=0D 0A). If Pocket GSM is programmed to manage numeric answers
PocketGSM AT Commands
4.2
(ATV0), then the answer will not have the prefix <CR><LF> and will be ended with the <CR> character.
To disable the answer messages use ATQ1 command.If the syntax of the command is wrong, the modem sends the answer ERRORIf the syntax of the command is correct but some incorrect parameters are used, the
strings +CME ERROR: <Err> or +CMS ERROR: <SMSErr> are sent with different error codes.
If the command has been successfully executed, the answer will be OK.
(In some cases, such as AT+CPIN? the modem will return the information requested
without OK).
[In the “Functional Examples”, and in the “A T commands description”, the characters <CR> and <CR><LF> have been intentionally omitted.]
4.2. AT COMMANDS DESCRIPTION
4.2.1. GENERAL COMMANDS
ATA Answer an incoming call
When the modem receives a call, it sets the Ring Indicator signal and sends to the DTE (e.g. PC) the RING string (or +CRING: <type> if AT+CRC=1). If the automatic answer is disabled (ATS0=0), the ATA command enables the answer to an incoming call.
Command Possible answers Action
ATA CONNECT DATA call accepted
OK VOICE call accepted
ATD Dial command
This command will dial the number entered after the A TD string. When the modem detects the carrier from the GSM base station, it will answer with the message CONNECT: at this point the data transmission starts. For further information on ATD command, see chapter “Functional Examples”.
PocketGSM AT Commands
4.3
Command Possible answers Action
ATD<str> CONNECT DATA / FAX connection is established
OK VOICE connection is established BUSY Remote device busy NO ANSWER No answer from the called number NO CARRIER Failed or refused call
<str> Description Examples
Numbers 0...9 National call ATD0123456789 + International call ATD+987654321 ; At the end of the number for the VOICE calls ATD0123456789; L Redial the last called telephone number ATDL >”text” Call to the number in the phonebook associated with the “text” indentifier
(by AT+CPBS command) ATD>”Digicom” >mem<idx> Call to the number contained in mem position n ATD>SM2 >n Call to the number stored in the position n of the current phonebook;
it can be selected with the AT+CPBS command ATD>1
ATE Echo command
When the modem receives a command, it executes the echo of the received characters. With this command it is possible to enable and disable the echo.
Command Possible answers Action
ATE0 OK Echo disabled ATE1 OK Echo enabled Default: ATE1
ATH Hang up
When the modem is on-line after the escape sequence “+++”, this command forces the modem to disconnect.
Command Possible answers Action
AT HOK The modem disconnects
PocketGSM AT Commands
4.4
ATO Back to On-Line mode
If you have to interrupt the data flow temporarily to verify the modem status or some registers without disconnecting, you can use the “+++” escape sequence. Then send the AT0 command to return to data mode.
Command Possible answers Action
ATO CONNECT Back to On-Line mode
ATQ Answer messages
This command is used to enable and disable the modem answers.
Command Possible answers Action
ATQ0 OK Answer messages enabled ATQ1 OK Answer messages disabled Default: ATQ0
ATS0 Auto answer
The S0 register allows to disable (ATS0=0) or to enable the modem autoanswer when arriving an incoming call.
Command Possible answers Action
ATS0=<n> OK / ERROR Auto answer after n rings ATS0? OK Reading of S0 register Default: ATS0=0
ATV Result code format
This command determines the modem response format: verbose code or numeric code.
Command Possible answers Action
ATV0 OK Result code display as digit ATV1 OK Result code display as words Default: ATV1
PocketGSM AT Commands
4.5
ATZ Load user profile
This command will load a user profile previously saved with the AT&W command.
Command Possible answers Action
AT ZOK Loads the user profile
AT%D Automatic dialing with DTR (C108)
This command allows to activate a DATA or VOICE autocall to the number stored in the first location of the SIM phonebook; or the automatic sending of an SMS stored in the SIM first location. The number is dialed when DTR passes from OFF to ON status; the short message is sent when DTR passes from OFF to ON status.
Command Possible answers Action
AT%D0 OK Function disabled AT%D1 OK Enables automatic dialing (DATA) AT %D1; OK Enables automatic dialing (VOICE) AT%D2 OK
Enables automatic sending of the SMS
Default: AT%D0
AT&C Data Carrier Detect (C109)
This command defines the management of the DCD (C109) on the modem serial port. If controlled (A T&C1), the DCD ON indicates the connection with a remote device. If forced (AT&C0) regardless of the status (connected/disconnected), the DCD is always ON.
Note: Data Carrier Detect can be controlled in DATA and FAX modes only.
Command Possible answers Action
AT&C0 OK Data Carrier Detect always ON AT&C1 OK Data Carrier Detect is controlled and
follows the connection status
Default: AT&C1
PocketGSM AT Commands
4.6
AT&D Data Terminal Ready (C108)
This command defines the management of the DTR (C108) on the modem serial port. The DTR comes from the DTE (e.g. PC) to the modem, for this reason the criterion can be present or absent. If absent, the modem must be configured to ignore the criterion (A T&D0). If present, the modem will accept the call only if the criterion is ON. For further information on AT&D command, see chapter “Functional Examples”.
Command Possible answers Action
AT&D0 OK DTR is ignored AT&D1 OK Modem switches from data to
command mode when DTR switches from ON to OFF.
AT&D2 OK When DTR switches from ON to OFF
the modem disconnects.
Default: AT&D2
AT&F Restore factory settings
This command is used to load the factory settings for the command listed in the table.
Command Possible answers Action
AT&F OK Loads the factory configuration
Commands restored with AT&F
QS0V %D +CBST +CLIP +CMEE +CMGF +CNMI +COPS +CR +CRC +CREG +CSMP +ECHO +ILRR +SIDET +SPEAKER +VGR +VGT
AT&S Data Set Ready (C107)
This command defines the management of DSR (C107) criterion present on the modem serial port. If controlled (A T&S1), the DSR ON indicates a connection with a remote device. When OFF it indicates the disconnection with the remote modem. If forced (AT&S0), regardless of the status (connected/disconnected), the DSR is always ON.
Note: Data Set Ready can be controlled in DATA and FAX modes only.
PocketGSM AT Commands
4.7
Command Possible responses Action
AT&S0 OK Data Set Ready always ON AT&S1 OK Data Set Ready is controlled and
follows the connection status
Default: AT&S1
AT&V Display configuration
Command Possible answers Action
AT&V0 OK Displays the current configuration AT&V1 OK Displays the stored configuration AT&V2 OK Displays the factory configuration
AT&W Save current configuration
This command saves the active configuration, in the EEPROM.
Command Possible answers Action
AT&W OK Saves the configuration
This commands can be saved with AT&W
EQ S0 V &C &D &S +CBST +CLIP +CMEE +CMGF +COPS +CR +CRC +CREG +ICF +IFC +ILRR +IPR +SIDET +SPEAKER +VGR +VGT
+++ Escape command
By sending the escape sequence, the modem switches from data to command mode. If the escape sequence is followed by the ATH command, the connection will be ended.
Note: the escape sequence works only with AT+ICF=3,4 (8N1) or =5,1 (7E1)
Command Possible answers Action
+++ OK Return to command mode
PocketGSM AT Commands
4.8
AT+CGMM Model identification
Command Possible answers Action
AT+CGMM MULTIBAND 900E 1800 Device identification
OK
AT+CGMR Modem firmware release
Command Possible answers Action
AT+CGMR 432a09gm.2D Modem firmware release
OK
AT+CGSN Product Serial Number (IMEI)
Command Possible answers Action
AT+CGSN 012345678901234 International Mobile Equipment
Identity (IMEI) of the GSM module
OK
AT+CIMI IMSI (International Mobile Subscriber Identity)
This command is used to read and identify the IMSI of the SIM card.
Command Possible answers Action
AT+CIMI 222016200858803
222 : Mobile Country Code (222 = Italy)
OK 01 : Mobile Network Code (01 = Tim)
6200858803 : Mobile Subscriber Identification Number
AT+IPR Fixed DTE rate
This command specifies the data rate at which the modem will accept data from the DTE (e.g. PC); the answer messages from the modem will use the same speed.
PocketGSM AT Commands
4.9
Command Possible answers Action
AT+IPR=<speed> OK / ERROR Set the interface rate AT+IPR? +IPR: 9600 Shows the current speed AT+IPR=? +IPR: (0,2400,…) Shows the available speeds Default: AT+IPR=9600 (the PocketGSM/GPRS AT+IPR=115200)
<speed> Description
0Autobaud enabled: the modem automatically detects the speed, monitoring
the received AT command.
From 300 to 115200 bit/s Interface speed set at one of the following values: 300, 600, 1200, 2400, 4800,
9600, 19200, 38400, 57600, 115200 bit/s.
AT+ICF Data format
This command allows to select the data synchronous format, the modem will use to accept data from the DTE (e.g. PC); the modem answer messages will use the same format.
Note: a data format different from 8N1 ( AT+ICF=3,4) disables the autobaud (AT+IPR=0) if active. If the
data format is set at 8N1, the autobaud is automatically enabled.
Comando Possibili risposte Azione
AT+ICF=<format>,<parity> OK / ERROR Set data format AT+ICF? +ICF: 5,1 Shows the current settings AT+ICF=? +ICF: (1-6), (0-4) Shows the available settings Default: AT+ICF=3,4
<format> Data Format
1 Data: 8bit; Parity: 0bit (None); Stop: 2bit 2 Data: 8bit; Parity: 1bit; Stop: 1bit 3 Data: 8bit; Parity: 0bit (None); Stop: 1bit 4 Data: 7bit; Parity: 0bit (None); Stop: 2bit 5 Data: 7bit; Parity: 1bit; Stop: 1bit 6 Data: 7bit; Parity: 0bit (None); Stop: 1bit
PocketGSM AT Commands
4.10
<parity> Parity Format
0 Odd 1Even 2Mark 3 Space 4 None
Examples
AT+ICF=3,4 Data: 8bit; Parity: None; Stop: 1bit AT+ICF=5,0 Data: 7bit; Parity: Odd; Stop: 1bit AT+ICF=5,1 Data: 7bit; Parity: Even; Stop: 1bit
AT+IFC Flow control
This command is used to set the flow control to be used. For further information on the AT+IFC command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+IFC=0,0 OK Flow control disabled AT+IFC=2,2 OK
Enables the Hardware flow control (RTS/CTS) AT+IFC? +IFC: 2,2 Shows the current flow control AT+IFC=? +IFC: (0,2), (0,2) Shows the available values Default: AT+IFC=2,2
AT+ILRR Interface speed report
This command gives a report for the serial port speed, before the connection message.
Command Possible answers Action
AT+ILRR=0 OK Report disabled AT+ILRR=1 OK Report enabled AT+ILRR? +ILRR: 0 Shows the current settings AT+ILRR=? +ILRR: (0,1) Shows the available settings Default: AT+ILRR=0
PocketGSM AT Commands
4.11
4.2.2. 07.07 GSM COMMANDS
AT+CBST Line Speed Setting
This command is used to select the line speed and the protocol for the DATA calls. If Multistandard is selected:
when transmitting, the modem sets with the maximum speed available on the GSM
network (for Italy V.32 9600 bit/s)
when receiving the modem recognizes the speed and the protocol suggested from the
remote device.
For further information on AT+CBST command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CBST=<speed>,<mode>,<ce> OK / ERROR Sets the speed and the protocol AT+CBST? +CBST: 0,0,1 Shows the current settings AT+CBST=? +CBST: (0-7…), (0),… Shows the available settings Default: AT+CBST=0,0,1
<speed> <mode> <ce> Description
001Multistandard 101V.21 300 bit/s No Transparent 201V.22 1200 bit/s No Transparent 401V.22 bis 2400 bit/s No Transparent 601V.32 4800 bit/s No Transparent
701V.32 9600 bit/s No Transparent 66 0 1 V.110 1200 bit/s No Transparent 68 0 1 V.110 2400 bit/s No Transparent 70 0 1 V.110 4800 bit/s No Transparent 71 0 1 V.110 9600 bit/s No Transparent
PocketGSM AT Commands
4.12
AT+CEER Extended error report
This command gives a report with the cause of the last disconnection. (See Appendix A for the error codes).
Command Possible answers Action
AT+CEER +CEER: Error <err> Cause of last disconnection
OK
AT+CFUN Modem Restart
The AT+CFUN=1 command is used for a software reset of the modem; this means also a new registration to the GSM network. Before carrying out a reset, we suggest to save the current configuration (AT&W). The AT+CFUN=0 or AT+CPOF commands are used to switch the modem in Stand-by mode: during this phase the modem is disconnected from the GSM network. To exit from the Stand-by mode use the AT+CFUN=1 command.
Command Possible answers Action
AT+CFUN=0 (o AT+CPOF) OK Modem in Stand-by AT+CFUN=1 OK Modem restart
AT+CLIP Calling Line Identification (CLI)
When receiving a call, this command allows to identify the calling number. With the command AT+CLIP? It is possible to obtain the status of the “CLIP Service” in the network. The caller ID is displayed after any RING message.
Command Possible answers Action
AT+CLIP=0 OK CLI displaying is disabled AT+CLIP=1 OK CLI displaying id enabled AT+CLIP? +CLIP: 0,<n> Shows the current settings and the
CLIP Service state AT+CLIP=? +CLIP: (0,1) Shows the available settings Default: AT+CLIP=0
PocketGSM AT Commands
4.13
<n> CLIP Service status in the network (reading only)
0 CLIP Service not available 1 CLIP Service available 2 Service Status: Unknown (no network…)
AT+CLIR Calling Line Identification restriction (CLI)
This command allows to hide the Calling Line Identification to the remote device.
Note: Independently from the setting of AT+CLIR, it is possible to add an “i” small letter at the end of
the calling string to present the CLI to the remote user (e.g. ATD0123456789i); or the letter “I” capital letter to hide the CLI (e.g. ADT0123456789I).
Command Possible answers Action
AT+CLIR=0 OK CLI presentation depends on the
CLIR Sevice status. AT+CLIR=1 OK CLI is not displayed AT+CLIR=2 OK CLI is displayed AT+CLIR? +CLIR: 0,<n> Shows the current settings and CLIR
Service status AT+CLIR=? +CLIR: (0-2) Shows the available settings Default: AT+CLIR=0
<n> CLIR Service status in the network (reading only)
0 CLIR Service not available 1 CLIR Service available 2 Service Status: Unknown (no network…) 3 CLIR Service temporary suspended 4 CLIR Service temporary available
AT+CMEE Report Mobile Equipment errors
This command enables the report +CME ERROR: <err> and +CMS ERROR <SMSerr> with the indication of the error code, instead of a generic answer. (See Appendix A for error codes).
PocketGSM AT Commands
4.14
Command Possible answers Action
AT+CMEE=0 OK Report disabled AT+CMEE=1 OK Report enabled AT+CMEE? +CMEE: 0 Shows the current settings Default: AT+CMEE=0
AT+COPS Operator selection
PocketGSM can automatically detect the GSM operator both directly and in roaming. With this command you can check the current provider . Moreover, in extreme cases it is possible to force the registration to a specific provider: in this case check the registration status with the command AT+CREG. With the command AT+COPS=? it is possible to verify the situation of the operators: 0 unknown operator; 1 operator is available; 2 current operator; 3 the operator is forbidden and cannot be selected. For further information on AT+COPS command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+COPS=<mode>, OK / ERROR Selects the operator <format>,<oper> AT+COPS? +COPS: 0,2,22201 Shows the current operator AT+COPS=? +COPS: (2,"I TIM”,”TIM”,”22201”)… Shows the available operators Default: AT+COPS=0,2
<mode> Registration mode
0 Automatic (<oper> is ignored) 1 Manual 4 If manual selection fails, automatic mode is entered
<format> Operator format
0 Long alphanumeric format (e.g. I OMNITEL) 1 Short alphanumeric format (e.g. OMNI) 2 Numeric format (e.g. 22210)
<oper> Operator identifier
PocketGSM AT Commands
4.15
AT+CPIN Enter PIN code
This command is used to enter the PIN and PUK codes. If the SIM card, used with Pocket GSM, has the PIN code enabled, it will be necessary to insert it each time you turn the modem on, to permit the registration to the GSM network. The PIN and the PUK code management can be carried out with any mobile phone. For further information on the PIN code management, see chapter “Functional Examples”.
Attention: If the PIN code is three times wrongly inserted, the SIM card is blocked. To unblock, insert
the PUK code and the new PIN code. (e.g. AT+CPIN=12345678,1234).
Command Possible answers Action
AT+CPIN=<pin> OK / ERROR PIN code insertion AT+CPIN=<puk>,<pin> OK / ERROR PUK and PIN insertion AT+CPIN? <status> Shows the SIM status
<status> Description
+CPIN: READY PIN code is present: SIM ready +CPIN: SIM PIN PIN is required +CPIN: SIM PUK PUK is required +CPIN: SIM PIN2 PIN2 is required ERROR SIM card reading failed
AT+CR Connection report
This command enables the report +CR: <type> that identifies the current connection. The report is given before the connection message.
Command Possible answers Action
AT+CR=0 OK Report disabled AT+CR=1 OK Report enabled AT+CR? +CR: 0 Shows the current settings Default: AT+CR=0
PocketGSM AT Commands
4.16
AT+CRC Cellular Result Code
This command enables the report +CRING: <type>, instead of the traditional RING message.
Command Possible answers Action
AT+CRC=0 OK Report disabled AT+CRC=1 OK Report enabled AT+CRC? +CRC: 0 Shows current settings Default: AT+CRC=0
AT+CREG GSM Network registration
This command enables the automatic report to any change of status during the modem registration to the GSM network. For further information on AT+CREG command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CREG=<n> OK Report enabled or disabled AT+CREG? +CREG: <n>,<stat>,[<lac>,<ci>] Shows the current registration status
of the GSM modem to the network AT+CREG=? +CREG: (0-2) Shows the available settings Default: AT+CREG=0
<n> Report status
0 Report disabled 1 Report enabled with +CREG: <stat> 2 Report enabled with +CREG: <stat>,<lac>,<ci>
<stat> Registration status
0 Modem not registered, PocketGSM is not currently searching for a new operator 1 Modem registered with the same operator of the SIM card 2 Modem not registered, PocketGSM is searching for a new operator 3 Registration denied 4 Registered at an unknown network 5 Modem registered in roaming
PocketGSM AT Commands
4.17
<lac> Location Area Code in hexadecimal format (e.g. “00C3” is the same as “195”
in decimal)
<ci> Cell ID in hexadecimal format
AT+CSQ GSM Signal Quality
This command is used to control the GSM quality signal. For further information on AT+CSQ command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CSQ +CSQ: <rssi>,<ber> Reads the signal power and ber
OK
<rssi> Reception level
0-113 dBm or less 1-111 dBm 2…30 -109…-53 dBm 31 -51 dBm or greater 99 unknown or not detectable
Note: each unit corresponds to 2 dBm
<ber> bit error rate
0 ber < 0,2% 1 0,2% < ber < 0,4% 2 0,4% < ber < 0,8% 3 0,8% < ber < 1,6% 4 1,6% < ber < 3,2% 5 3,2% < ber < 6,4% 6 6,4% < ber < 12,8% 7 ber > 12,8% 99 unknown or not detectable
PocketGSM AT Commands
4.18
4.2.3. PHONEBOOK COMMANDS
AT+CPBS Select Phonebook
This command selects the memory to be used for the phonebook.
Command Possible answers Action
AT+CPBS=<”storage”> OK / ERROR
Select the current phonebook memory AT+CPBS? +CPBS: <“storage”>,<used>, and the available memory
<total>
Default: AT+CPBS=”ME”
<”storage”> Phonebook
“ME” Modem phonebook (250 memory locations) “SM” SIM phonebook (the number of locations depends on the SIM) “LD” Last 10 dialled numbers “RC” Last 10 received calls
<used> Locations used <total> Total locations
AT+CPBW Write and cancel a telephone number
This command allows to write or to delete a telephone number in the current phonebook. It can be selected with the command AT+CPBS.
Command Possible answers Action
AT+CPBW=<index>,<”number”>, OK / ERROR Insert the telephone number <type>,<”text”> AT+CPBW=<index> OK Cancel the telephone number AT+CPBW=? +CPBW: (lista <index>), Shows the information on the
<ilength>,(lista <type>), memory of the selected phonebook <tlength>
PocketGSM AT Commands
4.19
<index> Location where to save the telephone number <”number”> telephone number <type> 145 if <”number”> includes the “+” character in the international prefix
129 if <”number”> does not include the “+” character in the international prefix
Note: this parameter can be omitted.
<”text”> Mnemonic name of the telephone number <ilength> Max length for <”number”> <tlength> Max length for <”text”>
Examples
AT+CPBW=1,”+39320xxxxxxx”,,”Ufficio Roma” Location 1 inserted AT+CPBW=2,”320xxxxxxx”,129,”Ufficio Napoli” Location 2 inserted AT+CPBW=3,”320xxxxxxx”,,”Casa” Location 3 inserted AT+CPBW=3 Location 3 cancelled
AT+CPBR Read a telephone number
This command is used to read a telephone number in the current phonebook and can be selected with the command AT+CPBS.
Command Possible answers Action
AT+CPBR=<idx1>,<idx2> +CPBR: Reads the numbers in the phonebook
<idx1>,<number>,<type>,<text> from <idx1> to <idx2> … <idx2>,<number>,<type>,<text>
<idx1> e <idx2> Location range
AT+CPBR=1 Read entry 1 AT+CPBR=1,10 Read entries from 1 to 10
PocketGSM AT Commands
4.20
AT+CPBF Search for a telephone number (knowing the stored text)
This command is used to find a telephone number inside the phonebook, knowing the associated identifier (e.g. starting with D…).
Command Possible answers Action
AT+CPBF=<”text”> +CPBF: Displays the telephone numbers
<idx1>,<number>,<type>,<text> with the specified <”text”> identifier <idx2>,<number>,<type>,<text>
AT+CPBP Search for a telephone number (knowing the number)
This command is used to find an identifier associated with a telephone number inside the phonebook, knowing the number itself.
Command Possible answers Action
AT+CPBP=<”number”> +CPBP: Displays the identifier
<idx1>,<number>,<type>,<text>
associated with the specified <”number”>
4.2.4. VOICE COMMANDS
PocketGSM can call another voice device with the ATD<number>; command: e.g.ATD0123456789;
When the remote device answers the call, PocketGSM will show the OK message. For the voice functionality, PocketGSM is equipped with a double-ended audio interface
on RJ6 female connector with the same Pin-out of a standard telephone handset. The interface can be connected both to a handset and to a loud speaking telephone.
In order to improve the quality of the voice it will be necessary to modify some parameters to delete the echo, the noise, etc. In this paragraph you can find the commands necessary to improve the voice quality. To save the configuration use the AT&W command.
PocketGSM AT Commands
4.21
AT+SPEAKER Speaker and Microphone selection
With a single command, you can set the factory parameters of the commands:
AT+VGR
,
AT+VGT, etc
; in this way you can quickly improve the quality of the voice.
Note: Act also on AT+VGR, AT+CGT, commands to improve the quality of the voice. If there is noise
you could connect an external antenna with extension cable.
Command Possible answers Action
AT+SPEAKER=0 OK Configuration for “telephone handset” AT+SPEAKER? +SPEAKER: 0 Shows the current settings Default: AT+SPEAKER=0
AT+CMUT Mute Control
During a voice connection, this command disables the microphone while the speaker is always active.
Command Possible answers Action
AT+CMUT=0 OK Microphone enabled AT+CMUT=1 OK Microphone disabled (MUTE) AT+CMUT? +CMUT: 0 Shows the current settings Default: AT+CMUT=0
AT+VTS Send DTMF tones
During a voice connection, this command sends the DTMF tones, to allow the surfing in vocal servers.
Note: wait always the OK, before sending another tone.
Command Possible answers Action
AT+VTS=<DTMF> OK / ERROR Send the specified DTMF tone
<DTMF> DTMF tones
0…9 Numbers from 0 to 9 # # character * Asterisk character A…D A, B, C, D characters
PocketGSM AT Commands
4.22
AT+VTD Length of the DTMF tone
This command is used to increase or reduce the length of the DTMF tone, sent with the command A T+VTS.
Command Possible answers Action
AT+VTD=<time> OK / ERROR Sets the length of the DTMF tone AT+VTD? +VTD: 1 Shows the current settings Default: AT+VTD=1
<time> DTMF tones
1 100 milliseconds 2 200 milliseconds …… 10 1 second ……
AT+VGR Speaker gain control
This command is used to set the receiving level of the speaker. (See Appendix A for the values of the speaker gain).
Command Possible answers Action
AT+VGR=<val> OK / ERROR Sets the receiving level of the speaker AT+VGR? +VGR: 64 Shows the current settings
AT+VGT Microphone gain control
This command is used to set the transmission level of the microphone. (See Appendix A for the values of the microphone gain).
Command Possible answers Action
AT+VGT=<val> OK / ERROR Sets the transmission level of
the microphone AT+VGT? +VGT: 64 Shows the current settings
PocketGSM AT Commands
4.23
AT+ECHO Echo cancellation
This command enables the echo cancellation for voice calls in small rooms. It could be necessary to act on the (AT+VGT) and (AT+VGR) commands for a best voice quality.
Command Possible answers Action
AT+ECHO=<mode>,<algold> OK / ERROR Sets the echo cancellation AT+ECHO? +ECHO: <status>,<algold> Shows the current settings
<mode> Mode
0 Echo disabled 1 Echo enabled
Note: you can enable/disable the echo cancellation during a call without restarting the modem if you
don’t change the Algorithm.
<algold> Algorithm
1 Echo cancellation 1 3 Echo cancellation 3
<status> Status
0 Eco disabled 1 Eco enabled for “telephone handset” 2 Eco enabled for “loud speaking telephone” 3 Module reset
AT+SIDET SideTone Control
This command is used to set the echo level of the voice in the speaker (to have a microphone feedback in the speaker).
Command Possible answers Action
AT+SIDET=0,<val> OK / ERROR SideTone disabled AT+SIDET=1,<val> OK / ERROR SideTone enabled AT+SIDET? +SIDET: 1,1 Shows the current settings
PocketGSM AT Commands
4.24
<val> Description
00 db 1 -6db 2 -12db 3 -18db
AT+VIP Voice parameters Initialization
This command allows to restore the factory settings for the voice parameters from EEPROM. These voice parameters include: A T+SPEAKER; A T+CMUT; AT+VGR; A T+VGT AT+ECHO; AT+SIDET.
Command Possible answers Action
AT+VIP=1 OK Restores the factory settings
4.2.5. SMS CONTROL COMMANDS (GSM 07.05)
AT+CMGF Messages format
This command is used to define the SMS format (Short Message Service). For further information on AT+CMGF command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CMGF=0 OK SMS in PDU mode AT+CMGF=1 OK SMS in Text mode AT+CMGF? +CMGF: 1 Shows the current settings
AT+CSCA Service Center Number
This command allows to set the Service Center number in the SIM card memory . An error will occur if trying to send an SMS using a wrong number of the Services Center. Verify with your GSM Operator the number of the Service Center. For further information on AT+CSCA command, see the chapter “Functional Examples”.
PocketGSM AT Commands
4.25
Command Possible answers Action
AT+CSCA? +CSCA: “Service Center Address” Displays the Service Center number AT+CSCA=“ Service Center OK Inserts the Service Center number Address”
AT+CSMP Period of Validity for the SMS
This command is used to define period of validity of the message in the Services Center .
Command Possible answers Action
AT+CSMP=<fo>,<vp>, OK / ERROR Sets the period of validity <pid>,<dcs> AT+CSMP? +CSMP: Shows the current settings
<fo>,<vp>,<pid>,<dcs>
Default: AT+CSMP=1,167
<fo> Reserved (value is 1, do not modify) <vp> Period of validity
“11“ 1 hour “71“ 6 hours “167“ 24 hours “173” 1 week “255” Higher
<pid> Reserved <dcs> Reserved
AT+CSAS Save settings
This command allows to save the settings of the following commands: AT+CSCA, A T+CSMP and A T+CNMI. For further information on AT+CSAS command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CSAS OK Save the current settings
PocketGSM AT Commands
4.26
AT+CRES Restore settings
This command restores the setting of the following commands: AT+CSCA, A T+CSMP and AT+CNMI.
Command Possible answers Action
AT+CRES OK Restore the saved settings
AT+CNMI Indication of New incoming message
This command displays a report when a new SMS arrives. For further information on AT+CNMI command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CNMI=<mode>,<mt> OK / ERROR Select the report display mode AT+CNMI? +CNMI: <mode>,<mt> Shows the current settings Default: AT+CNMI=0,1
<mode> Display Mode
2 If the modem is Off-line, the message will be displayed on the DTE in <mt>
format. If the modem is On-line, the message will be displayed on the DTE in <mt> format at the end of the connection.
0,1,3 Equal to 2
<mt> Report format
0 No report 1 Report with format:
+CMTI: <mem>,<index>
2 Report with format:
+CMT:<oa>,[<alpha>],<scts>[,<tooa>,<fo>,<pid>,<dcs>,<sca>,<tosca>,<lengh>] <data>
PocketGSM AT Commands
4.27
Examples
1) AT+CNMI=2,1
Report: +CMTI: "SM",2 Description: The received SMS has been stored in the location 2 of the SIM memory.
2) AT+CNMI=2,2
Report: +CMT: "+393217654321",,"01/01/75,12:06:14+00" First SMS message with PocketGSM
Description: the received SMS is displayed directly on the DTE.
AT+CMGD Delete messages
This command is used to delete the SMS messages stored in the SIM memory. For further information on AT+CMGD command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CMGD=<index>,<deflag> OK / ERROR Cancella i messaggi SMS
<index> Memory index <deflag> Delete method
0 Delete the message in the <index> position.
If <deflag> value is omitted, it will be equal at 0.
1 Delete all the received and read messages: “REC READ”. The <index> value
is ignored.
2 Delete all the received, read, saved and sent messages: “REC READ” and
“STO SENT”. The <index> value is ignored.
3 Delete all the received, read, saved, sent and unsent messages: “REC READ”,
“STO SENT” and “STO UNSENT”. The <index> value is ignored.
4 Delete all messages. The <index> value is ignored.
PocketGSM AT Commands
4.28
AT+CMGL Messages List
This command displays the list of the SMS messages stored in the SIM memory. For further information on AT+CMGL command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CMGL=<stat> OK / ERROR Shows the list of SMS
<stat> Display method
Text mode PDU mode Description
“REC UNREAD” 0 Displays all the received unread messages “REC READ” 1 Displays all the received and read messages “STO UNSENT” 2 Displays all the stored unsent messages “STO SENT” 3 Displays all the stored sent messages “ALL” 4 Display all the messages
AT+CMGR Display message
This command allows to display a specific SMS stored in the SIM memory For further information on AT+CMGR command, see the chapter “Functional Examples”.
Command Possible answers Action
AT+CMGR=<index> OK Shows the message
AT+CMGS Send SMS
This command is used to send a SMS message in Text mode. For further information on AT+CMGS command, see the chapter “Functional Examples”.
Examples Command:AT+CMGS=”+393217654321”<enter> Answer:> Text: First SMS message with PocketGSM<ctrl z> Answer: +CMGS: <sms index>
OK
PocketGSM AT Commands
4.29
Compose your message, press <ctrl z> (Hex =1A). To cancel the procedure, press <esc> (Hex = 1B). In this example the message “First SMS message with Pocket GSM” is sent to number +393217654321.
AT+CMSS Send a stored SMS
This command is used to send a previously stored SMS message in Text format. Check the memory location with the AT+CMGL=”ALL” command.
Command Possible answers Action
AT+CMSS=<index> OK Sends the SMS message stored in <index> location
AT+CMGW Store an SMS
This command is used to store an SMS message in text format into the SIM memory.
Examples Command:AT+CMGW=”+393217654321”<enter>
Answer:> Text: First SMS message with PocketGSM<ctrl z> Answer: +CMGW: <sms index>
OK
Compose your message, press <ctrl z> (Hex =1A). To cancel the procedure, press <esc> (Hex = 1B). In this example the message “First SMS message with Pocket GSM” is stored.
PocketGSM AT Commands
4.30
4.2.6. GPIO COMMANDS (GENERAL PURPOSE INPUT OUTPUT)
Besides the functionalities for the DATA, SMS, FAX and VOICE management, Pocket GSM can also read some inputs contacts and control some output relays. Thanks to this characteristic, you will be able to build a complete application using a single device:
you can detect the status change of an input and send an SMS alarm;you can receive a specific SMS and control a output relay.
In this paragraph you find the characteristics of the General Purpose Input/Output (GPIO) and the AT commands to control them.
MINIFIT CONNECTOR
The inputs, the outputs and the power supply are managed through a Minifit connector (12 pin):
Frontal view PIN Description Wire color
(1)
1 OUTPUT 2 [Open Collector] (GPO2) Yellow 2 OUTPUT 1 [Open Collector] (GPO1) Green 3 INPUT DIGITALE 4 (GPIO5) Blue 4 INPUT DIGITALE 3 (GPIO4) Light Blue 5 INPUT DIGITALE 2 (GPIO0) Brown 6 INPUT DIGITALE 1 (GPI3) Violet 7 N.C. White 8 N.C. Grey
9 from +5 to +32Vdc Red 10 GND Black 11 INPUT ANALOGICO 2 (ADC2) Pink 12 INPUT ANALOGICO 1 (ADC1) Orange
(1)
If you use the complete connector with 12 cables.
PocketGSM AT Commands
4.31
Power on PocketGSM connecting the cable with the correct polarity:
pin 9: positive [from +5 to +32Vdc] pin 10: negative [GND]
The modem has a special protection in case you accidentally invert the polarity.
CHARACTERISTICS OF GPIO CONTACTS
PocketGSM supports:
4 digital inputs (two logical states: ON/OFF);2 analog inputs;2 output open-collector.
Digital Inputs
Two status are supported for each input: open or closed to ground. It is necessary connect only a free contact (without voltage) between the input pin (pin 6, 5, 4, 3) and the ground pin (pin 10).
DIGITAL INPUT CHARACTERISTICS
Permitted status:
Input open Input closed to ground (GND)
Analog Inputs
Two Analog to Digital Converter are available on the PocketGSM. These converters have a 10 bit resolution, ranging from 0 to 28 Vdc.
ANALOG INPUT CHARACTERISTICS
Resolution 10bit Input signal range From 0 to 28Vdc
To read the value, use AT+ADC command. Send AT+ADC=1 command and read the value with AT+ADC? command.
PocketGSM AT Commands
4.32
Command Possible answers Action
AT+ADC? +ADC: <ADC3>,<ADC2>,<ADC1> Shows the current value
Ignore the first value <ADC3>; read only ADC1 and ADC2. This command gets the (DC level * 1024) of ADC1 and ADC2.
Output
The two outputs of PocketGSM (old and new version), manage the devices that can be activated and deactivated through a switch. (e.g. Lamp, Sound, Logic Port, etc...).
To connect your devices, check the Transistor characteristics: max collector-emitter voltage (Vce) and collector current (Ic):
Vce (max): 45V Ic (max): 500mA
PocketGSM AT Commands
4.33
Connection Examples
If you want to manage a simple led (1,5V – 20mA), with a 12V power supply, you must add a pull-up resistor (470) to limit the current.
If you want to manage a lamp with 230V power supply, you can connect an external rele and a diode (1N4007 or 1N4148) to protect the transistor inside the PocketGSM
Note: if you use a cable to connect the rele, connect the diode close to the pin1 or pin2 of the PocketGSM to protect the transistor inside the PocketGSM.
PocketGSM AT Commands
4.34
AT+WIOM Input/Output Configuration
This command allows to configure the 6 contacts I/O. If they are configures as Output, it is possible to establish the default status (Reset or Set) at every restart.
Command Possible answers Action
AT+WIOM=<IODir>,<IOVal> OK / ERROR GPIO configured AT+WIOM? +WIOM: <IODir>,<IOVal> Shows the current settings
<IODir> GPIO direction (Input or Output) (bit mapped register)
bit 0 0 = GPIO0 configured as Input
1 = GPIO0 configured as Output bit 1 1 = GPO1 configured as Output bit 2 1 = GPO2 onfigured as Output bit 3 0 = GPI3 configured as Input bit 4 0 = GPIO4 configured as Input
1 = GPIO4 configured as Output bit 5 0 = GPIO5 configured as Input
1 = GPIO5 configured as Output bit 6-7 Not used
<IOVal> Output default value after reset (bit mapped register)
0 OUTPUT1 Reset
OUTPUT2 Reset 2 OUTPUT1 Set
OUTPUT2 Reset 4 OUTPUT1 Reset
OUTPUT2 Set 6 OUTPUT1 Set
OUTPUT2 Set
Remember:
The Open Collector outputs are usually OPEN.
PocketGSM AT Commands
4.35
Possible settings AT+WIOM=6,0 GPIO0 INPUT2
GPO1 OUTPUT1 (initial state: Reset) GPO2 OUTPUT2 (initial state: Reset) GPI3 INPUT1 GPIO4 INPUT3 GPIO5 INPUT4
AT+WIOM=6,2 GPIO0 INPUT2
GPO1 OUTPUT1 (initial state: Set) GPO2 OUTPUT2 (initial state: Reset) GPI3 INPUT1 GPIO4 INPUT3 GPIO5 INPUT4
AT+WIOM=6,4 GPIO0 INPUT2
GPO1 OUTPUT1 (initial state: Reset) GPO2 OUTPUT2 (initial state: Set) GPI3 INPUT1 GPIO4 INPUT3 GPIO5 INPUT4
AT+WIOM=6,6 GPIO0 INPUT2
GPO1 OUTPUT1 (initial state: Set) GPO2 OUTPUT2 (initial state: Set) GPI3 INPUT1 GPIO4 INPUT3 GPIO5 INPUT4
PocketGSM AT Commands
4.36
AT+WIOR Read GPIO value
This command reads the current state (Reset or Set) of an Input. It is not possible to read the state of an Output. Trying to read an Output status will cause an ERROR.
Command Possible answers Action
AT+WIOR=<Index> +WIOR: <Val> Reads the current status
<Index> Digital Input index (values: 0, 3, 4, 5)
AT+WIOR=3 Reads the Digital Input 1 status AT+WIOR=0 Reads the Digital Input 2 status AT+WIOR=4 Reads the Digital Input 3 status AT+WIOR=5 Reads the Digital Input 4 status
<Val>Digital Input state
0 Reset 1 Set
AT+WIOW Write GPIO value
This command writes the state (Reset o Set) of an Output. It is not possible to write the state of an Input. Trying to write an Input status will cause an ERROR. By default (after a power off/on) the Output contact is set by AT+WIOM command.
Command Possible answers Action
AT+WIOW=<Index>,<Val> OK / ERROR Writes the output status
<Index> Output index (values 1, 2)
AT+WIOW=1,<Val> Writes the Output 1 status AT+WIOW=2, <Val> Writes the Output 2 status
<Val> GPIO state
0 Reset 1 Set
PocketGSM AT Commands
4.37
4.2.7. GPRS COMMANDS (GSM 07.07)
The GPRS functionality is available only in some versions of PocketGSM. If available for the best use of the GPRS function, we suggest to set AT+IPR=0 (autobaud) and to save the configuration with AT&W command. After the driver installation, select in driver properties the interface speed at 115200.
GPRS activation
Verify with your GSM Operator the GPRS activation.
GPRS configuration
To configure PocketGSM for GPRS connection, you must send the AT+CGDCONT to se the access profile to the service. Check with the GSM Operator your access profile. AT+CGDCONT=1,”IP”,”APN” You can insert the A T+CGDCONT command in the Additional string in the driver properties or send the command by HyperTerminal and save it with AT&W command.
Connection
Now you are ready for a Dial-Up connection and a GPRS connection, using the drivers. Verify with your GSM Operator the GPRS parameters (e.g. User ID, password, phone number).
For further technical information and for the driver, see the Support area on our web site www.digicom.it,
or send a e-mail to support@digicom.it
PocketGSM Appendix A
A.1
APPENDIX A
A1. (+CEER: Error <err>) Report Error Codes
<err> Description
1 Unassigned (unallocated) number 3 No route to destination 6 Channel unacceptable 8 Operator determined barring 16 Normal call clearing 17 User busy 18 No user responding 19 User alerting, no answer 21 Call rejected 22 Number changed 26 Non selected user clearing 27 Destination out of order 28 Invalid number format (incomplete number) 29 Facility rejected 30 Response to STATUS ENQUIRY 31 Normal, unspecified 34 No circuit/channel available 38 Network out of order 41 Temporary failure 42 Switching equipment congestion 43 Access information discarded 44 Requested circuit/channel not available 47 Resources unavailable, unspecified 49 Quality of service unavailable 50 Requested facility not subscribed 55 Incoming calls barred with in the CUG 57 Bearer capability not authorized 58 Bearer capability not presently available
A
PocketGSM Appendix A
A.2
63 Service or option not available, unspecified 65 Bearer service not implemented 68 ACM equal to or greater than ACMmax 69 Requested facility not implemented 70 Only restricted digital information bearer capability is available 79 Service or option not implemented, unspecified 81 Invalid transaction identifier value 87 User not member of CUG 88 Incompatible destination 91 Invalid transit network selection 95 Semantically incorrect message 96 Invalid mandatory information 97 Message type non-existent or not implemented 98 Message type not compatible with protocol state 99 Information element non-existent or not implemented 100 Conditional IE error 101 Message not compatible with protocol state 102 Recovery on timer expiry 111 Protocol error, unspecified 127 Interworking, unspecified 240 FDN is active and number is not in FDN 241 Call operation not allowed 252 Call barring on outgoing calls 253 Call barring on incoming calls 254 Call impossible 255 Lower layer failure
Note: All other values in the range 0 to 31 shall be treated as cause 31
All other values in the range 32 to 47 shall be treated as cause 47 All other values in the range 48 to 63 shall be treated as cause 63 All other values in the range 64 to 79 shall be treated as cause 79 All other values in the range 80 to 95 shall be treated as cause 95 All other values in the range 96 to 111 shall be treated as cause 111 All other values in the range 112 to 127 shall be treated as cause 127
PocketGSM Appendix A
A.3
A.2. (+CME ERROR: <error>) Report Error Codes
<error> Description
3 Operation not allowed 4 Operation not supported 5 PH-SIM PIN required 10 SIM not inserted 11 SIM PIN required 12 SIM PUK required 13 SIM failure 16 Incorrect password 20 Memory full 21 Invalid index 22 Not found 24 Text string too long 26 Dial string too long 30 No network service 32 Network not allowed – emergency calls only 40 Network personalisation PIN Required (Network lock)
PocketGSM Appendix A
A.4
A.2.1. (+CMS ERROR: <SMSerror>) Report Error Codes
<SMSerror> Description
Da 1 a 127 Error cause values from the GSM recommendation 04.11 Annex E-2 301 SMS service of ME reserved +CSMS 302 Operation not allowed All SMS commands 303 Operation not supported All SMS commands 304 Invalid PDU mode parameter 305 Invalid text mode parameter 310 SIM not inserted All SMS commands 311 SIM PIN required All SMS commands 312 PH-SIM PIN required All SMS commands 313 SIM failure All SMS commands 316 SIM PUK required All SMS commands 317 SIM PIN2 required All SMS commands 318 SIM PUK2 required All SMS commands 321 Invalid memory index 322 SIM memory full 330 SC address unknown 340 No +CNMA acknowledgement expected +CNMA
PocketGSM Appendix A
A.5
A.3. Values of the speaker gain (AT+VGR=<val>)
<val> Speaker gain
0 – 15 +6 db 16 – 31 +4 db 32 – 47 +2 db 48 – 63 +0 db 64 – 79 -2 db 80 – 95 -4 db
96 – 111 -6 db 112 – 127 -8 db 128 – 143 -10 db 144 – 159 -12 db 160 – 175 -14 db 176 – 191 -16 db 192 – 207 -18 db 208 – 223 -20 db 224 – 239 -22 db 240 – 255 -24 db
PocketGSM Appendix A
A.6
A.3.1. Values of the Microphone transmission (AT+VGT=<val>)
Values for Values for
“telephone handset” “loud speaking telephone”
<val> Gain <val> Gain
0 – 31 +30 db 0 +0 db 32 – 63 +33 db 1 +0,5 db 64 – 95 +36 db 2 +1 db
96 – 127 +39 db 3 +1,5 db 128 – 159 +42 db … 160 – 191 +45 db 19 9,5 db 192 – 223 +48 db 20 10 db 224 – 255 +51 db 21 – 60 30 db
61 30,5 db 62 31 db
……
101 50,5 db 102 – 127 51 db 128 – 243 -6,5 db
244 -6 db
245 -5,5 db
246 -5 db
……
255 -0,5 db
ITALY
21010 Cardano al Campo VA
via A. Volta 39
Loading...