A detection method, terminal, user identification card, electronic device and storage medium

By disabling the polling instruction in the terminal and only retaining the hot-swap in-place detection function, the problem of high power consumption in the existing technology is solved, and real-time and efficiency are improved.

CN113837338BActive Publication Date: 2025-01-03SPREADTRUM COMMUNICATION (SHANGHAI) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111151683.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-29
Publication Date
2025-01-03
Estimated Expiration
2041-09-29

AI Technical Summary

Technical Problem

In the prior art, the terminal simultaneously executes polling instructions and hot-swap in-position detection functions, resulting in high power consumption and poor real-time performance.

Method used

By disabling the polling instruction in the terminal, when there is no STK application triggered by the polling instruction in the user identification card, only the hot-swap in-place detection function is retained, and configuration instructions are sent to the user identification card using the preset communication protocol to inform the user identification card. Its terminal supports disabling polling instructions and determines the timing of disabling polling instructions through target active commands.

Benefits of technology

On the basis of ensuring the real-time detection of the user identification card in-position state, the terminal power consumption is reduced and the detection efficiency is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113837338B_ABST
    Figure CN113837338B_ABST
Patent Text Reader

Abstract

The present application discloses a detection method, a terminal, a user identification card, an electronic device and a storage medium, which can improve the problem of high terminal power consumption caused by the terminal executing two detection methods for the user identification card in place status at the same time in the prior art. The detection method includes: the terminal sends a polling instruction to the user identification card, and determines that the user identification card is in place based on the first response information of the user identification card to the polling instruction; the terminal executes a hot plug in place detection function, and determines that the user identification card is in place based on the detection result of the hot plug in place detection function; when the terminal determines that the user identification card currently does not have a user identification card application toolbox STK application triggered based on the polling instruction, the terminal disables the polling instruction.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The embodiments of the present application relate to the field of terminal technology, and in particular to a detection method, a terminal, a user identification card, an electronic device, and a storage medium. [Background technology]

[0002] In the traditional method, polling instructions are usually used to perform in-place detection on the user identification card. At the same time, some user identification card application toolbox (SIM TOOL KIT, STK) applications in the user identification card also need to be triggered based on the polling instructions. However, the real-time performance of this detection method is poor. On this basis, a hot plug detection in-place detection function based on the user identification card is added. That is, in the prior art, the terminal needs to execute two in-place detection functions for the user identification card at the same time, which results in higher power consumption of the terminal. [Summary of the invention]

[0003] The embodiments of the present application provide a detection method, a terminal, a user identification card, an electronic device and a storage medium, which can improve the problem of high terminal power consumption caused by the terminal simultaneously executing two detection methods for the user identification card in place status in the prior art.

[0004] In a first aspect, an embodiment of the present application provides a detection method, which is applied to a terminal, wherein the terminal is equipped with a user identification card, and the terminal supports a hot-swap in-place detection function for the user identification card, the method comprising:

[0005] The terminal sends a polling instruction to the user identification card, and determines that the user identification card is in a state based on first response information of the user identification card to the polling instruction;

[0006] The terminal executes the hot-swap in-place detection function, and determines that the subscriber identification card is in-place based on the detection result of the hot-swap in-place detection function;

[0007] When the terminal determines that the subscriber identity card currently does not have a subscriber identity card application toolkit STK application triggered by the polling instruction, the terminal disables the polling instruction.

[0008] In the embodiment of the present application, the terminal determines that the user identification card is in the in-place state by interacting with the user identification card based on the polling instruction, which can be considered as the first in-place detection method. The terminal executes the hot-swap in-place detection function for the user identification card, and determines that the user identification card is in the in-place state based on the detection result, which can be considered as the second in-place detection method. In order to take into account that some STK applications in the user identification card that are triggered based on the polling instruction can be used normally and to ensure the real-time performance of the in-place detection of the user identification card, the terminal executes the first in-place detection method and the second in-place detection method at the same time in the initial state. When the terminal determines that the STK application executed in the current user identification card does not need to rely on the polling instruction, the polling instruction can be disabled, which is equivalent to disabling the first in-place detection method, that is, only retaining the second in-place detection method. Compared with the prior art in which two in-place detection methods are executed at the same time, the terminal power consumption can be reduced to a certain extent on the basis of ensuring the real-time performance of the in-place detection of the user identification card.

[0009] Optionally, before the terminal determines that the user identification card currently does not have an STK application executed based on the polling instruction, the method further includes:

[0010] The terminal sends a configuration instruction in advance to the user identification card based on a preset communication protocol, and the configuration instruction indicates that the terminal supports disabling the polling instruction.

[0011] In the embodiment of the present application, the terminal can send a configuration instruction to the user identification card through a preset communication protocol, thereby informing the user identification card that the terminal itself can support disabling polling instructions, so that the user identification card can inform the terminal when to disable the polling instruction according to its actual situation.

[0012] Optionally, the preset communication protocol includes at least a preset field, and the preset field is used to indicate that the terminal supports disabling the polling instruction.

[0013] In an embodiment of the present application, a preset field is defined in the preset communication protocol, and the preset field is used to define that the terminal can support disabling polling instructions. That is, the preset field can indicate two states: the first presence detection mode and the second presence detection mode are executed simultaneously, and only the second presence detection mode is executed.

[0014] Optionally, the method further includes:

[0015] The terminal receives second response information from the subscriber identification card in response to the configuration instruction, where the second response information indicates that the subscriber identification card has received the configuration instruction.

[0016] In an embodiment of the present application, after the user identification card receives the configuration instruction of the terminal, it can feedback second response information to the terminal, thereby informing the terminal that the user identification card currently knows that the terminal can support disabling polling instructions, thereby avoiding the terminal from repeatedly sending configuration instructions to the user identification card.

