A76XX Series - Dual SIM - Application Note - V1.02

Download as pdf or txt
Download as pdf or txt
You are on page 1of 20

A76XX Series_

Dual SIM _Application Note


LTE Module

SIMCom Wireless Solutions Limited


SIMCom Headquarters Building, Building 3, No. 289 Linhong
Road, Changning District, Shanghai P.R. China
Tel:86-21-31575100
Support:[email protected]
www.simcom.com
A76XX Series_Dual SIM_Application Note_V1.02

Name: A76XX Series_Dual SIM_Application Note


Version: 1.02
Date: 2023.06.13
Status: Released

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 SIMCOM WIRELESS SOLUTIONS LIMITED COPYING, TO OTHERS AND USING THIS DOCUMENT,
ARE FORBIDDEN WITHOUT EXPRESS AUTHORITY BY SIMCOM. OFFENDERS ARE LIABLE TO THE
PAYMENT OF INDEMNIFICATIONS. ALL RIGHTS RESERVED BY SIMCOM IN THE PROPRIETARY
TECHNICAL INFORMATION, INCLUDING BUT NOT LIMITED TO REGISTRATION GRANTING OF A
PATENT, A UTILITY MODEL OR DESIGN. ALL SPECIFICATION SUPPLIED HEREIN ARE SUBJECT TO
CHANGE WITHOUT NOTICE AT ANY TIME.

SIMCom Wireless Solutions Limited


SIMCom Headquarters Building, Building 3, No. 289 Linhong Road, Changning District, Shanghai P.R.
China
Tel: +86 21 31575100
Email: [email protected]

For more information, please visit:


https://www.simcom.com/technical_files.html

For technical support, or to report documentation errors, please visit:


https://www.simcom.com/online_questions.html or email to: [email protected]

Copyright © 2023 SIMCom Wireless Solutions Limited All Rights Reserved.

www.simcom.com 1/19
A76XX Series_Dual SIM_Application Note_V1.02

About Document

Version History

Revision Date Author Description


V1.00 2022.05.30 Sijin.zhou New version
Yannan.sun
V1.01 2022.07.25 Bobo.shao Modified 3.3.1 Description: The AT channel of the
modem port is changed with the main card
Delete Q&A section “SIM2 PPP dial-up failure”
V1.02 2023.06.13 Update the scope of the document

www.simcom.com 2/19
A76XX Series_Dual SIM_Application Note_V1.02

Scope

Based on module AT command manual, this document will introduce Dual SIM application process.
Developers could understand and develop application quickly and efficiently based on this document.
This document applies to ASR CTA1 Series, A1603 Series, A1606 Series.

www.simcom.com 3/19
A76XX Series_Dual SIM_Application Note_V1.02

Contents

About Document .................................................................................................................... 2


Version History ...........................................................................................................................................2
Scope ......................................................................................................................................................... 3

Contents ................................................................................................................................. 4
1 Introduction ......................................................................................................................5
1.1 Purpose of the document .................................................................................................................... 5
1.2 Related documents ..............................................................................................................................5
1.3 Conventions and abbreviations ...........................................................................................................5

2 Basic Knowledge of DS ...................................................................................................6


3 DS Application ................................................................................................................. 7
3.1 DS Mode Selection ..............................................................................................................................7
3.1.1 DUAL SIM DUAL STANDBY FP ............................................................................................... 7
3.1.2 DUAL SIM DUAL STANDBY .....................................................................................................7
3.1.3 DUAL SIM SINGLE STANDBY ................................................................................................. 7
3.2 Master SIM Selection .......................................................................................................................... 8
3.3 Bind AT command channel and URC reporting. ...............................................................................10
3.3.1 Bind AT command channel ..................................................................................................... 10
3.3.2 URC reporting control ..............................................................................................................11
3.3.3 Data service URC on DS ........................................................................................................ 13
3.3.4 List of URC with suffix “DS” .................................................................................................... 13

4 Example .......................................................................................................................... 14
4.1 Basic DS configuration ...................................................................................................................... 14
4.2 URC reporting when power up ..........................................................................................................14
4.3 URC reporting on CS service ............................................................................................................15
4.4 URC reporting on PS service ............................................................................................................ 17

Q&A ....................................................................................................................................... 19

www.simcom.com 4/19
A76XX Series_Dual SIM_Application Note_V1.02

