CN114363455A - SIM card switching control method, device, equipment and storage medium - Google Patents

SIM card switching control method, device, equipment and storage medium Download PDF

Info

Publication number
CN114363455A
CN114363455A CN202011089360.5A CN202011089360A CN114363455A CN 114363455 A CN114363455 A CN 114363455A CN 202011089360 A CN202011089360 A CN 202011089360A CN 114363455 A CN114363455 A CN 114363455A
Authority
CN
China
Prior art keywords
sim card
external
switching circuit
event
terminal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011089360.5A
Other languages
Chinese (zh)
Inventor
何晓飞
韩哲
苑林
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chengdu TD Tech Ltd
Original Assignee
Chengdu TD Tech Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Chengdu TD Tech Ltd filed Critical Chengdu TD Tech Ltd
Priority to CN202011089360.5A priority Critical patent/CN114363455A/en
Publication of CN114363455A publication Critical patent/CN114363455A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Telephone Function (AREA)

Abstract

The invention provides a method, a device, equipment and a storage medium for controlling SIM card switching, which are applied to a terminal, wherein the terminal supports placing an external SIM card and configuring a built-in SIM card; the method comprises the following steps: determining that the detected target event is a hot-plug event or a hot-plug event of the external SIM card; if the target event is a hot plug event, controlling a switching circuit in the terminal to be connected with the external SIM card so that the external SIM card is electrified to work; and if the target event is a hot plug event, controlling a switching circuit to be connected with the built-in SIM card so that the built-in SIM card is electrified to work. The embodiment of the invention can realize the automatic switching of the SIM card.

Description