[0017] Optionally, the terminal determines that the user identification card currently does not have an STK application executed based on the polling instruction, including:

[0018] If the terminal determines that the first response information includes a preset status word, the terminal sends an acquisition instruction to the subscriber identification card, the preset status word is used to indicate that the subscriber identification card has a target active command that needs to be sent to the terminal, the target active command is used to instruct the terminal to disable the polling instruction, and the acquisition instruction is used to acquire the target active command of the subscriber identification card;

[0019] The terminal receives the target active command from the subscriber identification card to determine that the subscriber identification card currently does not have the STK application triggered based on the polling instruction.

[0020] In the embodiment of the present application, when the user identification card determines that the STK application currently executed by itself does not need to rely on the polling instruction in the first in-place detection mode, a preset status word can be fed back to the terminal, that is, the terminal is informed that the user identification card currently has a target active command that needs to be sent to the terminal, and the target active command can be considered to be used to instruct the terminal to disable the polling instruction. After obtaining the preset status word, the terminal can request the user identification card to obtain the target active command. When the terminal receives the above-mentioned target active command from the user identification card, it can be determined that the user identification card currently does not have an STK application triggered based on the polling instruction.

[0021] Optionally, the terminal disabling the polling instruction includes:

[0022] The terminal disables the polling instruction based on the target proactive command.

[0023] In the embodiment of the present application, the terminal may disable the polling instruction based on the target active command obtained from the user identification card, so that the timing of disabling the polling instruction may be determined more accurately.

[0024] Optionally, the method further includes:

[0025] The terminal sends a feedback instruction for the target active command to the subscriber identity card, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

[0026] In the embodiment of the present application, after disabling the polling instruction, the terminal can feed back information to the user identification card, thereby preventing the user identification card from repeatedly sending the target active command to the terminal.

[0027] In a second aspect, an embodiment of the present application provides a detection method, which is applied to a user identification card, wherein the user identification card is installed in a terminal, and the terminal supports a hot-swap in-place detection function for the user identification card. When the terminal determines that the user identification card is in-place based on a detection result of the hot-swap in-place detection function, the method includes:

[0028] The user identification card receives the polling instruction from the terminal, and sends a first response message to the terminal, so that the terminal determines that the user identification card is in the in-place state based on the first response message;

[0029] When the subscriber identification card determines that there is no subscriber identification card application toolbox STK application currently triggered by the polling instruction, a target active command is sent to the terminal to make the terminal disable the polling instruction.

[0030] Optionally, before sending the target active command to the terminal, the method further includes:

[0031] The user identification card receives a configuration instruction sent from the terminal based on a preset communication protocol, where the configuration instruction is used to indicate that the terminal supports disabling the polling instruction.

[0032] Optionally, the preset communication protocol includes at least a preset field, and the preset field is used to indicate that the terminal supports disabling the polling instruction.

[0033] Optionally, the method further includes:

[0034] The subscriber identification card sends second response information to the terminal for the configuration instruction, where the second response information indicates that the subscriber identification card has received the configuration instruction.

[0035] Optionally, if the first response information includes a preset status word, the preset status word is used to indicate that the user identification card has a target active command that needs to be sent to the terminal, and the target active command is used to instruct the terminal to disable the polling instruction, sending the target active command to the terminal includes:

[0036] The user identification card receives an acquisition instruction from the terminal, where the acquisition instruction is used to acquire the target active command;

[0037] The subscriber identification card responds to the acquisition instruction and sends the target active command to the terminal.

[0038] Optionally, after sending the target active command to the terminal, the method further includes:

[0039] The subscriber identification card receives a feedback instruction from the terminal for the target active command, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

[0040] In a third aspect, an embodiment of the present application provides a terminal, wherein the terminal is equipped with a user identification card, and the terminal supports a hot-swap in-place detection function for the user identification card, and the terminal includes:

[0041] a first detection unit, configured to send a polling instruction to the subscriber identification card, and determine that the subscriber identification card is in a present state based on first response information of the subscriber identification card to the polling instruction;

[0042] A second detection unit, used for executing the hot-swap in-place detection function, and determining that the subscriber identification card is in-place based on the detection result of the hot-swap in-place detection function;

[0043] The disabling unit is used to disable the polling instruction when it is determined that the subscriber identification card currently does not have a subscriber identification card application toolbox STK application triggered by the polling instruction.

[0044] Optionally, the terminal further includes:

[0045] The sending unit is used to pre-send a configuration instruction to the user identification card based on a preset communication protocol, wherein the configuration instruction indicates that the terminal supports disabling the polling instruction.

[0046] Optionally, the preset communication protocol includes at least a preset field, and the preset field is used for the terminal to indicate support for disabling the polling instruction.

[0047] Optionally, the terminal further includes:

[0048] The receiving unit is configured to receive second response information from the user identification card to the configuration instruction, wherein the second response information indicates that the user identification card has received the configuration instruction.

[0049] Optionally, the disabling unit is specifically used to:

[0050] If it is determined that the first response information includes a preset status word, sending an acquisition instruction to the subscriber identification card, the preset status word is used to indicate that the subscriber identification card has a target active command that needs to be sent to the terminal, the target active command is used to instruct the terminal to disable the polling instruction, and the acquisition instruction is used to acquire the target active command of the subscriber identification card;

[0051] The target active command is received from the subscriber identification card to determine that the STK application triggered based on the polling instruction does not currently exist in the subscriber identification card.

[0052] Optionally, the disabling unit is specifically used to:

[0053] The polling instruction is disabled based on the target proactive command.

[0054] Optionally, the sending unit is further used for:

[0055] A feedback instruction for the target active command is sent to the subscriber identification card, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

[0056] In a fourth aspect, an embodiment of the present application provides a user identification card, wherein the user identification card is installed in a terminal, and the terminal supports a hot-swap in-place detection function for the user identification card. When the terminal determines that the user identification card is in-place based on a detection result of the hot-swap in-place detection function, the user identification card includes:

[0057] a processing unit, configured to receive a polling instruction from the terminal, and send a first response message to the terminal, so that the terminal determines that the subscriber identification card is in a present state based on the first response message;

[0058] The sending unit is used to send a target active command to the terminal when it determines that there is no subscriber identity card application toolbox STK application triggered by the polling instruction, so that the terminal disables the polling instruction.

[0059] Optionally, the user identification card further includes:

[0060] The receiving unit is used to receive a configuration instruction sent from the terminal based on a preset communication protocol, wherein the configuration instruction is used to indicate that the terminal supports disabling the polling instruction.

[0061] Optionally, the preset communication protocol includes at least a preset field, and the preset field is used to indicate that the terminal supports disabling the polling instruction.

[0062] Optionally, the sending unit is further used for:

[0063] Sending second response information to the configuration instruction to the terminal, wherein the second response information indicates that the subscriber identification card has received the configuration instruction.

[0064] Optionally, if the first response information includes a preset status word, the preset status word is used to indicate that the user identification card has a target active command that needs to be sent to the terminal, and the target active command is used to instruct the terminal to disable the polling instruction, and the sending unit is specifically used to:

[0065] receiving an acquisition instruction from the terminal, wherein the acquisition instruction is used to acquire the target active command;

[0066] In response to the acquisition instruction, the target active command is sent to the terminal.

[0067] Optionally, the receiving unit is further used for:

[0068] A feedback instruction for the target active command is received from the terminal, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

[0069] In a fifth aspect, an embodiment of the present invention provides an electronic device, comprising a processor and a memory, wherein the processor is configured to implement the steps of the method described in any embodiment of the first aspect or the second aspect when executing a computer program stored in the memory.

[0070] In a sixth aspect, an embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the method described in any embodiment of the first aspect or the second aspect are implemented.

[0071] It should be understood that the second to sixth aspects of the embodiments of the present invention are consistent with the technical solutions of the first aspect of the embodiments of the present invention, and the beneficial effects achieved by each aspect and the corresponding feasible implementation methods are similar and will not be described in detail.

Brief Description of the Drawings

[0072] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0073] Figure 1 A schematic diagram of a detection method provided in an embodiment of the present application;

[0074] Figure 2 A schematic diagram of a flow chart of a first on-site detection method provided in an embodiment of the present application;

[0075] Figure 3 A schematic diagram of a process of disabling a polling instruction provided in an embodiment of the present application;

[0076] Figure 4 A schematic diagram of a detection method provided in an embodiment of the present application;

[0077] Figure 5 A schematic diagram of the structure of a terminal provided in an embodiment of the present application;

[0078] Figure 6 A schematic diagram of the structure of a user identification card provided in an embodiment of the present application;

[0079] Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application;

[0080] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. [Specific implementation method]

[0081] In order to better understand the technical solution of this specification, the embodiments of the present application are described in detail below with reference to the accompanying drawings.

[0082] It should be clear that the described embodiments are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this specification.

[0083] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit this specification. The singular forms of "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.

[0084] At present, terminals are equipped with user identification cards, such as SIM (Subscriber Identity Module) cards or USIM (Universal Subscriber Identity Module) cards, so that the terminals can access the mobile network and realize the Internet access and voice call functions. Of course, the user identification card can also be of other types, which are not particularly limited here. Usually, a plug-in card holder is used to fix the user identification card. In the process of use, the user identification card may become loose due to unpredictable factors, resulting in the terminal being unable to access the mobile network.

[0085] The inventor of the present application has found that in the traditional method, the terminal usually performs on-site detection of the user identification card based on software. For example, the terminal performs on-site detection of the user identification card based on polling instructions, which is equivalent to the first on-site detection method. At the same time, some STK applications in the user identification card also need to rely on polling instructions to trigger. The disadvantage of this on-site detection method is that there is a time interval between polling instructions, resulting in poor real-time detection of the user identification card on-site status. On this basis, the terminal adds a hardware-based on-site detection of the user identification card. For example, the terminal performs on-site detection of the user identification card based on the hot-swap on-site detection function, which is equivalent to the second on-site detection method. That is to say, in the prior art, there are two on-site detection methods for the user identification card in the same terminal at the same time, and no matter which of the above methods is used, the power supply is through the terminal, resulting in high power consumption of the terminal.

[0086] In view of this, an embodiment of the present application provides a detection method, in which, when it is determined that the STK application in the user identification card does not need to rely on polling instructions to be triggered, the polling instructions can be disabled, which is equivalent to disabling the first in-place detection method and retaining only the second in-place detection method. Compared with the prior art of simultaneously executing two in-place detection methods, the terminal power consumption can be reduced to a certain extent.

[0087] The following is an introduction to the technical solution provided by the embodiment of the present application in conjunction with the accompanying drawings. Figure 1 , an embodiment of the present invention provides a detection method, which can be applied to a terminal, and the terminal supports the installation of a user identification card, such as a SIM card or a USIM card. Of course, other types of user identification cards can also be installed, and there is no special restriction here. The terminal can be a smart phone (such as an Android phone, an IOS phone), a tablet computer, a smart wearable device, etc., and there is no special restriction on the specific type of the terminal. The process of the method is described as follows:

[0088] Step 101: the terminal sends a polling instruction to a subscriber identity card, and determines whether the subscriber identity card is in a present state based on first response information of the subscriber identity card to the polling instruction.

[0089] In the embodiment of the present application, the detection of the in-place state of the user identification card can be realized based on the software mode. For example, the terminal can send a polling instruction to the user identification card, and determine whether the user identification card is in the in-place state based on the response information (for example, the first response information) fed back by the user identification card to the above-mentioned polling instruction. For the convenience of description below, the detection mode in which the terminal interacts with the user identification card based on the polling instruction to determine whether the user identification card is in the in-place state is referred to as the first in-place detection mode. The first in-place detection mode will be specifically described below.

[0090] See also Figure 2 , is a flow chart of the first in-situ detection method provided for the implementation of this application. The detection process of the first in-situ detection method is described as follows:

[0091] Step 201: The terminal sends a STATUS command to the subscriber identity card.

[0092] The terminal may actively send a STATUS command to the user identification card, and then determine whether the user identification card is in place based on the first response information fed back by the user identification.

[0093] Step 202: The subscriber identity card returns correct response data.

[0094] If the terminal confirms that the first response information returned by the SIM card is correct response data, it can be determined that the SIM card is currently in the on-site state, that is, the terminal determines for the first time that the SIM card is in the on-site state.

[0095] Step 203: The terminal sends a STATUS command to the subscriber identity card.

[0096] When the terminal determines for the first time that the SIM card is in the on-site state, it can send a STATUS command to the SIM card again after a preset time interval, i.e., start a new round of SIM card on-site state detection. For example, the preset time can be 10s, 20s, or 30s, and can also be flexibly set according to actual conditions, and is not particularly limited here.

[0097] Step 204: The subscriber identity card returns error response data / no response data.

[0098] If the terminal confirms that the first response information returned by the user identification card is error response data or no response data (i.e., no first response information), it can be determined that the user identification card is not currently in the in-place state. For example, the user identification card is loose or damaged. The reasons for causing the user identification card to be in the out-of-place state are not particularly limited here.

[0099] It should be understood that when the on-site status of the user identification card is detected by the first on-site detection method, the terminal will send a STATUS command to the user identification card at a preset interval. The above step 204 is only used as an example to illustrate how the terminal determines that the user identification card is not in the on-site state, and does not mean that the terminal will definitely receive error response data or no response data returned by the user identification card after sending the STATUS command for the second time.

[0100] Step 102: The terminal executes a hot-swap in-place detection function, and determines that the subscriber identity card is in-place based on a detection result of the hot-swap in-place detection function.

[0101] In the embodiment of the present application, the detection of the user identification card in place state can be realized based on the hardware method. For example, if the terminal supports the hot plug in place detection function for the user identification card, then the terminal can determine whether the user identification card is in place by executing the hot plug in place detection function and based on the detection result of the hot plug in place detection function. For example, if the detection result of the terminal executing the hot plug in place detection function is a high level, it is determined that the user identification card is in place; if the terminal executes the hot plug in place detection function The detection result is a low level, it is determined that the user identification card is not in place. Of course, the opposite judgment logic can also be used. If the terminal executes the hot plug in place detection function The detection result is a low level, it is determined that the user identification card is in place; if the terminal executes the hot plug in place detection function. The detection result is a high level, it is determined that the user identification card is not in place. In this application, the correspondence between high and low levels and the user identification card in place state is not particularly limited. For the convenience of description, the terminal executes the hot-swap presence detection function and determines whether the subscriber identity card is in place based on the detection result of the hot-swap presence detection function as the second presence detection mode.

[0102] Considering that, on the one hand, the first in-place detection method is a detection method of writing standards, and some STK applications in the user identification card also rely on the polling instructions in the first in-place detection method to be triggered, but there is a problem of poor real-time performance; on the other hand, the second in-place detection method can perform real-time detection of the in-place status of the user identification card. Therefore, in order to take into account the normal use of some STK applications in the user identification card that are triggered based on polling instructions and to ensure the real-time performance of the in-place detection of the application identification card, in the initial state, the terminal can simultaneously execute the first in-place detection method and the second in-place detection method.

[0103] Step 103: When the terminal determines that the subscriber identity card currently does not have a subscriber identity card application toolbox STK application triggered by the polling instruction, the terminal disables the polling instruction.

[0104] When the terminal executes the first presence detection method and the second presence detection method at the same time, considering that some STK applications in the user identification card that need to rely on polling instructions to trigger do not need to be executed all the time, for example, this part of the STK application may only run after a preset period of time after the terminal is turned on, or this part of the STK application may only run at fixed times every day or every week. Therefore, in an embodiment of the present application, when the above-mentioned STK application is not running, the terminal can prohibit sending polling instructions, that is, deactivate the first presence detection method, and only retain the second presence detection method, thereby achieving the purpose of reducing terminal power consumption.

[0105] As a possible implementation, when the terminal determines that the subscriber identity card currently does not have an STK application triggered based on a polling instruction, the terminal may disable the polling instruction.

[0106] Considering that the user identification card itself knows when some STK applications in the user identification card that need to rely on polling instructions to trigger are running or not running, but the terminal does not know when the above-mentioned some STK applications do not need to run, the following specifically explains how the terminal determines that there is currently no STK application triggered by polling instructions on the user identification card.

[0107] After the terminal sends a STATUS instruction to the user identification card at a certain time, the user identification card itself can judge whether there is a STK application that needs to be dependent on the polling instruction triggered. If the user identification card determines that there is no STK application that depends on the polling instruction to trigger execution, the user identification card can feed back corresponding response information to the terminal, for example, a first response message, at least a preset status word is carried in the first response message, and the preset status word can be used to inform the terminal that the user identification card has a target active command that wants to be sent to the terminal, and the target active command can be considered as the user identification card wanting to indicate that the terminal can currently disable the polling instruction. After receiving the first response information from the user identification card, the terminal can send an acquisition command to the user identification card, and the acquisition command is used to obtain the above-mentioned target active command from the user identification card. After receiving the acquisition command from the terminal, the user identification card will send the target active command used to indicate that the terminal disables the polling instruction to the terminal. The terminal receives the target active command from the user identification card, and just can determine that the user identification card does not currently exist the STK application triggered based on the polling instruction.

[0108] Furthermore, in the embodiment of the present application, after receiving the above-mentioned target active command, the terminal can control itself to disable the polling instruction based on the target active command, so as to more accurately determine the timing of disabling the polling instruction.

[0109] In some embodiments, whether the terminal supports the disable polling instruction is unknown to the user identification card. If the terminal determines to inform the user identification card that it does not support the disable polling instruction only after the user identification card has sent the target active command to the terminal, it will cause a waste of command resources.

[0110] Therefore, in the embodiment of the present application, the terminal can inform the user identification card in advance whether it supports the disable polling instruction. For example, if the terminal informs the user identification card in advance that it supports the disable polling instruction, the user identification card will feedback the preset status word to the terminal and send the target active command; if the terminal informs the user identification card in advance that it does not support the disable polling instruction, the user identification card will not feedback the preset status word to the terminal and send the target active command, thereby saving command resources.

[0111] As a possible implementation method, before the terminal determines that the user identification card currently does not have an STK application executed based on a polling instruction, the terminal can pre-send a configuration instruction to the user identification card based on a preset communication protocol. The configuration instruction can be used to characterize that the terminal supports disabling polling instructions. Then, after the user identification card receives the above configuration instruction from the terminal, it can be known that the terminal supports disabling polling instructions, that is, there is a possibility of disabling the first in-place detection method.

[0112] It should be understood that the preset communication protocol may include at least a preset field, which may be considered as a newly added field based on the original communication protocol (TS31.111) between the terminal and the user identification card, and the preset field defines that the terminal can support the disabling of the polling instruction. The specific definition inside the preset field should follow the standard of the original communication protocol, which will not be repeated here. At the same time, the initiator (user identification card) and the destination (terminal) of the target active command may also be defined in the preset communication protocol.

[0113] For example, "00" defined in the preset field indicates that the terminal does not support disabling polling instructions, that is, the terminal must execute the first presence detection method and the second presence detection method at the same time; "01" defined in the preset field indicates that the terminal supports disabling polling instructions, that is, the terminal can only execute the second presence detection method.

[0114] In some embodiments, after the terminal sends a configuration instruction to the user identification card for the first time, it is not sure whether the user identification card has received the configuration instruction. Therefore, in order to avoid the terminal repeatedly sending the configuration instruction to the user identification card, the user identification card can inform the terminal after receiving the above configuration instruction.

[0115] As a possible implementation, after receiving the configuration instruction, the user identification card can send a second response message to the terminal. The second response message is used to indicate that the user identification card has received the configuration instruction. Then, when the terminal receives the second response message, it can be known that the user identification card has received the configuration instruction.

[0116] In some embodiments, if the terminal does not inform the SIM card after disabling the polling instruction, the SIM card may think that the terminal has not received the target active command it sent, and the SIM card may repeatedly send the target active command to the terminal, resulting in a waste of resources.

[0117] Therefore, in the embodiment of the present application, after successfully disabling the polling instruction, the terminal may inform the user identification card of the message that the polling instruction has been disabled, thereby preventing the user identification card from repeatedly sending the target active command to the terminal.

[0118] As a possible implementation, the terminal may send a feedback instruction for the target active command to the user identification card, where the feedback instruction is used to indicate that the polling instruction has been successfully disabled. After receiving the feedback instruction, the user identification card may know that the polling instruction has been successfully disabled.

[0119] See also Figure 3 ,The following describes the detection instructions in detail from an overall perspective.

[0120] Step 301: The terminal sends a configuration instruction to a subscriber identity card.

[0121] Step 302: The subscriber identity card sends a second response message to the terminal.

[0122] Step 303: The terminal sends a STATUS command to the subscriber identity card.

[0123] Step 304: The subscriber identity card sends a first response message to the terminal.

[0124] Step 305: The terminal sends an acquisition instruction to the user.

[0125] Step 306: The subscriber identity card sends a target active command to the terminal.

[0126] Step 307: The terminal sends a feedback instruction to the subscriber identity card.

[0127] It should be understood that step 301 may be performed before step 303, or step 301 may be performed after step 303, or step 301 and step 303 may be performed simultaneously, and the present application does not impose any particular restriction on the execution order of step 301 and step 303. The following description is made by taking step 301 being performed before step 303 as an example.

[0128] First, the terminal can actively send a configuration instruction to the user identification card (i.e., execute step 301), and the configuration instruction is used to indicate that the terminal supports disabling polling instructions. Then, after the user identification card receives the configuration instruction, it can be known that the terminal supports disabling polling instructions, and then the user identification card will also send a second response message to the terminal (i.e., execute step 302). The second response message is used to inform the terminal that the user identification card has received the above-mentioned configuration instruction, that is, to inform the terminal that the user identification card has known that the terminal supports disabling polling instructions.