1 Introduction

1.1 Purpose of the document

This document will describe how to design with Dual SIM(DS for short) function from software side. With
this document customer will learn about the DS feature and apply to customer application.

1.2 Related documents

[1] A76XX Series_AT Command Manual


[2] A1602 & 1606 Series_AT Command Manual

1.3 Conventions and abbreviations

In this document, the GSM engines are referred to as following term:


ME (Mobile Equipment);
MS (Mobile Station);
TA (Terminal Adapter);
DCE (Data Communication Equipment) or facsimile DCE (FAX modem, FAX board);

In application, controlling device controls the GSM engine by sending AT Command via its serial interface.
The controlling device at the other end of the serial line is referred to as following term:
TE (Terminal Equipment);
DTE (Data Terminal Equipment) or plainly "the application" which is running on an embedded system;

Other Conventions:
DS(Dual-SIM);
DSDS(dual-SIM dual standby );
CS(Circuit Switching);
PS(Packet switching);
URC(Unsolicited result code);
IMEI(International Mobile Equipment Identity);

www.simcom.com 5/19
A76XX Series_Dual SIM_Application Note_V1.02

2 Basic Knowledge of DS

A76XX series of module could support DS feature with DSDS(Dual SIM Dual Standby) or DSSS(Dual SIM
Single Standby) configuration by AT command, the operation and behavior of the 2 SIM cards is
independent. The 2 SIM cards could communicate with network in parallel(when in idle mode), meaning
they can register to different operator,do cell selection\re-selection\paging at the same time. But the module
could only run CS\PS service with only 1 selected card at a time while for the other card it must be in not
connected or idle mode.For example when SIM1 is on a voice call,SIM2 can not accept incoming call and
caller to SIM2 will get “busy” or “not available” at the moment, only after SIM1 finish the call, then SIM2
could start CS service(voice call and SMS).In the same way only a selected card will act as master SIM to
provide data service while the other vice SIM could not have ability to provide data service.

www.simcom.com 6/19
A76XX Series_Dual SIM_Application Note_V1.02

3 DS Application
3.1 DS Mode Selection

3.1.1 DUAL SIM DUAL STANDBY FP

With this mode, the module will register network for both SIM cards. The master SIM will register ims
service(if card supported), and the vice SIM will register ims service too(if card supported)

3.1.2 DUAL SIM DUAL STANDBY

With this mode,the module will register network for both SIM cards. The master SIM will register ims
service(if card supported), and the vice SIM will not register ims service. If the vice card does not support
2G or the module is CAT-1 only, then there will be no CS service(voice call and SMS will not be supported).

3.1.3 DUAL SIM SINGLE STANDBY

With this mode,the module will only register network for master SIM,the vice SIM will be in flight mode.

The following AT command could be used to configure the DS mode.

AT+DUALSIM Set dual-sim mode


Response
+DUALSIM: (0: DUAL SIM DUAL STANDBY, 1: DUAL SIM
Test Command
SINGLE STANDBY, 3: DUAL SIM DUAL STANDBY FP)
AT+DUALSIM=?

OK
Response
Read Command +DUALSIM: <dsmode>
AT+DUALSIM?
OK
Response
1)If the parameter is correct, response:
Write Command
OK
AT+DUALSIM=<dsmode>
2)Others:
ERROR

www.simcom.com 7/19
A76XX Series_Dual SIM_Application Note_V1.02

Parameter Saving Mode AUTO_SAVE


Max Response Time 9000ms
Reference

Defined Values

<dsmode> Integer type


0 Dual SIM dual standby
1 Dual SIM single standby
3 Dual SIM dual standby with extras(Default setting)

Examples

AT+DUALSIM=?
+DUALSIM: (0: DUAL SIM DUAL STANDBY, 1:
DUAL SIM SINGLE STANDBY, 3: DUAL SIM
DUAL STANDBY FP)

OK
AT+DUALSIM?
+DUALSIM: 0

OK
AT+DUALSIM=0
OK

3.2 Master SIM Selection

A76XX series only support single channel of data service processor,so only one SIM could act as master
SIM to provide data service(SIM1 as default setting),there is AT command for customer to select master
SIM(command setting could be kept in NV ROM). But to keep the stability of module usage, if single card
has been inserted,this card will act as master SIM regardless of the setting by AT command. Changing
master SIM to a different card will lose all previous running CS\PS service.

www.simcom.com 8/19
A76XX Series_Dual SIM_Application Note_V1.02

The following AT command could be used to select the master SIM.

AT+SWITCHSIM Switch master SIM


Response
Test Command +SWITCHSIM: (0: SIM1, 1: SIM2)
AT+SWITCHSIM=?
OK
Response
Read Command +SWITCHSIM: <simID>
AT+SWITCHSIM?
OK
Response
1)If the parameter is correct,and the corresponding card has been
Write Command inserted, response:
AT+SWITCHSIM=<simID> OK
2)Others:
ERROR
Parameter Saving Mode AUTO_SAVE
Max Response Time 9000ms
Reference

Defined Values

<simID> Integer type


0 SIM1
1 SIM2

Examples

AT+SWITCHSIM=?
+SWITCHSIM: (0: SIM1, 1: SIM2)

OK
AT+SWITCHSIM?
+SWITCHSIM: 0

OK
AT+SWITCHSIM=1
OK

www.simcom.com 9/19
A76XX Series_Dual SIM_Application Note_V1.02

3.3 Bind AT command channel and URC reporting.

A76XX series has only 1 AT command channel internally,to handle dual SIM the module need to switch
different logic channel for different SIM. For AT command channel bind there is AT+BINDSIM command to
select SIM, further AT command send will be fixed to selected SIM card. For URC reporting there is
AT+DUALSIMURC command to configure the ability for SIM1 and SIM2.

3.3.1 Bind AT command channel

To ensure that the 2 SIM are controllable and do not affect each other, the AT command takes effect on only
one selected SIM. For example as default SIM1 is binding channel, all functions of AT commands sent by
users through the default bound channel are only effective for SIM1 card, and SIM2 card is not affected by
them. If you need to independently control or query the function status of SIM2 card, you need to use the AT
command to bind the channel in use to SIM2 card. In this case, the channel will give up the control of SIM1
card and only control SIM2 card. It should be noted that binding channels only affects the control right of AT
and does not affect URC reporting. For details on URC reporting, see 3.3.2.
Note: After the main card is switched, in order to use the PPP dial-up service more conveniently, the AT
channel of the Modem port will be automatically bound to the main card.

The following AT command could be used to bind AT command channel.

AT+BINDSIM Bind ATP to SIM1 or SIM2


Response
Test Command +BINDSIM: (0: SIM1, 1: SIM2)
AT+BINDSIM=?
OK
Response
Read Command +BINDSIM: <simID>
AT+BINDSIM?
OK
Response
1)If the parameter is correct, response:
Write Command
OK
AT+BINDSIM=<simID>
2)Others:
ERROR
Parameter Saving Mode NO_SAVE
Max Response Time 9000ms
Reference

Defined Values

www.simcom.com 10/19
A76XX Series_Dual SIM_Application Note_V1.02

<simID> Integer type


0 SIM1
1 SIM2

Examples

AT+BINDSIM=?
+BINDSIM: (0: SIM1, 1: SIM2)

OK
AT+BINDSIM?
+BINDSIM: 0

OK
AT+BINDSIM=0
OK
AT+CIMI
460003064859756

OK
AT+BINDSIM=1
OK
AT+CIMI
460012360528428

OK

3.3.2 URC reporting control

In order to distinguish dual SIM reporting and avoid dual SIM URC confusion, only the URC information of
SIM1 card will be reported in the factory default channel, and the URC information of SIM2 card will be
shielded by default. You can select the URC switch of a certain SIM card through the AT command, or turn
on the URC of two cards AT the same time to report. When the URC switch of SIM2 card is turned on
(AT+DUALSIMURC=1/2), the suffix "DS" is added to part of the URC of SIM2 card for differentiation (see
3.3.4 for details), which is valid for all channels, including CMUX. Such as:

SIM1 Call URC: RING

SIM2 Call URC: RINGDS

The following AT command could be used to configure URC reporting switch.

www.simcom.com 11/19
A76XX Series_Dual SIM_Application Note_V1.02

AT+DUALSIMURC Dual card reporting control


Response
Test Command +DUALSIMURC: (0:SIM1, 1:SIM2, 2:SIM1&SIM2)
AT+DUALSIMURC=?
OK
Response
Read Command + DUALSIMURC: <opt>
AT+DUALSIMURC?
OK
Response
1)If the parameter is correct, response:
Write Command
OK
AT+DUALSIMURC =<opt>
2)Others:
ERROR
Parameter Saving Mode AUTO_SAVE
Max Response Time 9000ms
Reference

Defined Values

<opt> Integer type


0 SIM1---Only output URC from SIM1
1 SIM2---Only output URC from SIM2
2 SIM1 & SIM2---Output URC from SIM1&SIM2

Note: URC for SIM2 will add “DS” in the end of string.

Examples

AT+DUALSIMURC=?
+DUALSIMURC: (0:SIM1, 1:SIM2, 2:SIM1&SIM2)

OK
AT+DUALSIMURC?
+ DUALSIMURC: 0

OK
AT+ DUALSIMURC=1
OK

www.simcom.com 12/19
A76XX Series_Dual SIM_Application Note_V1.02

3.3.3 Data service URC on DS

Based on the description of primary card switching in Section 3.2 , it can be seen that due to the single AT
command channel design, the current data service of the module can only be carried by the primary card
dial-up. Therefore, the URC reported for data service operation will not add the suffix "DS" and only needs
to be checked by AT+SWITCHSIM? so that the URC card source can be distinguished by querying the
current master SIM number. Any data service operation is not affected by AT+BINDSIM. In other words, all
data business interaction objects are master cards. The data services include TCP, FTP, HTP, HTTP, MQTT,
NTP, PING, and SSL.

3.3.4 List of URC with suffix “DS”

SIM1 URC SIM2 URC


SMS DONE SMS DONEDS
PB DONE PB DONEDS
SMS FULL SMS FULLDS
RING RINGDS
NO CARRIER NO CARRIERDS
+CPIN +CPINDS
*ATREADY *ATREADYDS
+CCWA +CCWADS
+CLCC +CLCCDS
+CLIP +CLIPDS
+COLP +COLPDS
+CREG +CREGDS
+CGREG +CGREGDS
+CEREG +CEREGDS
+CMTI +CMTIDS
+CMT +CMTDS
+CDS +CDSDS
+MSTK +MSTKDS
+CUSD +CUSDDS
+CGEV +CGEVDS
+SIMCARD +SIMCARDDS
VOICE CALL VOICE CALLDS
+CDSI +CDSIDS
+CBM +CBMDS
+CRING +CRINGDS

www.simcom.com 13/19
A76XX Series_Dual SIM_Application Note_V1.02

4 Example

4.1 Basic DS configuration

AT+DUALSIM? Check DS mode


+DUALSIM: 3 Dual SIM Dual Standby with extras

OK
AT+SWITCHSIM? Check master SIM
+SWITCHSIM: 0 SIM1 as mater SIM with default setting

OK
AT+BINDSIM? Check binding AT command channel
+BINDSIM: 0 SIM1 as binding channel

OK
AT+CSPN? Check registered operator
+CSPN: “CMCC”,1 SIM1 registered to CMCC

OK
AT+BINDSIM=1 Change binding AT command channel to SIM2
OK
AT+BSPN? Check registered operator
+CSPN: “China Telecom”,1 SIM2 registered to China Telecom

OK

4.2 URC reporting when power up

AT+DUALSIMURC? Check URC switch setting


+DUALSIMURC: 0 URC reporting only for SIM1 as default setting

OK
+CPIN: READY Reboot module,URC reporting for SIM1

www.simcom.com 14/19
A76XX Series_Dual SIM_Application Note_V1.02

+CGEN: EPS PDN ACT 1

SMS DONE

PB DONE
AT+DUALSIMURC=2 Changing URC switch
OK
+CPIN: READY Reboot module, URC reporting for both SIM1 and
SIM2, for SIM2 the URC with “DS”
+CPINDS: READY

*ATREADY: 1

*ATREADYDS: 1

PB DONE

SMS DONE

+CGEVDS: EPS PDN ACT 1

PBDS DONE

SMSDS DONE

4.3 URC reporting on CS service

Voice call:

AT+BINDSIM? Check binding AT command channel


+BINDSIM: 0 Bind to SIM1

OK
AT+DUALSIMURC=2 Enable URC for SIM1 and SIM2
OK
AT+BINDSIM=1 Bind to SIM2
OK
ATD18412345678; Make voice call from SIM2, URC reporting for
SIM2
+CGEVDS: NW ACT 8,10