SIM card switching control method, device, equipment and storage medium
Technical Field
The embodiment of the invention relates to the technical field of communication, in particular to a method, a device, equipment and a storage medium for controlling SIM card switching.
Background
The mobile phone is a commonly used communication tool for human, and after a Subscriber Identity Module (SIM) card is installed in the mobile phone, the mobile phone can enjoy services provided by an operator, including talking with others, surfing the internet using data traffic, and the like.
At least one SIM card holder is usually disposed inside the current mobile phone for placing the SIM card. In the current mobile phone, if the external SIM card or the internal SIM card needs to be switched, the replacement needs to be performed manually, which is troublesome to operate.
Therefore, the prior art cannot realize the automatic switching of the SIM cards.
Disclosure of Invention
The embodiment of the invention provides a method, a device, equipment and a storage medium for controlling SIM card switching, which can realize automatic switching of SIM cards.
In a first aspect, an embodiment of the present invention provides a SIM card switching control method, which is applied to a terminal, where the terminal supports placement of an external SIM card and configuration of an internal SIM card; the method comprises the following steps:
determining that the detected target event is a hot-plug event or a hot-plug event of the external SIM card;
if the target event is a hot plug event, controlling a switching circuit to be connected with the external SIM card so that the external SIM card is electrified to work;
and if the target event is a hot plug event, controlling a switching circuit to be connected with the built-in SIM card so that the built-in SIM card is electrified to work.
In one possible design, the switching circuit is a GPIO switching circuit, and the GPIO switching circuit is configured to connect with the external SIM card or the internal SIM card; the determining that the detected target event is a hot-plug event or a hot-plug event of the external SIM card includes:
judging whether the external SIM card is pulled out when the terminal is in a card state or not by detecting the current state of the GPIO switching circuit;
if the external SIM card is pulled out when the terminal is in a card state, determining that the external SIM card is a hot pull event;
if the external SIM card is not pulled out when the terminal is in a card-containing state, judging whether the external SIM card is inserted when the terminal is in a card-free state;
and if the external SIM card inserting operation exists when the terminal is in a card-free state, determining that the external SIM card inserting operation is a hot inserting event.
In one possible design, the switching circuit is a GPIO switching circuit; the control switching circuit is connected with the external SIM card, so that the external SIM card is electrified to work, and the control switching circuit comprises:
controlling a GPIO switching circuit to be connected with the external SIM card so as to electrify the external SIM card;
and triggering the initialization operation of the external SIM card, and executing the operation of electrifying the external SIM card.
In one possible design, the switching circuit is a GPIO switching circuit; the control switching circuit is connected with the built-in SIM card, so that the built-in SIM card is electrified to work, and the control switching circuit comprises:
controlling a GPIO switching circuit to be connected with the built-in SIM card so as to electrify the built-in SIM card;
and triggering the initialization operation of the built-in SIM card, and executing the operation of electrifying the built-in SIM card.
In one possible design, before the determining that the detected target event is a hot-plug event or a hot-plug event of the external SIM card, the method further includes:
receiving a target event through a universal wireless communication system USIM in the terminal, wherein the target event is used for representing the hot plug event of the external SIM card;
and if the SIM card switching function in the terminal is triggered to be enabled, determining to execute the operation of detecting that the target event is a hot plug event or a hot plug event of the external SIM card.
In a second aspect, an embodiment of the present invention provides an SIM card switching control apparatus, which is applied to a terminal, where the terminal supports placing an external SIM card and configuring an internal SIM card; the device comprises:
the determining module is used for determining that the detected target event is a hot plug event or a hot plug event of the external SIM card;
the control module is used for controlling the switching circuit to be connected with the external SIM card when the target event is a hot plug event so as to electrify the external SIM card to work;
the control module is further configured to control the switching circuit to be connected with the built-in SIM card when the target event is a hot plug event, so that the built-in SIM card is powered on to operate.
In one possible design, the switching circuit is a GPIO switching circuit, and the GPIO switching circuit is configured to connect with the external SIM card or the internal SIM card; the determining module is specifically configured to:
judging whether the external SIM card is pulled out when the terminal is in a card state or not by detecting the current state of the GPIO switching circuit;
if the external SIM card is pulled out when the terminal is in a card state, determining that the external SIM card is a hot pull event;
if the external SIM card is not pulled out when the terminal is in a card-containing state, judging whether the external SIM card is inserted when the terminal is in a card-free state;
and if the external SIM card inserting operation exists when the terminal is in a card-free state, determining that the external SIM card inserting operation is a hot inserting event.
In one possible design, the switching circuit is a GPIO circuit; the control module is specifically configured to:
controlling a GPIO switching circuit to be connected with the external SIM card so as to electrify the external SIM card;
and triggering the initialization operation of the external SIM card, and executing the operation of electrifying the external SIM card.
In a third aspect, an embodiment of the present invention provides an SIM card switching control device, including: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executes computer-executable instructions stored by the memory, so that the at least one processor executes the SIM card switching control method according to any one of the first aspect.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, where a computer executing instruction is stored, and when a processor executes the computer executing instruction, the SIM card switching control method according to any one of the first aspect is implemented.
The SIM card switching control method, the device, the equipment and the storage medium provided by the embodiment of the invention are applied to a terminal, and the terminal supports placing an external SIM card and configuring a built-in SIM card; firstly, determining that a detected target event is a hot plug event or a hot plug event of the external SIM card; if the target event is a hot plug event, controlling a switching circuit to be connected with the external SIM card so that the external SIM card is electrified to work; if the target event is a hot-plug event, controlling the switching circuit to be connected with the built-in SIM card to electrify the built-in SIM card to work, and correspondingly controlling the switching circuit to be connected with the external SIM card and the built-in SIM card by the terminal based on the target event to realize the automatic switching of the external SIM card and the built-in SIM card, thereby effectively improving the service capability of the terminal and meeting the user requirements.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a schematic view of a scenario of a SIM card switching control method according to an embodiment of the present invention;
fig. 2 is a schematic flowchart of a SIM card switching control method according to an embodiment of the present invention;
fig. 3 is a schematic flowchart of a SIM card switching control method according to another embodiment of the present invention;
fig. 4 is a schematic structural diagram of a SIM card switching control apparatus according to an embodiment of the present invention;
fig. 5 is a schematic diagram of a hardware structure of a SIM card switching control device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are, for example, capable of operation in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
At least one SIM card holder is usually disposed inside the current mobile phone for placing the SIM card. In the current mobile phone, if the external SIM card or the internal SIM card needs to be switched, the replacement needs to be performed manually, which is troublesome to operate. Therefore, the prior art cannot realize the automatic switching of the SIM cards.
In order to solve the problems, the technical idea of the invention is to configure the switching circuit on the terminal, and the terminal can correspondingly control the switching circuit to be connected with an external SIM card or an internal SIM card in the terminal by detecting a hot plug event or a hot plug event based on a determined event, so as to realize the automatic switching of the external SIM card and the internal SIM card, effectively improve the service capability of the terminal and meet the user requirements.
The technical solution of the present invention will be described in detail below with specific examples. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments.
Fig. 1 is a scene schematic diagram of a SIM card switching control method according to an embodiment of the present invention, where an execution main body in the method according to the embodiment may be a terminal, and specifically may be a baseband processor modem on the terminal, where the modem may include units such as a digital signal processor DSP, a microcontroller MCU, and a memory. In order to realize the automatic switching of the SIM card, a switching circuit is arranged, wherein the switching circuit can be a GPIO switching circuit, the GPIO switching circuit is welded on the modem, a pin of the GPIO can be connected with the SIM card, and the modem can control the switching of the SIM connected with the switching circuit. The SIM card connected with the switching circuit can be powered on.
The terminal supports placing an external SIM card and configuring the internal SIM card, can be a single-card terminal (namely a modem with only one USIM interface) or a dual-card terminal, and for the single-card terminal, when the terminal is started by default, the external SIM card is electrified and initialized; for a dual-card terminal, when the terminal is powered on by default, the external SIM1 card (the SIM card placed in the main card slot) is powered on for initialization.
For example, taking a single-card terminal as an example, referring to fig. 1, hot plug detection for an external SIM card may be detected by a GPIO, and if a hot plug or hot plug event occurs in the single-card terminal, the GPIO switching circuit may be controlled to connect with a corresponding SIM card. For example, in a hot plug event, for example, the modem in fig. 1 is connected to the external SIM card, the external SIM card is powered on, and an initialization operation is performed, so as to complete network registration, thereby performing related services, implementing automatic switching between the external SIM card and the internal SIM card, effectively improving the service capability of the terminal, and meeting the user requirements.
For a dual-card terminal, a hot plug event exists, which may be similar to the steps executed by a single-card terminal, and is not described herein again.
Fig. 2 is a schematic flowchart of a SIM card switching control method according to an embodiment of the present invention. The SIM card switching control method is applied to a terminal, the terminal supports placing an external SIM card and configuring an internal SIM card, and for the convenience of understanding, the SIM card switching control method is explained in detail by taking a single-card terminal as an example. The SIM card switching control method may include:
s101, determining that the detected target event is a hot plug event or a hot plug event of the external SIM card.
In this embodiment, the terminal may detect, by the switching circuit, whether the target event is a hot plug event or a hot plug event of the external SIM card, where the hot plug event may be a hot plug into the external SIM card, and the hot plug event may be a hot plug out of the external SIM card.
Before detecting whether the target event is a hot plug event or a hot plug event of the external SIM card, the terminal may receive the target event, that is, the external SIM card hot plug event, through a Universal Subscriber Identity Module (USIM) in the terminal, which may specifically be implemented by the following steps:
step a1, receiving a target event through a global subscriber identity module in the terminal, where the target event is used to indicate a hot plug event of the external SIM card.
Step a2, if the SIM card switching function in the terminal is triggered to be enabled, determining to execute the operation of detecting that the target event is a hot-plug event or a hot-plug event of the external SIM card.
In this embodiment, the USIM module receives an external SIM card hot plug event, and reports the external SIM card hot plug event to the modem, and the modem starts to process the external SIM card hot plug event, and first determines whether the SIM card switching function is macro-closed, and if the macro-closed, the SIM switching is implemented in at least three scenarios:
and in a scene 11, if the USIM module receives a hot-plug event of the external SIM card under the condition of a card, executing an operation of activating the internal SIM card, and executing related work such as powering off the external SIM card.
And in the scene 12, if the USIM module receives the external SIM card hot plug event under the condition of no external SIM card, the USIM module executes the operation of activating the external SIM card to complete the related work of power-on initialization of the external SIM card.
Scene 13, and other cases are ended without executing the switching operation.
If the macro is not closed, the SIM card switching function in the terminal is triggered to enable, and the operation that the detection target event is the hot plug event or the hot plug event of the external SIM card is started to be executed, so that the specific detection of the target event is realized.
S102, if the target event is a hot plug event, controlling a switching circuit in the terminal to be connected with the external SIM card, so that the external SIM card is electrified to work.
In this embodiment, if the detected target event is a hot plug event, the modem controls the switching circuit to connect with the external SIM card, the external SIM card is powered on and initializes the external SIM card, and the terminal may register a network and perform related services only by using information related to the external SIM card.
S103, if the target event is a hot plug event, controlling a switching circuit to be connected with the built-in SIM card, so that the built-in SIM card is electrified to work.
In this embodiment, if the detected target event is a hot plug event, the modem controls the switching circuit to connect with the built-in SIM card, the built-in SIM card is powered on and initializes the built-in SIM card, and the terminal may register a network and perform related services only by using the related information of the built-in SIM card.
Specifically, the single-card terminal can alternately use the internal SIM card or the external SIM card, so as to meet the needs of the industry users, for example, the needs of the 5G industry users.
Therefore, for a Modem (2G/3G/4G/5G) (namely a single-card terminal) with only one USIM interface, aiming at the requirement of connecting two SIM cards for alternate use (namely, when an external SIM card is pulled out, the internal SIM card is automatically switched to the internal SIM card, the internal SIM card is powered on to work, and when the external SIM card is inserted in a hot mode, the external SIM card is automatically switched to the external SIM card and powered on to work), the single-card terminal can realize the user requirement and complete the automatic switching of the SIM cards by the SIM card switching control method.
The SIM card switching control method provided in this embodiment is applied to a terminal, where the terminal supports placing an external SIM card and configuring an internal SIM card; firstly, determining that a detected target event is a hot plug event or a hot plug event of the external SIM card; if the target event is a hot plug event, controlling a switching circuit to be connected with the external SIM card so that the external SIM card is electrified to work; if the target event is a hot-plug event, controlling the switching circuit to be connected with the built-in SIM card to electrify the built-in SIM card to work, and correspondingly controlling the switching circuit to be connected with the external SIM card and the built-in SIM card by the terminal based on the target event to realize the automatic switching of the external SIM card and the built-in SIM card, thereby effectively improving the service capability of the terminal and meeting the user requirements.
In a possible design, the present embodiment provides a detailed description of S101 on the basis of the above embodiments. The switching circuit is a GPIO switching circuit, and the GPIO switching circuit is used for being connected with the external SIM card or the internal SIM card. The determining that the detected target event is a hot-plug event or a hot-plug event of the external SIM card may be implemented by:
and b1, judging whether the external SIM card is pulled out when the terminal is in the card state by detecting the current state of the GPIO switching circuit.
Step b2, if the external SIM card is pulled out when the terminal is in the card state, determining that the operation is a hot pull event.
Step b3, if the external SIM card is not pulled out when the terminal is in the card-containing state, judging whether the external SIM card is inserted when the terminal is in the card-free state.
Step b4, if the external SIM card inserting operation exists when the terminal is in the no-card state, determining that the operation is a hot inserting event.
In this embodiment, the current state of the GPIO switching circuit is detected, for example, whether a pin of the GPIO is a high level or a low level, for example, the high level indicates that the external SIM card is pulled out under the condition of a card being present, and the low level indicates that the external SIM card is inserted under the condition of no card being present; or, the low level indicates that the external SIM card is pulled out in the case of a card being present, and the high level indicates that the external SIM card is inserted in the case of no card being present. The specific level state represents which kind of scene can be configured in advance, and no specific limitation is made here, and only by means of different level states, the external SIM card existing in the card-existing state is pulled out, and the external SIM card existing in the card-absent state is inserted and distinguished.
If a scene of the external SIM card pulling operation exists under the condition of card existence, determining that the external SIM card pulling operation is a hot pulling event; if the external SIM card is inserted into the external SIM card in the situation of no card, determining that the external SIM card is a hot insertion event; in other scenarios, the hot plug process may be directly ended, and the automatic switching and initialization operations of the SIM card may not be performed.
In a possible design, the present embodiment provides a detailed description of S102 on the basis of the above embodiments. The control switching circuit is connected with the external SIM card, so that the external SIM card is electrified to work, and the control switching circuit can be realized by the following steps:
and c1, controlling the GPIO switching circuit to be connected with the external SIM card, so that the external SIM card is powered on.
And c2, triggering the initialization operation of the external SIM card, and executing the operation of electrifying the external SIM card.
In this embodiment, the modem switches the GPIO to the external SIM card, that is, the external SIM card is powered on to operate, and then the modem triggers an initialization procedure of the external SIM card, so that the external SIM card completes initialization, and then the terminal can register a network by using relevant information of the external SIM card and perform relevant services.
In a possible design, the present embodiment provides a detailed description of S103 on the basis of the above embodiments. The control switching circuit is connected with the built-in SIM card, so that the built-in SIM card is electrified to work, and the control switching circuit can be realized by the following steps:
and d1, controlling a GPIO switching circuit to be connected with the built-in SIM card, so that the built-in SIM card is powered on.
And d2, triggering the initialization operation of the built-in SIM card, and executing the operation of electrifying the built-in SIM card.
In this embodiment, the modem switches the GPIO to the built-in SIM card, that is, the built-in SIM card is powered on to operate, and then the modem triggers an initialization procedure of the built-in SIM card, so that the built-in SIM card completes initialization, and the terminal can register a network by using relevant information of the built-in SIM card and perform relevant services.
Specifically, as shown in fig. 3, fig. 3 is a schematic flow chart of a SIM card switching control method according to another embodiment of the present invention.
S201, the USIM module receives an external SIM card hot plug event, and if the simswitch (SIM card switching function) is enabled, S202 is executed; if the simswitch is closed, executing S204;
s202, according to the currently used card and the hot plug event, the following four scenes are divided:
scene 1: under the power-on working condition of the external SIM card, when the external SIM card is pulled out (the explanation is a hot pull event), the following operations are carried out:
step 1: deactivating the external SIM card (executing related work such as powering down the external SIM card);
step 2: switching the GPIO (controlling the electrification work of the internal SIM card or the external SIM card by the GPIO) to the internal SIM card (namely the electrification work of the internal SIM card);
step 3: activating the built-in card, completing the relevant processes of power-on initialization of the built-in SIM card, and then executing S203;
scene 2: under the condition that the built-in SIM card is electrified and works, the external SIM card is pulled out, and the following operations are carried out:
step 1: step S203 is executed;
scene 3: under the condition of using the external SIM card (GPIO power supply external card work), the external SIM card is inserted, and the following operations are carried out:
step 1: activating the external card, and executing S203;
scene 4: under the working condition of the built-in card, when the external card is inserted (the explanation is a hot insertion event), the following operations are carried out:
step 1: deactivating the built-in card (executing related work such as powering down the built-in SIM card);
step 2: switching the GPIO to an external SIM card;
step 3: activating the external SIM card, completing the relevant procedures of power-on initialization of the external SIM card, and then executing S203;
s203, finishing the hot plug flow processing;
s204, the operations of the above-described scene 11, scene 12, and scene 13 are performed.
In practical application, when a single-card terminal is started by default, the external SIM card is electrified and initialized; when detecting whether the external SIM card is inserted/pulled out thermally, the following operations are carried out:
when the external card is hot-pulled out (whether the external sim card is hot-plugged or hot-pulled out can be controlled by a hot plug detection GPIO)
1. A GPIO switching (hardware) circuit for controlling SIM card switching is connected with the built-in SIM card;
2. powering on the built-in SIM card and completing related work of SIM card initialization;
3. the terminal can register the network only by using the relevant information of the built-in card and does relevant services.
When the external SIM card is inserted in a hot mode (whether the external SIM card is inserted in the hot mode or pulled out of the hot mode is controlled by a hot plug detection GPIO);
1. a GPIO switching (hardware) circuit (such as a connection line with an external SIM card in fig. 1) that controls SIM card switching is connected to the external SIM card;
2. electrifying the external SIM card and completing the related work of SIM card initialization;
3. the terminal can register the network only by using the relevant information of the external card and does relevant service.
Therefore, automatic switching between the external SIM card and the internal SIM card is realized, the service capability of the terminal is effectively improved, and the user requirements are met.
Fig. 4 is a schematic structural diagram of a SIM card switching control apparatus according to an embodiment of the present invention, and an application terminal supports placing an external SIM card and configuring an internal SIM card. As shown in fig. 4, the SIM card switching control means 40 may include: a determination module 401 and a control module 402.
The determining module 401 is configured to determine that the detected target event is a hot plug event or a hot plug event of the external SIM card; a control module 402, configured to control a switching circuit in the terminal to connect with the external SIM card when the target event is a hot plug event, so that the external SIM card is powered on to operate; the control module 402 is further configured to control a switching circuit to connect with the internal SIM card when the target event is a hot plug event, so that the internal SIM card is powered on to operate.
In this embodiment, the setting determining module 401 and the control module 402 are configured to determine that the detected target event is a hot plug event or a hot plug event of the external SIM card; if the target event is a hot plug event, controlling a switching circuit to be connected with the external SIM card so that the external SIM card is electrified to work; if the target event is a hot-plug event, controlling the switching circuit to be connected with the built-in SIM card to electrify the built-in SIM card to work, and correspondingly controlling the switching circuit to be connected with the external SIM card and the built-in SIM card by the terminal based on the target event to realize the automatic switching of the external SIM card and the built-in SIM card, thereby effectively improving the service capability of the terminal and meeting the user requirements.
In one possible design, the switching circuit is a GPIO switching circuit, and the GPIO switching circuit is configured to connect with the external SIM card or the internal SIM card; a determination module specifically configured to: judging whether the external SIM card is pulled out when the terminal is in a card state or not by detecting the current state of the GPIO switching circuit; if the external SIM card is pulled out when the terminal is in a card state, determining that the external SIM card is a hot pull event; if the external SIM card is not pulled out when the terminal is in a card-containing state, judging whether the external SIM card is inserted when the terminal is in a card-free state; and if the external SIM card inserting operation exists when the terminal is in a card-free state, determining that the external SIM card inserting operation is a hot inserting event.
In one possible design, the switching circuit is a GPIO circuit; the control module is specifically configured to:
controlling a GPIO switching circuit to be connected with the external SIM card so as to electrify the external SIM card; and triggering the initialization operation of the external SIM card, and executing the operation of electrifying the external SIM card.
In one possible design, the control module is further specifically configured to:
controlling a GPIO switching circuit to be connected with the built-in SIM card so as to electrify the built-in SIM card; and triggering the initialization operation of the built-in SIM card, and executing the operation of electrifying the built-in SIM card.
In one possible design, the apparatus may further include: a processing module; the processing module is used for receiving a target event through a global subscriber identity module in the terminal before the detected target event is determined to be a hot plug event or a hot plug event of the external SIM card, wherein the target event is used for representing a hot plug event of the external SIM card; and if the SIM card switching function in the terminal is triggered to be enabled, determining to execute the operation of detecting that the target event is a hot plug event or a hot plug event of the external SIM card.
The SIM card switching control apparatus provided in the embodiment of the present invention can implement the SIM card switching control method in the above-described embodiment, and the implementation principle and technical effect are similar, which are not described herein again.
Fig. 5 is a schematic diagram of a hardware structure of a SIM card switching control device according to an embodiment of the present application. As shown in fig. 5, the SIM card switching control device 50 provided in this embodiment includes: at least one processor 501 and memory 502. The processor 501 and the memory 502 are connected by a bus 503.
In a specific implementation, the at least one processor 501 executes the computer-executable instructions stored in the memory 502, so that the at least one processor 501 executes the method in the above-described method embodiments.
For a specific implementation process of the processor 501, reference may be made to the above method embodiments, which implement the similar principle and technical effect, and this embodiment is not described herein again.
In the embodiment shown in fig. 5, it should be understood that the Processor may be a Central Processing Unit (CPU), other general purpose processors, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with the present invention may be embodied directly in a hardware processor, or in a combination of the hardware and software modules within the processor.
The memory may comprise high speed RAM memory and may also include non-volatile storage NVM, such as at least one disk memory.
The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended ISA (EISA) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, the buses in the figures of the present application are not limited to only one bus or one type of bus.
The embodiment of the invention also provides a computer-readable storage medium, wherein a computer execution instruction is stored in the computer-readable storage medium, and when a processor executes the computer execution instruction, the SIM card switching control method of the embodiment of the method is realized.
The computer-readable storage medium may be implemented by any type of volatile or non-volatile memory device or combination thereof, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disk. Readable storage media can be any available media that can be accessed by a general purpose or special purpose computer.
An exemplary readable storage medium is coupled to the processor such the processor can read information from, and write information to, the readable storage medium. Of course, the readable storage medium may also be an integral part of the processor. The processor and the readable storage medium may reside in an Application Specific Integrated Circuits (ASIC). Of course, the processor and the readable storage medium may also reside as discrete components in the apparatus.
Those of ordinary skill in the art will understand that: all or a portion of the steps of implementing the above-described method embodiments may be performed by hardware associated with program instructions. The program may be stored in a computer-readable storage medium. When executed, the program performs steps comprising the method embodiments described above; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. A SIM card switching control method is characterized by being applied to a terminal, wherein the terminal supports placing an external SIM card and configuring an internal SIM card; the method comprises the following steps:
determining that the detected target event is a hot-plug event or a hot-plug event of the external SIM card;
if the target event is a hot plug event, controlling a switching circuit in the terminal to be connected with the external SIM card so that the external SIM card is electrified to work;
and if the target event is a hot plug event, controlling a switching circuit to be connected with the built-in SIM card so that the built-in SIM card is electrified to work.
2. The method of claim 1, wherein the switching circuit is a GPIO switching circuit configured to connect with the external SIM card or the internal SIM card; the determining that the detected target event is a hot-plug event or a hot-plug event of the external SIM card includes:
judging whether the external SIM card is pulled out when the terminal is in a card state or not by detecting the current state of the GPIO switching circuit;
if the external SIM card is pulled out when the terminal is in a card state, determining that the external SIM card is a hot pull event;
if the external SIM card is not pulled out when the terminal is in a card-containing state, judging whether the external SIM card is inserted when the terminal is in a card-free state;
and if the external SIM card inserting operation exists when the terminal is in a card-free state, determining that the external SIM card inserting operation is a hot inserting event.
3. The method of claim 1, wherein the switching circuit is a GPIO switching circuit; the control switching circuit is connected with the external SIM card, so that the external SIM card is electrified to work, and the control switching circuit comprises:
controlling a GPIO switching circuit to be connected with the external SIM card so as to electrify the external SIM card;
and triggering the initialization operation of the external SIM card, and executing the operation of electrifying the external SIM card.
4. The method of claim 1, wherein the switching circuit is a GPIO switching circuit; the control switching circuit is connected with the built-in SIM card, so that the built-in SIM card is electrified to work, and the control switching circuit comprises:
controlling a GPIO switching circuit to be connected with the built-in SIM card so as to electrify the built-in SIM card;
and triggering the initialization operation of the built-in SIM card, and executing the operation of electrifying the built-in SIM card.
5. The method of any of claims 1-4, wherein prior to the determining that the detected target event is a hot-plug event or a hot-unplug event for the external SIM card, the method further comprises:
receiving a target event through a global subscriber identity module in the terminal, wherein the target event is used for representing a hot plug event of the external SIM card;
and if the SIM card switching function in the terminal is triggered to be enabled, determining to execute the operation of detecting that the target event is a hot plug event or a hot plug event of the external SIM card.
6. The SIM card switching control device is applied to a terminal, and the terminal supports placing an external SIM card and configuring an internal SIM card; the device comprises:
the determining module is used for determining that the detected target event is a hot plug event or a hot plug event of the external SIM card;
the control module is used for controlling a switching circuit in the terminal to be connected with the external SIM card when the target event is a hot plug event so as to electrify the external SIM card to work;
the control module is further configured to control the switching circuit to be connected with the built-in SIM card when the target event is a hot plug event, so that the built-in SIM card is powered on to operate.
7. The device of claim 6, wherein the switching circuit is a GPIO switching circuit, the GPIO switching circuit being configured to connect with the external SIM card or the internal SIM card; the determining module is specifically configured to:
judging whether the external SIM card is pulled out when the terminal is in a card state or not by detecting the current state of the GPIO switching circuit;
if the external SIM card is pulled out when the terminal is in a card state, determining that the external SIM card is a hot pull event;
if the external SIM card is not pulled out when the terminal is in a card-containing state, judging whether the external SIM card is inserted when the terminal is in a card-free state;
and if the external SIM card inserting operation exists when the terminal is in a card-free state, determining that the external SIM card inserting operation is a hot inserting event.
8. The apparatus of claim 6, wherein the switching circuit is a GPIO circuit; the control module is specifically configured to:
controlling a GPIO switching circuit to be connected with the external SIM card so as to electrify the external SIM card;
and triggering the initialization operation of the external SIM card, and executing the operation of electrifying the external SIM card.
9. A SIM card switching control apparatus, comprising: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executing the computer-executable instructions stored by the memory causes the at least one processor to perform the SIM card switching control method of any one of claims 1-5.
10. A computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and when a processor executes the computer-executable instructions, the SIM card switching control method according to any one of claims 1 to 5 is implemented.
CN202011089360.5A 2020-10-13 2020-10-13 SIM card switching control method, device, equipment and storage medium Pending CN114363455A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011089360.5A CN114363455A (en) 2020-10-13 2020-10-13 SIM card switching control method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011089360.5A CN114363455A (en) 2020-10-13 2020-10-13 SIM card switching control method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114363455A true CN114363455A (en) 2022-04-15