[0129] After knowing that the user identification card receives the configuration instruction, the terminal can send the STATUS instruction (i.e., perform step 303) to the user identification card. After receiving the STATUS instruction, if the user identification card determines that the user identification card does not currently have the STK application triggered based on the polling instruction, the first response information can be sent to the terminal (i.e., perform step 304). At this moment, the first response information can include a preset status word, which is used to inform the user identification card that there is a target active command that needs to be sent to the terminal. It should be understood that in this case, the first response information can also be used to inform the terminal that the user identification card is currently in the in-position state. After the terminal receives the above-mentioned first response information, it can send an acquisition instruction (i.e., perform step 305) to the user identification card, and the acquisition instruction is used to obtain the target active command from the user identification card. After receiving the acquisition instruction from the terminal, the user identification card can send the target active command (i.e., perform step 306) to the terminal. After the terminal receives the above-mentioned target active command, it can be known that the user identification card does not currently have the STK application triggered based on the polling instruction, so the terminal can disable the polling instruction based on the target active command. When the terminal determines that the polling instruction is disabled successfully, it can send a feedback instruction to the SIM card (i.e., execute step 307), and the feedback instruction is used to inform the SIM card that the polling instruction is disabled successfully. Then, after the SIM card receives the feedback instruction from the terminal, the SIM card can determine that the polling instruction is disabled successfully.

[0130] It should be understood that after disabling the polling instruction, if the user identification card determines that it currently has an STK application triggered based on the polling instruction, then it can send an active command to the terminal to reopen the polling instruction. After receiving the above active command, the terminal can reopen the polling instruction, so that the STK application triggered based on the polling instruction in the user identification card can be used normally.

[0131] See also Figure 4Based on the same inventive concept, an embodiment of the present application further provides a detection method, which is applied to a user identification card, the user identification card is installed in a terminal, and the terminal supports a hot-swap in-place detection function for the user identification card. When the terminal determines that the user identification card is in-place based on the detection result of the hot-swap in-place detection function, the process of the method is described as follows:

[0132] Step 401: the subscriber identity card receives a polling instruction from a terminal, and sends a first response message to the terminal, so that the terminal determines that the subscriber identity card is in a present state based on the first response message.

[0133] Step 402: When the subscriber identity card determines that there is no subscriber identity card application toolbox STK application triggered by the polling instruction, it sends a target active command to the terminal to make the terminal disable the polling instruction.

[0134] The specific implementation of step 401-step 402 can refer to the specific content on the terminal side, which will not be repeated here.

[0135] See also Figure 5 Based on the same inventive concept, an embodiment of the present application also provides a terminal, which is equipped with a user identification card and supports a hot-swap in-place detection function for the user identification card. The terminal includes: a first detection unit 501, a second detection unit 502 and a disabling unit 503.

[0136] The first detection unit 501 is used to send a polling instruction to the user identification card, and determine whether the user identification card is in a position state based on the first response information of the user identification card to the polling instruction;

[0137] A second detection unit 502 is used to perform the hot-swap in-place detection function and determine whether the subscriber identity card is in-place based on the detection result of the hot-swap in-place detection function;

[0138] The disabling unit 503 is used to disable the polling instruction when it is determined that there is no subscriber identity card application toolkit STK application triggered by the polling instruction currently on the subscriber identity card.

[0139] Optionally, the terminal further includes:

[0140] The sending unit is used to send a configuration instruction to the user identification card in advance based on a preset communication protocol, and the configuration instruction indicates that the terminal supports the disabling of the polling instruction.

[0141] Optionally, the preset communication protocol includes at least a preset field, and the preset field is used to indicate support for disabling the polling instruction.

[0142] Optionally, the terminal further includes:

[0143] The receiving unit is used to receive second response information from the user identification card to the configuration instruction, wherein the second response information indicates that the user identification card has received the configuration instruction.

[0144] Optionally, the disabling unit 503 is specifically configured to:

[0145] If it is determined that the first response information includes a preset status word, sending an acquisition instruction to the user identification card, the preset status word is used to indicate that the user identification card has a target active command that needs to be sent to the terminal, the target active command is used to instruct the terminal to disable the polling instruction, and the acquisition instruction is used to acquire the target active command of the user identification card;

[0146] A target active command is received from a subscriber identity card to determine that the subscriber identity card currently does not have an STK application triggered based on a polling instruction.

[0147] Optionally, the disabling unit 503 is specifically configured to:

[0148] Disables polling instructions based on target proactive commands.

[0149] Optionally, the sending unit is further configured to:

[0150] A feedback instruction for the target active command is sent to the subscriber identification card, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

[0151] See also Figure 6 Based on the same inventive concept, an embodiment of the present application also provides a user identification card, which is installed in a terminal. The terminal supports a hot-swap in-place detection function for the user identification card. When the terminal determines that the user identification card is in-place based on the detection result of the hot-swap in-place detection function, the user identification card includes: a processing unit 601 and a sending unit 602.

[0152] The processing unit 601 is used to receive a polling instruction from a terminal and send a first response message to the terminal, so that the terminal determines that the user identification card is in a state of being in place based on the first response message;

[0153] The sending unit 602 is used to send a target active command to the terminal to disable the polling instruction when it is determined that there is no subscriber identity card application toolbox STK application triggered by the polling instruction.

[0154] Optionally, the user identification card further includes:

[0155] The receiving unit is used to receive a configuration instruction sent from a terminal based on a preset communication protocol, where the configuration instruction is used to indicate that the terminal supports disabling the polling instruction.

[0156] Optionally, the preset communication protocol includes at least a preset field, and the preset field is used to indicate that the terminal supports disabling the polling instruction.

[0157] Optionally, the sending unit 602 is further configured to:

[0158] A second response message for the configuration instruction is sent to the terminal, wherein the second response message indicates that the user identification card has received the configuration instruction.

[0159] Optionally, if the first response information includes a preset status word, the preset status word is used to indicate that the user identification card has a target active command that needs to be sent to the terminal, and the target active command is used to instruct the terminal to disable the polling instruction, and the sending unit 602 is specifically used to:

[0160] receiving an acquisition instruction from the terminal, wherein the acquisition instruction is used to acquire the target active command;

[0161] In response to the acquisition instruction, the target active command is sent to the terminal.

[0162] Optionally, the receiving unit is further configured to:

[0163] A feedback instruction for a target active command is received from a terminal, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

[0164] See also Figure 7 Based on the same inventive concept, the embodiment of the present application further provides an electronic device 100, which may include at least one processor, and the at least one processor is used to execute a computer program stored in a memory to implement the embodiment of the present application. Figure 1 The steps of the detection method are shown.

[0165] Optionally, the processor may specifically be a central processing unit, a specific ASIC, or one or more integrated circuits for controlling program execution.

[0166] Optionally, the electronic device 100 may further include a memory connected to at least one processor, and the memory may include ROM, RAM, and disk storage. The memory is used to store data required by the processor when it is running, that is, it stores instructions that can be executed by at least one processor. At least one processor executes the instructions stored in the memory to execute the following steps: Figure 1 The method shown in the figure. Wherein, the number of memories is one or more.

[0167] The physical devices corresponding to the first detection unit 501, the second detection unit 502 and the disabling unit 503 can all be the aforementioned processors. Figure 1Therefore, for the functions that can be realized by each functional module in the electronic device, please refer to Figure 1 The corresponding description in the illustrated embodiment will not be repeated here.

[0168] The electronic device 100 may be a smart electronic device such as a smart phone or a tablet computer, and this embodiment does not limit the form of the electronic device.

[0169] Instance, Figure 7 Taking a smart phone as an example, a schematic diagram of the structure of the electronic device 100 is shown. Figure 7 As shown, the electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc.

[0170] It is to be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0171] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0172] The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of instruction fetching and execution.

[0173] The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0174] In some embodiments, the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0175] The charging management module 140 is used to receive charging input from a charger.

[0176] The power management module 141 is used to connect the battery 142 , the charging management module 140 and the processor 110 .

[0177] In some embodiments, the antenna 1 of the electronic device 100 is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time-division code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technology. The GNSS may include a global positioning system (GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS) and / or a satellite based augmentation system (SBAS).

[0178] The electronic device 100 implements the display function through a GPU, a display screen 194, and an application processor.

[0179] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel.

[0180] The ISP is used to process data fed back by the camera 193 .

[0181] The camera 193 is used to capture still images or videos.

[0182] The digital signal processor is used to process digital signals, and can process not only digital image signals but also other digital signals. For example, when the electronic device 100 is selecting a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

[0183] Video codecs are used to compress or decompress digital videos. The electronic device 100 may support one or more video codecs. Thus, the electronic device 100 may play or record videos in a variety of coding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0184] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function, such as storing music, video and other files in the external memory card.

[0185] The internal memory 121 can be used to store computer executable program codes, which include instructions. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area may store data created during the use of the electronic device 100 (such as audio data, a phone book, etc.), etc. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc. The processor 110 executes various functional applications and data processing of the electronic device 100 by running instructions stored in the internal memory 121, and / or instructions stored in a memory provided in the processor.

[0186] The electronic device 100 can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0187] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals.

[0188] The speaker 170A, also called a "horn", is used to convert audio electrical signals into sound signals.

[0189] The receiver 170B, also called a "handset", is used to convert audio electrical signals into sound signals.

[0190] Microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals.

[0191] The earphone interface 170D is used to connect a wired earphone and can be a USB interface 130 or a 3.5 mm open mobile terminal platform (OMTP) standard interface or a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0192] Buttons 190 include a power button, a volume button, and the like.

[0193] Motor 191 can generate vibration prompts.

[0194] Indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, messages, missed calls, notifications, etc.

[0195] The SIM card interface 195 is used to connect a SIM card. The SIM card can be connected to and separated from the electronic device 100 by inserting it into the SIM card interface 195 or pulling it out from the SIM card interface 195. The electronic device 100 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, and the like. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the multiple cards can be the same or different. The SIM card interface 195 can also be compatible with different types of SIM cards. The SIM card interface 195 can also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as calls and data communications. In some embodiments, the electronic device 100 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.

[0196] The present application also provides a computer storage medium, wherein the computer storage medium stores computer instructions, and when the computer instructions are executed on a computer, the computer executes Figure 1 The method described.

[0197] See also Figure 8 Based on the same inventive concept, the embodiment of the present application further provides an electronic device 200, which may be a user identification card, and includes at least one processor 210, which is used to execute a computer program stored in a memory to implement the embodiment of the present application. Figure 4 The steps of the detection method are shown.

[0198] Optionally, the processor 210 may specifically be a central processing unit, a specific ASIC, or one or more integrated circuits for controlling program execution.

[0199] Optionally, the electronic device may further include a memory 211 connected to the at least one processor 210, and the memory 211 may include a ROM, a RAM, and a disk memory. The memory 211 is used to store data required by the processor 210 when it is running, that is, to store instructions that can be executed by the at least one processor 210. The at least one processor 210 executes or Figure 4 The method shown. The number of the memory 211 is one or more. The memory 211 is Figure 8 However, it should be noted that the memory 211 is not a mandatory functional module, so Figure 8 Shown by dotted lines.

[0200] The physical devices corresponding to the processing unit 601 and the sending unit 602 may be the aforementioned processor 210. The electronic device may be used to execute or Figure 4 Therefore, for the functions that can be realized by each functional module in the electronic device, please refer to Figure 4 The corresponding description in the illustrated embodiment will not be repeated here.

[0201] The present application also provides a computer storage medium, wherein the computer storage medium stores computer instructions, and when the computer instructions are executed on a computer, the computer executes Figure 4 The method described.

[0202] The above description is only a preferred embodiment of this specification and is not intended to limit this specification. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of this specification should be included in the scope of protection of this specification.

Claims

1. A detection method, characterized in that: Applied to a terminal, the terminal is equipped with a user identification card, and the terminal supports a hot-swap in-place detection function for the user identification card. The method includes: The terminal sends a polling instruction to the user identification card, and determines that the user identification card is in a state based on first response information of the user identification card to the polling instruction; The terminal executes the hot-swap in-place detection function, and determines that the subscriber identification card is in-place based on the detection result of the hot-swap in-place detection function; When the terminal determines based on a target proactive command that the user identification card currently does not have a user identification card application toolbox STK application triggered by the polling instruction, the terminal disables the polling instruction. The target proactive command is obtained by the terminal from the user identification card according to a preset status word included in the first response information, and the target proactive command is used to indicate that the terminal is allowed to disable the polling instruction.

2. The method according to claim 1, characterized in that Before the terminal determines that the user identification card currently does not have an STK application executed based on the polling instruction, the method further includes: The terminal sends a configuration instruction in advance to the user identification card based on a preset communication protocol, and the configuration instruction indicates that the terminal supports disabling the polling instruction.

3. The method according to claim 2, characterized in that The preset communication protocol includes at least a preset field, and the preset field is used to indicate that the terminal supports disabling the polling instruction.

4. The method according to any one of claims 2 or 3, characterized in that: The method further comprises: The terminal receives second response information from the subscriber identification card in response to the configuration instruction, where the second response information indicates that the subscriber identification card has received the configuration instruction.

5. The method according to claim 1, characterized in that The terminal determines, based on the target active command, that the user identification card currently does not have an STK application triggered by the polling instruction, including: If the terminal determines that the first response information includes the preset status word, the terminal sends an acquisition instruction to the subscriber identification card, the preset status word is used to indicate that the subscriber identification card has the target active command that needs to be sent to the terminal, and the acquisition instruction is used to acquire the target active command of the subscriber identification card; The terminal receives the target active command from the subscriber identification card to determine that the subscriber identification card currently does not have the STK application triggered based on the polling instruction.

6. The method according to claim 5, characterized in that The terminal disabling the polling instruction includes: The terminal disables the polling instruction based on the target proactive command.

7. The method according to claim 6, characterized in that The method further comprises: The terminal sends a feedback instruction for the target active command to the subscriber identity card, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

8. A detection method, characterized in that: Applied to a user identification card, the user identification card is installed in a terminal, the terminal supports a hot-swap in-place detection function for the user identification card, when the terminal determines that the user identification card is in-place based on a detection result of the hot-swap in-place detection function, the method comprises: The user identification card receives the polling instruction from the terminal, and sends a first response message to the terminal, so that the terminal determines that the user identification card is in the in-place state based on the first response message; When the subscriber identification card determines that there is no subscriber identification card application toolbox STK application currently triggered by the polling instruction, a target active command is sent to the terminal to make the terminal disable the polling instruction.

9. The method according to claim 8, characterized in that Before sending the target active command to the terminal, the method further includes: The user identification card receives a configuration instruction sent from the terminal based on a preset communication protocol, where the configuration instruction is used to indicate that the terminal supports disabling the polling instruction.

10. The method according to claim 9, characterized in that The preset communication protocol includes at least a preset field, and the preset field is used to indicate that the terminal supports disabling the polling instruction.

11. The method according to any one of claims 9 or 10, characterized in that: The method further comprises: The subscriber identification card sends second response information to the terminal for the configuration instruction, where the second response information indicates that the subscriber identification card has received the configuration instruction.

12. The method according to claim 8, characterized in that If the first response information includes a preset status word, the preset status word is used to indicate that the user identification card has a target active command that needs to be sent to the terminal, and the target active command is used to instruct the terminal to disable the polling instruction, sending the target active command to the terminal includes: The user identification card receives an acquisition instruction from the terminal, where the acquisition instruction is used to acquire the target active command; The subscriber identification card responds to the acquisition instruction and sends the target active command to the terminal.

13. The method according to claim 12, characterized in that After sending the target active command to the terminal, the method further includes: The subscriber identification card receives a feedback instruction from the terminal for the target active command, where the feedback instruction is used to indicate that the polling instruction has been disabled successfully.

14. A terminal, characterized in that: The terminal is installed with a user identification card, and the terminal supports a hot-swap in-place detection function for the user identification card. The terminal includes: a first detection unit, configured to send a polling instruction to the subscriber identification card, and determine that the subscriber identification card is in a present state based on first response information of the subscriber identification card to the polling instruction; A second detection unit, used for executing the hot-swap in-place detection function, and determining that the subscriber identification card is in-place based on the detection result of the hot-swap in-place detection function; A disabling unit is used to disable the polling instruction when it is determined based on a target active command that the user identification card currently does not have a user identification card application toolbox STK application triggered by the polling instruction, wherein the target active command is obtained by the terminal from the user identification card according to a preset status word included in the first response information, and the target active command is used to indicate that the terminal is allowed to disable the polling instruction.

15. A user identification card, characterized in that: The user identification card is installed in a terminal, and the terminal supports a hot-swap in-place detection function for the user identification card. When the terminal determines that the user identification card is in-place based on a detection result of the hot-swap in-place detection function, the user identification card includes: a processing unit, configured to receive a polling instruction from the terminal, and send a first response message to the terminal, so that the terminal determines that the subscriber identification card is in a present state based on the first response message; The sending unit is used to send a target active command to the terminal when it determines that there is no subscriber identity card application toolbox STK application triggered by the polling instruction, so that the terminal disables the polling instruction.

16. An electronic device, characterized in that: The electronic device comprises at least one processor and a memory connected to the at least one processor, and the at least one processor is configured to implement the steps of the method as claimed in any one of claims 1-7 or 8-13 when executing a computer program stored in the memory.

17. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 or 8 to 13 are implemented.