www.simcom.com 15/19
A76XX Series_Dual SIM_Application Note_V1.02

OK

+CLCCDS: 1,0,2,0,0,"18412345678",129,""

+CLCCDS: 1,0,3,0,0,"18412345678",129,""
VOICE CALLDS: BEGIN

+CLCCDS: 1,0,0,0,0,"18412345678",129,""

+COLPDS: "18412345678",129

AT+CHUP Hung up call


+CGEVDS: NW DEACT 8,10

NO CARRIERDS

+CLCCDS: 1,0,6,0,0,"18468070411",129,""

OK

VOICE CALLDS: END: 000010

+CGEVDS: NW ACT 8,10

RINGDS

+CLIPDS: "18468070411",129

+CLCCDS: 1,1,4,0,0,"18468070411",129,""

ATA Answer call


VOICE CALLDS: BEGIN

+CLCCDS: 1,1,0,0,0,"18468070411",129,""

OK
AT+CHUP Hung up call
+CGEVDS: NW DEACT 8,10

NO CARRIERDS

+CLCCDS: 1,1,6,0,0,"18468070411",129,""

VOICE CALLDS: END: 000011

www.simcom.com 16/19
A76XX Series_Dual SIM_Application Note_V1.02

OK

NOTE

Only one SIM card can initiate the voice call service at a time. The SIM card must be the same as the
control right of the current binding AT channel when you use or hang up the call service. Otherwise, the
command will be invalid.

SMS:

AT+CCNMI=2,1,0,0,0 Set new SMS URC indicator


OK
+CMTI: "SM",1 URC for new SMS on SIM1

+CMTIDS: "SM",1 URC for new SMS on SIM2


AT+CNMI=1,2,0,0,0 Set new SMS URC indicator with text output to
UART
OK
+CMT: URC for new SMS on SIM1
"+8618325007055","","22/05/29,14:20:05+32"

1234

+CMTDS: URC for new SMS on SIM2


"+8618325007055","","22/05/29,14:20:05+32"

1234

4.4 URC reporting on PS service

AT+SWITCHSIM? Check master SIM


+SWITCHSIM: 0 SIM1 as master SIM

OK
AT+BINDSIM=0 Bind to SIM1

www.simcom.com 17/19
A76XX Series_Dual SIM_Application Note_V1.02

OK
AT+CGPADDR Check IP for SIM1
+CGPADDR: 1,10.60.78.57

OK
AT+BINDSIM=1 Bind to SIM2
OK
AT+CGPADDR Check IP for SIM2
+CGPADDR: 1,10.60.20.48

OK
AT+CPING=”8.8.8.8”,1,3,10,1000 SIM1 as master SIM to PING 8.8.8.8

OK

+CPING: 1,8.8.8.8,38,55,49

+CPING: 1,8.8.8.8,38,45,49

+CPING: 1,8.8.8.8,38,45,49

+CPING: 3,3,3,0,45,55,48

AT+SWITCHSIM=1 Change master SIM to SIM2


OK

AT+CPING=”8.8.8.8”,1,3,10,1000 SIM1 as master SIM to PING 8.8.8.8

+CPING: 1,8.8.8.8,38,110,114

+CPING: 1,8.8.8.8,38,115,114

+CPING: 1,8.8.8.8,38,100,114

+CPING: 3,3,3,0,100,115,108

www.simcom.com 18/19
A76XX Series_Dual SIM_Application Note_V1.02

Q&A

Q:Why can not read second IMEI and get ERROR?


A:ERROR means there is no second IMEI inside module, you need to check if you are using correct
hardware PN as only DS hardware version has second IMEI.Please note in some case if there is no
second IMEI the registeration on second SIM will fail. For test purpose customer could use
AT+BINDSIM=1 and AT+SIMEI=xxx to write a temp second IMEI.

Q:Why AT+SWITCHSIM=0/1 returns ERROR?


A:(1)Please check if the selected SIM card has been inserted well, usually it is hardware connection
issue.
(2)Please check with AT+SWITCHSIM? if current setting has already been configured, same
configuration will cause ERROR.

Q:Why after AT+SWITCHSIM=0 or 1 to change master,some AT command can not be used and
return ERROR?

A:Switching master will will take few seconds,please wait at least 5 seconds then send AT command
especially for network related AT commands.

www.simcom.com 19/19

You might also like