Family

ID=81090120

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011089360.5A Pending CN114363455A (en) 2020-10-13 2020-10-13 SIM card switching control method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114363455A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018082105A1 (en) * 2016-11-07 2018-05-11 华为技术有限公司 Method and device for switching on-vehicle service using external sim card
CN109067416A (en) * 2018-09-26 2018-12-21 广东小天才科技有限公司 A kind of method and Intelligent hardware for realizing SIM card hot plug and starting
CN109195189A (en) * 2018-10-08 2019-01-11 深圳市广和通无线股份有限公司 Double card switching method and apparatus

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018082105A1 (en) * 2016-11-07 2018-05-11 华为技术有限公司 Method and device for switching on-vehicle service using external sim card
CN109067416A (en) * 2018-09-26 2018-12-21 广东小天才科技有限公司 A kind of method and Intelligent hardware for realizing SIM card hot plug and starting
CN109195189A (en) * 2018-10-08 2019-01-11 深圳市广和通无线股份有限公司 Double card switching method and apparatus

Similar Documents

Publication Publication Date Title
CN105704332B (en) Mobile payment method and device
CN109495875B (en) SIM card selection method and device, electronic equipment and storage medium
WO2016173071A1 (en) Mobile terminal, and adaptive switching method and system for card slot therefor
CN104869619A (en) Single card dual standby long term evolution (LTE) terminal network control method and device
CN108882325A (en) Method for switching network, network switching device and mobile terminal
CN110351433A (en) A kind of method, apparatus and terminal device of double card switching
WO2014071774A1 (en) Method for registering terminal and terminal
CN111581994A (en) Near Field Communication (NFC) communication method and device and electronic equipment
CN103748958A (en) Multi-card mobile phone and display method
CN106537956B (en) User identification card control method and mobile terminal
CN113242542B (en) Network searching control method and device of mobile terminal and mobile terminal
KR20160096646A (en) Method and device for managing blacklist
CN114363455A (en) SIM card switching control method, device, equipment and storage medium
US9883051B2 (en) Method and system for usage of manual PLMN selection mode
CN107466087B (en) Network searching method and mobile terminal
CN109257734A (en) A kind of method and device for realizing Subscriber Identity Module switching
JP6254303B2 (en) User identification module protocol switching
CN108882222B (en) Method for realizing one card with multiple numbers of terminal
CN106507434B (en) Data processing method and device
CN113950044A (en) Method and device for identifying user identification card, terminal equipment and storage medium
CN115567901A (en) Method, device, equipment and storage medium for operating user identity identification card
CN114339721A (en) eSIM card number management method, storage medium, electronic device and apparatus
CN108574503B (en) Setting method of interception setting option and related equipment
CN109474721B (en) Method and system for mutually using different types of SIM cards and communication terminal
CN113692003A (en) Mode switching method and device of Wi-Fi module

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination