CN109495875B - SIM card selection method and device, electronic equipment and storage medium - Google Patents

SIM card selection method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN109495875B
CN109495875B CN201910028190.0A CN201910028190A CN109495875B CN 109495875 B CN109495875 B CN 109495875B CN 201910028190 A CN201910028190 A CN 201910028190A CN 109495875 B CN109495875 B CN 109495875B
Authority
CN
China
Prior art keywords
card
sim
sim card
sim cards
response
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.)
Active
Application number
CN201910028190.0A
Other languages
Chinese (zh)
Other versions
CN109495875A (en
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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201910028190.0A priority Critical patent/CN109495875B/en
Publication of CN109495875A publication Critical patent/CN109495875A/en
Application granted granted Critical
Publication of CN109495875B publication Critical patent/CN109495875B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/18Processing of user or subscriber data, e.g. subscribed services, user preferences or user profiles; Transfer of user or subscriber data
    • H04W8/183Processing at user equipment or user record carrier

Abstract

The application discloses a method and a device for selecting an SIM card, electronic equipment and a storage medium, and relates to the technical field of electronic equipment. Wherein, the method comprises the following steps: receiving a data connection request, wherein the data connection request corresponds to a corresponding data service; selecting one SIM card from the SIM cards of which the available service volume corresponding to the data service is greater than the corresponding preset threshold value as a response card; and taking the response card as the SIM card responding to the data connection request.

Description

SIM card selection method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of electronic device technologies, and in particular, to a method and an apparatus for selecting a SIM card, an electronic device, and a storage medium.
Background
With the change of the use requirement and the use environment of the SIM card, more and more users use two or more SIM cards as the call number cards at the same time. Therefore, dual-card dual-standby or multi-card electronic devices are also available.
Generally, for a plurality of SIM cards existing in an electronic device, a user needs to set a master card for use in response to a relevant data request. However, in an actual usage environment, the SIM card that responds to the data request may not be the appropriate SIM card, as determined by the manner in which the user sets the main card.
Disclosure of Invention
In view of the above problems, the present application provides a method and an apparatus for selecting a SIM card, an electronic device, and a storage medium to solve the above problems.
In a first aspect, an embodiment of the present application provides a SIM card selection method, which is applied to an electronic device, where the electronic device is provided with multiple SIM cards, and the method includes: receiving a data connection request, wherein the data connection request corresponds to a corresponding data service; selecting one SIM card from the SIM cards of which the available service volume corresponding to the data service is greater than the corresponding preset threshold value as a response card; and taking the response card as the SIM card responding to the data connection request.
In a second aspect, an embodiment of the present application provides a SIM card selection apparatus, which is applied to an electronic device. The device comprises: a request receiving module, configured to receive a data connection request, where the data connection request corresponds to a corresponding data service; the selection module is used for selecting one SIM card from the SIM cards of which the available service volume corresponding to the data service is greater than the corresponding preset threshold value as a response card; and the response module is used for taking the response card as the SIM card responding to the data connection request.
In a third aspect, an embodiment of the present application provides an electronic device, including a memory, a processor, and a card slot for setting a plurality of SIM cards, where the memory and the card slot are coupled to the processor, and the memory stores instructions, and when the instructions are executed by the processor, the processor performs the above-mentioned method.
In a fourth aspect, the present application provides a computer-readable storage medium, in which a program code is stored, and the program code can be called by a processor to execute the above method.
According to the SIM card selection method, the SIM card selection device, the electronic equipment and the storage medium, under the condition that the data connection request is received, the SIM cards are selected according to the available service volume of each SIM card. And selecting one SIM card from the SIM cards with the available service volume larger than the corresponding preset threshold value as the SIM card responding to the data connection request, thereby selecting the SIM card more suitable for the actual use condition.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 shows a flowchart of a SIM card selection method according to an embodiment of the present application.
Fig. 2 shows a flowchart of a SIM card selection method according to another embodiment of the present application.
Fig. 3 shows a flowchart of a SIM card selection method according to another embodiment of the present application.
Fig. 4 is a functional block diagram of a SIM card selection apparatus according to an embodiment of the present application.
Fig. 5 shows a block diagram of an electronic device according to an embodiment of the present application.
Fig. 6 is a storage unit for storing or carrying program codes for implementing a SIM card selection method according to an embodiment of the present application.
Detailed Description
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application.
SIM (subscriber identity module) cards, also called subscriber identity cards, smart cards, etc., each SIM card corresponds to a telephone number for uniquely identifying a subscriber identity. A SIM card may be inserted into an electronic device for use and the communication charges incurred by the electronic device through the SIM card are recorded on an account of the subscriber identity uniquely identified by the SIM card.
With the development of electronic devices, more and more electronic devices can be provided with multiple SIM cards, which may be two or more than two. The SIM card set in the electronic device may be an entity SIM card or a virtual SIM card.
Each SIM card installed in the electronic device may be used as a call number card for voice call, or each SIM card may be used as a data card for connecting to a mobile data network. In actual use, a SIM card is determined for responding to relevant data services, such as determining a SIM card for making a call in response to a dialing request, and determining a SIM card for making a mobile data network connection in response to a network connection request. The mobile data network includes a 2G network, a 3G network, a 4G network, a 5G network, and the like, which is not limited in the embodiment of the present application.
The method for determining that one SIM card is used for responding to the related data service may be that a user sets a default SIM card as a main card in advance, and uses the main card to respond when receiving a request related to the data service. That is, if a dialing request for dialing a call is received, the main card is used for dialing; when a network connection request is received, the mobile data network is connected through the main card, and all Internet data services of the terminal can only use a default SIM card set by a user by default. The main cards corresponding to different data services may be set separately, for example, one SIM card is set as the main card for making a call, and the other SIM card is set as the main card for connecting to the mobile data network.
However, in this method, the SIM card responding to the request cannot be flexibly adjusted according to the actual situation of the SIM card, and the resources of all SIM cards are not fully utilized. For example, the electronic device is provided with two SIM cards, one of which has a large number of free minutes to talk, and the other of which has no number of free minutes to talk. At this time, if the SIM card with no free minutes is set as the master card, the master card dials a number when a dialing response is performed, which brings extra consumption to the user. For another example, the electronic device is provided with two SIM cards, wherein one SIM card has much remaining data traffic, and the other SIM card has no remaining data traffic. At this time, if the SIM card without the remaining data traffic is set as the master card responding to the data connection request, additional consumption is brought to the user while the mobile network connection is performed, and the data traffic of the SIM card with the remaining data traffic is not used.
In addition, the SIM card used for making a call in response to a dialing request may be determined by popping up a SIM card selection box when the dialing request is received, and selecting the SIM card used for the current dialing by the user. However, in this method, the interactive flow is added, and the user is required to manually select each time, which is cumbersome. Moreover, the user may not be able to correctly select the appropriate SIM card to make the outgoing call, for example, the user may not know the actual remaining amount of the call minutes of each SIM card, which may cause difficulty in user selection and may cause user selection errors.
Therefore, the inventor proposes a method, an apparatus, an electronic device, and a storage medium for selecting a SIM card according to the practical situation of the available traffic of each SIM card when receiving a data connection request, so that the selected SIM card for responding to the data connection request is more suitable for the practical situation.
The method, the apparatus, the electronic device, and the storage medium for selecting the SIM card provided in the embodiments of the present application are described in detail below with reference to specific embodiments.
Referring to fig. 1, a method for selecting a SIM card provided in the embodiment of the present application is applied to an electronic device. The electronic device is provided with a plurality of SIM cards, which may be physical SIM cards installed therein or virtual SIM cards, and the embodiment of the present application is not limited. Specifically, the method may include:
step S110: and receiving a data connection request, wherein the data connection request corresponds to a corresponding data service.
The electronic device may receive data connection requests, each data request corresponding to a respective data service.
The data connection request may be a dialing request, for example, a user initiates a dialing request through a dialing keypad, initiates a dialing request through a dialing key in a web page, and the like. And the data service corresponding to the dialing request is a dialing call service for carrying out dialing call. The electronic device may monitor the data connection request in real time, and when the dialing request is monitored, may determine that the data connection request corresponding to the dial-up call service is received.
In addition, the data connection request may also be a mobile network connection request, and the corresponding data service is a mobile network connection service, that is, a request for acquiring data through a mobile network such as 2G, 3G, 4G, or 5G. When an online video playing request is received, requesting to download video data through a mobile network; when a web page opening request is received, web page data and the like are requested to be acquired through a mobile network. Optionally, the mobile network connection request may also be a request for turning on a mobile network connection switch, such as receiving a touch to a mobile network turn-on button.
The electronic equipment can monitor the mobile network connection request in real time, and can judge that a data connection request corresponding to the mobile network connection service is received each time the mobile network connection request is monitored; in addition, in order to reduce the energy consumption of the electronic device, the mobile network connection request may be monitored every time longer than the preset time, and it may be determined that the data connection request corresponding to the mobile network connection service is received. In order to reduce the energy consumption of the electronic equipment, the electronic equipment may also perform monitoring of the mobile data connection request every other preset time, and if the mobile network connection request is monitored, it is determined that the data connection request corresponding to the mobile network connection service is received, the monitoring is stopped, and the monitoring is performed again after the interval of the preset time; and if the mobile network connection request is not monitored, continuing monitoring until the mobile network connection request is monitored, judging that the data connection request corresponding to the mobile network connection service is received, stopping monitoring, and monitoring again after a preset time interval.
Step S120: and selecting one SIM card from the SIM cards of which the available service volume corresponding to the data service is greater than the corresponding preset threshold value as a response card.
Step S130: and taking the response card as the SIM card responding to the data connection request.
Upon receiving the data connection request, the electronic device selects a SIM card for use in responding to the data connection request. Specifically, the selection may be performed according to the available traffic of the corresponding data service corresponding to each SIM card. The available traffic is the traffic of the corresponding data service that the SIM card can use for free, or the traffic in the service of the SIM card. If the available service volume corresponding to the dial-up call service is the number of free call minutes left by the SIM card, or the remaining amount of the voice package in the SIM card; for another example, the available service volume corresponding to the mobile network connection service is the remaining free traffic of the SIM, or the remaining amount of the data package in the SIM card.
Specifically, a preset threshold value for comparing with the available traffic volume is set corresponding to the corresponding data traffic. Wherein, different data services can be respectively set with preset threshold values. For example, a preset threshold is set as a first threshold corresponding to the dial-up call service, and a second threshold is set corresponding to the mobile network connection service. Specific values of the first threshold and the second threshold are not limited in the embodiment of the present application, for example, the first threshold may be 5 minutes, 10 minutes, or the like; the second threshold may be 50M, 100M, etc.
In addition, different SIM cards can also be set for the same data service. For example, the electronic device is provided with two SIM cards, which are a first SIM card and a second SIM card, respectively, and then the preset threshold corresponding to the dial-up call service of the first SIM card may be set as a third threshold corresponding to the first SIM card, and the preset threshold corresponding to the mobile network connection service of the first SIM card is set as a fourth threshold; the preset threshold corresponding to the second SIM card for the dial-up call service may be set as a fifth threshold corresponding to the second SIM card, and the preset threshold corresponding to the mobile network connection service for the second SIM card may be set as a sixth threshold.
In the embodiment of the present application, the preset threshold may be set by a user. That is, a setting interface of the preset threshold may be provided, and the user may set the preset threshold of each data service on the setting interface. And after receiving the setting of the user, the electronic equipment takes the value set by the user as a preset threshold value of the corresponding data service.
And comparing the available service volume of the data service corresponding to each SIM card with a corresponding preset threshold value. If two SIM cards are set in the electronic equipment, the two SIM cards are respectively a first SIM card and a second SIM card, and the data service corresponding to the data connection request is a dialing call service, comparing the available service volume of the dialing call service of the first SIM card with a third threshold value of the first SIM card, and determining whether the available service volume of the dialing call service of the first SIM card is greater than the third threshold value of the first SIM card; and comparing the available traffic of the dial-up call service of the second SIM card with a fifth threshold value of the second SIM card, and determining whether the available traffic of the dial-up call service of the second SIM card is greater than the fifth threshold value of the second SIM card. And selecting the SIM card as a response card from the SIM cards of which the available service volume corresponding to the data service is greater than a preset threshold value, namely the SIM card responding to the data connection request.
The electronic equipment can respond to the data connection request through the selected response card to perform corresponding data connection. For example, if the data connection request is a dial-up call request, dialing is performed through the telephone number of the response card, and the available traffic of the response card is consumed; if the data connection request is a mobile network connection request, the mobile network connection is carried out by consuming the traffic of the telephone number of the response card, and the consumed traffic is reduced from the available traffic of the telephone number of the response card.
Optionally, in this embodiment of the application, if the data service includes a mobile network connection service, since the mobile network connection is usually frequent, if the SIM card selection is performed every time the mobile network is connected, power consumption of the electronic device may be increased. Therefore, in the embodiment of the present application, after the SIM card is selected as the response card, the response card may be selected by responding to the data connection request again when the waiting time is greater than the preset time threshold. Before selecting the SIM card as the response card again, the data service may be processed in response to the data connection request by the response card selected previously. Specifically, before step S120, it may be determined whether a difference between a time when the SIM card is selected as the response card last time and a time when the SIM card is selected as the response card reaches a preset time threshold. If the preset time threshold is reached, step S120 may be executed. If the preset time threshold is not reached, the response card selected at the previous time can respond to the SIM card of the data connection request at the current time.
In the embodiment of the application, under the condition that a data connection request is received, a response card is selected from the SIM cards with the available traffic volume larger than a preset threshold value, so that a proper SIM card is selected for responding the data connection request.
According to the SIM card selection method provided by the embodiment of the application, when the number of the SIM cards with the available service volume larger than the corresponding preset threshold value is different, the SIM cards can be selected by different selection strategies. Specifically, referring to fig. 2, another embodiment of the present application provides a SIM selection method, including:
step S210: and receiving a data connection request, wherein the data connection request corresponds to a corresponding data service.
For the detailed description of this step, reference may be made to the foregoing step S110, which is not described herein again.
Step S220: and determining the number of the SIM cards of which the available service volume corresponding to the data service is greater than a corresponding preset threshold value. If the available service volume of the data service corresponding to at least two SIM cards in the plurality of SIM cards is greater than the corresponding preset threshold, executing step S230; if the available traffic of only one SIM card corresponding to the data service is greater than the corresponding preset threshold, the SIM card is used as the response card, and step S250 is executed.
In the embodiment of the application, if the electronic device is provided with only one SIM card, the SIM card is used as the SIM card for responding to the data connection request. If the electronic device is provided with a plurality of SIM cards, such as two or three, one SIM card is selected from the plurality of SIM cards as a response card.
When the electronic device is provided with a plurality of SIM cards, the number of SIM cards in which the available traffic of the corresponding data service is greater than the corresponding preset threshold may be determined. For example, if the data connection request is a dial-up call request, the number of SIM cards of which the available traffic of the dial-up call service is greater than the corresponding preset threshold is determined among the plurality of SIM cards. If the electronic device is provided with two SIM cards, and the available traffic of the dial-up call services of the two SIM cards is greater than the corresponding preset threshold, that is, the available traffic of the dial-up call service of the first SIM card is greater than the third threshold, and the available traffic of the dial-up call service of the second SIM card is greater than the fifth threshold, it may be determined that the number of the SIM cards whose available traffic is greater than the corresponding preset threshold in the electronic device is two. If the electronic equipment is provided with two SIM cards, the available traffic of the dial-up call service of the first SIM card in the two SIM cards is larger than a third threshold value, and the available traffic of the dial-up call service of the second SIM card is smaller than a fifth threshold value, the number of the SIM cards with the available traffic larger than the corresponding preset threshold value in the electronic equipment can be determined to be one. Of course, there may not be a SIM card with an available traffic volume greater than the corresponding preset threshold value among the multiple SIM cards, that is, the available traffic volumes of all the SIM cards are consumed to be less than or equal to the corresponding preset threshold value.
The available traffic of each SIM card in the electronic device can be obtained by inquiry from the operator or determined by manual input from the user. And, under the condition of obtaining the available service volume once from the outside, the consumption of the available service volume can be deducted according to the SIM card, and the change condition of the available service volume of the SIM card can be tracked. For example, the electronic device stores the available traffic of the dial-up call service of the SIM card in the local database, and after each dial-up call, deducts the call duration from the available traffic. In another example, the electronic device stores available traffic of the mobile network connection service of the SIM card in a local database, and after a period of time, deducts traffic consumption during the period of time from the available traffic.
If there is no SIM card with an available traffic volume greater than the corresponding preset threshold value among the plurality of SIM cards, the selection may be performed according to a preset selection policy.
As an implementation manner, if there is no SIM card with an available traffic volume greater than a corresponding preset threshold in the multiple SIM cards, a SIM card selection window may be popped up, the user is prompted to select a SIM card for responding to the data connection request, and the SIM card finally selected by the user is used as a response card.
As an implementation manner, the charge condition of each data service of each SIM card, such as the charge condition of dial-up call per minute after the available service volume of the dial-up call service is consumed, may be obtained and stored; and charging for each M flow after the mobile data flow is consumed. According to the charge condition of each SIM card, the SIM card with lower data service charge corresponding to the data connection request is selected as a response card, so that less consumption is generated when the data service of the response is executed. If the available service volume of the two SIM cards set by the electronic equipment is consumed, the first SIM card charges 0.25 yuan per minute for a call, and the second SIM card charges 0.1 yuan per minute, the second SIM card is selected as a response card when the available service volume of the plurality of SIM cards is not larger than the corresponding SIM card with the preset threshold value. The charging condition of each SIM card may be manually input by the user, or may be obtained by querying from a responding operator, and the specific obtaining manner is not limited in the embodiment of the present application.
As an implementation manner, a default SIM card pre-specified by the user may also be received, and when the available traffic of the data service of all the SIM cards is less than or equal to the corresponding preset threshold, the default SIM card is used as a response card, and the data connection request is responded through the default SIM card. Wherein, corresponding to different data services, different default SIM card settings can be performed. Of course, the SIM card may also be uniformly configured for all data services, which is not limited in the embodiment of the present application.
In this embodiment of the present application, if the available traffic of only one SIM card corresponding to the data service in the multiple SIM cards is greater than the corresponding preset threshold, the SIM card may be directly used as the response card for responding to the data connection request, so as to avoid additional consumption caused by the exhaustion of the available traffic when using other SIM cards.
In this embodiment of the application, if the available traffic of the data service corresponding to at least two SIM cards in the plurality of SIM cards is greater than the corresponding preset threshold, as an implementation manner, one SIM card may be randomly selected as a response card.
As another embodiment, if the available traffic of the data service corresponding to at least two SIM cards in the plurality of SIM cards is greater than the corresponding preset threshold, an SIM card with better signal quality may be selected from the at least two SIM cards as a response card, that is, an SIM card with better signal quality may be selected from the SIM cards with the available traffic of the data service greater than the corresponding preset threshold as a response card, so that when processing the data service corresponding to the data connection request, the effect is better, for example, the call tone quality is higher and smoother, the call completing rate is higher, and the internet surfing speed is faster and not stuck. The at least two SIM cards may be all SIM cards in the electronic device, or may be some SIM cards in the electronic device.
Step S230: and determining the mobile communication network where each SIM card of the at least two SIM cards resides.
Specifically, when the available traffic of the data service corresponding to at least two SIM cards is greater than the corresponding preset threshold, the mobile communication network where each SIM card with the available traffic greater than the corresponding preset threshold resides may be determined. That is, it may be determined whether a base station accessed by each of the at least two SIM cards is a 5G base station, a 4G base station, a 3G base station, or a 2G base station, and whether a 5G network, a 4G network, a 3G network, or a 2G network is connected.
Step S240: and selecting one SIM card with the highest network type of the resident mobile communication network from the at least two SIM cards as the response card.
As the higher the network system of the mobile communication network where the SIM card resides, the better the signal quality, for example, the call quality of volte (voice over lte) in 4G network is better than that in 3G and 2G networks. Therefore, the SIM card with the highest network type can be selected from the SIM cards with the available traffic volume corresponding to the data service larger than the corresponding preset threshold. The network type is the type of the network, for example, the network type of 5G is higher than 4G, the network type of 4G is higher than 3G, and the network type of 3G is higher than 2G. Also as LTE > WCDMA > GSM.
Specifically, if the network type of the mobile communication network in which only one SIM card resides is the highest among the at least two SIM cards, the SIM card is used as the response card. That is, in at least two SIMs whose available traffic corresponding to the data service is greater than the corresponding preset threshold, the network system of one SIM card is higher than that of all other SIM cards, which indicates that the signal quality of the SIM card is the best, and the SIM card is used as the SIM card for responding to the data connection request. For example, if the available traffic of two SIM cards in the electronic device is greater than the corresponding preset threshold, and the network connected with one of the two SIM cards is a 4G network, and the network connected with the other SIM card is a 3G network, the SIM card connected with the 4G network is used as the response card.
In addition, if the network formats of the mobile communication networks where the at least two SIM cards reside are the highest and the same, one SIM card is selected from the two or more SIM cards as a response card. That is, in the SIM cards whose available traffic corresponding to the data service is greater than the corresponding preset threshold, if two or more SIM cards are accessed to the mobile communication network of the same standard and the standard of the accessed mobile communication network is higher than that of other SIM cards, the SIM card is selected from the two or more SIM cards as the response card. It can be understood that the two or more SIM cards may also be all SIM cards in the electronic device, or all SIM cards in the electronic device whose available traffic of all data services is greater than a corresponding preset threshold, or some SIM cards in the electronic device, where the specific use cases and signal cases of the SIM cards are different, and the number of the SIM cards is different. For example, if the available traffic of two SIM cards in the electronic device is greater than the corresponding preset threshold, and the two SIM cards are connected to the network 4G network, one of the two SIM cards connected to the network 4G network is selected as the response card. For another example, if the available traffic of three SIM cards in the electronic device is greater than the corresponding preset threshold, and the network connected with two SIM cards is a 4G network, and the network connected with one SIM card is a 3G network, then one of the two SIM cards connected with the 4G network is selected as the response card.
Optionally, in this embodiment of the application, one SIM card may be randomly selected as a response card from two or more SIM cards with the highest and the same network standard of the resident mobile communication network.
Optionally, in this embodiment of the present application, one SIM card with the strongest signal strength may also be selected from the two or more SIM cards as the response card. Specifically, the electronic device may detect the signal strength of each of the two or more SIM cards, and use one of the two or more SIM cards with the strongest signal strength as the response card. For example, two SIM cards in the electronic device are connected with a 4G network, and the 4G network is the highest network system connected among all the SIM cards, then it is determined which SIM card has stronger signal strength, and the stronger SIM card is selected as the response card, so that the network effect is better when processing data services.
Optionally, if the network systems of the mobile communication networks where the two or more SIM cards reside are the highest and the same, and if the signal intensity of only one SIM card among the two or more SIM cards is stronger than that of the other SIM cards, the SIM card is used as the response card.
And if the signal intensity of more than one SIM card is the same and stronger than that of other SIM cards in the two or more SIM cards, or the difference between the signal intensities of more than one SIM card is smaller than a preset difference value and stronger than that of other SIM cards, selecting a preset default SIM card from the more than one SIM card as the response card. That is, if there is more than one SIM card among the two or more SIM cards having the same signal strength, or if there is more than one SIM card having a signal strength close to that of the other SIM cards and stronger than that of the other SIM cards, the default SIM card is selected from the more than one SIM cards. The default SIM card may be a SIM card set by the user for handling data traffic if the signal strength is the same or close. It can be understood that, it is also possible that the signal strength of all the SIM cards with the highest network standard of the mobile communication network where the SIM card resides is the same or the difference between the signal strengths is smaller than a preset difference value, and then a default SIM card is selected as the response card from all the SIM cards with the highest network standard of the mobile communication network where the SIM card resides and the same. For example, two SIM cards in the electronic device are connected with a 4G network, and the 4G network is the highest network standard connected among all the SIM cards, and the SIM card with stronger signal strength is selected from the two SIM cards as the response card. If the signal intensities of the two SIM cards are the same or smaller than a preset difference value, selecting a default card as a response card; and if one of the two SIM cards is stronger than the other SIM card, or the signal intensity of one SIM card is stronger than that of the other SIM card, and the difference is greater than a preset difference, selecting the SIM card with stronger signal intensity as a response card.
Optionally, in this embodiment of the application, if there is an unlimited amount of available traffic SIM cards in the SIM cards whose available traffic corresponding to the data service is greater than the corresponding preset threshold, one SIM card may be selected from the unlimited amount of available traffic as the response card. The specific selection mode may also be that, if only one SIM card in the multiple SIM cards corresponds to the unlimited amount of available service volume of the data service, the SIM card is used as the response card; and if the available service volume of the data service corresponding to at least two SIM cards in the plurality of SIM cards is not limited, selecting one SIM card with the highest network type of the resident mobile communication network from the at least two SIM cards as the response card. If the network type of the mobile communication network where only one SIM card resides is the highest in the at least two SIM cards, taking the SIM card as the response card; and if the network systems of the mobile communication networks where the at least two SIM cards reside are the highest and the same, selecting one SIM card with the strongest signal intensity from the two or more SIM cards as a response card. If the signal intensity of only one SIM card in the two or more SIM cards is stronger than that of other SIM cards, taking the SIM card as the response card; and if the signal intensity of more than one SIM card in the two or more SIM cards is the same and stronger than that of other SIM cards, selecting a preset default SIM card from the more than one SIM card as the response card. The specific selection manner may refer to the above SIM card whose available traffic is greater than the corresponding preset threshold according to the network type and the signal strength, and is not described herein again.
Step S250: and taking the response card as the SIM card responding to the data connection request.
In the embodiment of the application, the available service volume, the network type and the signal strength of the SIM card are combined for comprehensive selection, and the SIM card with better signal quality can be preferentially selected for corresponding data service without increasing the user charge.
The SIM card selection method in the embodiment of the present application will be described below through a specific usage scenario. In this usage scenario, the electronic device is provided with two SIM cards, and it can be understood that the number of the SIM cards that can be set by the electronic device is not limited to two, and the SIM card selection method provided in this embodiment is not limited to selecting from the two SIM cards. As shown in fig. 3, the method for selecting the SIM card of the electronic device in the specific usage scenario may include:
step S310: and receiving a data connection request, wherein the data connection request corresponds to a corresponding data service.
Step S320: and judging whether the available traffic of the two SIM cards is larger than a corresponding preset threshold value. If yes, go to step S330; if not, and the available service volume of one of the SIM cards is greater than the corresponding preset threshold, taking the SIM card as a response card, and executing step S360; if not, and the available traffic of the two SIM cards is not greater than the corresponding preset threshold, the default card is selected as the response card, and step S360 is executed.
Step S330: and judging whether the network system of the mobile network connected with one SIM card in the two SIM cards is higher than that of the other SIM card. If not, go to step S340; if yes, the SIM card with the higher network type of the connected mobile network is used as the response card, and step S360 is executed.
If the network system of the mobile network connected with none of the two SIM cards is higher than that of the other SIM card, the network systems of the mobile networks connected with the two SIM cards are the same, such as a 4G network, a 3G network, a 2G network and the like.
Step S340: and judging whether the signal intensity of one SIM card is stronger than that of the other SIM card in the two SIM cards. If not, executing step S350; if yes, the SIM card with stronger signal strength is used as the response card, and step S360 is executed.
And if the signal intensity of one SIM card in the two SIM cards is stronger than that of the other SIM card, the signal intensities of the two SIM cards are the same. Optionally, in this embodiment of the application, the signal strengths of the SIM cards are the same, and may not necessarily be the same, and two signal strengths having a preset difference may also be determined as the same signal strength.
Step S350: and taking the default card of the two SIM cards as a response card.
Step S360: and taking the response card as the SIM card responding to the data connection request.
When receiving the data connection request, the available traffic of the data service corresponding to the data connection request of the two SIM cards is larger than the corresponding preset threshold,
specific contents of each step in this embodiment may refer to the same or corresponding parts in the foregoing embodiments, and are not described in detail in this embodiment.
In the embodiment of the application, the data connection request can be a dial-up call request corresponding to a dial-up call service; or the mobile network connection request corresponds to the mobile network connection service.
If the data connection request is a dial-up call request, when the voice package margins of the two SIM cards are not exhausted, a card selection strategy based on signal quality is preferentially used, namely, the SIM card with higher network system is used as the SIM card with better signal quality, and the SIM card with stronger signal strength is used as the SIM card with better signal quality when the network systems are the same. Judge which card signal quality is better during the dialing, the better draw-in groove outgoing call of preferred selection signal quality can promote the user outgoing call's when two cards success rate, also can effectively promote the pronunciation quality experience after the conversation is established simultaneously, because the sound that weak signal leads to is fuzzy, the card is pause during the reduction conversation, the probability of noiseless scheduling problem. If the voice package allowance of one card is exhausted, the other card with the unspent voice package allowance is preferentially selected as the card preferentially selected when the call is made, so that the package allowance is prevented from being exceeded, and extra telephone charge expense is brought to a user. If the voice package allowance of the two cards is exhausted, the user can be prompted to select a default SIM card, or dialing is carried out by using the preset default SIM card, so that the situation that the two cards exceed the charge standard of the package part and are inconsistent, and extra telephone charge expense is brought to the user is prevented.
In the case where the data connection request is a dial-up call request, the difference of the network environments where the SIM cards are located when the dial-up request is received may be considered, for example, if one SIM card is a mobile card and one SIM card is a telecommunication card, where the mobile card signal is strong and the telecommunication card signal is strong, a suitable SIM card may be selected according to the signal strength of the actual location when the dial-up call request is received. Moreover, if a default SIM card set by the user is used to make a call, a card with poor signal is used to make a call under certain conditions, which may result in a call failure, and even if the call is successfully established, the call quality is not good due to poor signal. The method provided by the embodiment of the application ensures that the user can preferentially select the calling card with strong signals to call the telephone on the basis of the intelligent card selection strategy combining the signal intensity and the voice package allowance under the condition of not increasing the user fee, and reduces the problems of call calling failure and poor call voice quality caused by poor signal coverage.
And if the network connection request is moved during the data connection request, an automatic card selection strategy based on the combination of the signal quality and the data traffic package allowance is adopted. When the data package allowance of the two SIM cards is not exhausted, a card selection strategy based on signal quality is preferentially used, namely, the network type of a network connected with which the card is connected is judged to be higher when the network is accessed, if the resident network types are the same, the card with better signal strength is preferentially selected as the network access card, if the resident network types are different, the card with high type is preferentially selected as the network access card according to the priority from high to low of the network types, and the network access experience of a user in the double-card process can be improved.
If the data package allowance of the two cards is exhausted, the user can be prompted to select a default internet access card or perform network connection by using a preset default SIM card, so that the situation that the charging standard of the two cards exceeding the package part is inconsistent and extra expense is brought to the user is prevented. The method provided by the embodiment can prevent the use of the mobile data network from exceeding the package allowance, and bring extra expense for the user. Under the condition of not increasing user charge, the user can be ensured to preferentially select the telephone card with strong signal to carry out Internet access service, and the problems of slow Internet access and incapability of Internet access of the user caused by poor signal coverage of the default Internet access card are reduced.
The embodiment of the present application further provides a SIM card selecting apparatus 400, which is applied to an electronic device. Specifically, as shown in fig. 4, the apparatus 400 includes: a request receiving module 410, configured to receive a data connection request, where the data connection request corresponds to a corresponding data service; a selecting module 420, configured to select one SIM card from SIM cards whose available traffic corresponding to the data service is greater than a corresponding preset threshold as a response card; a response module 430, configured to use the response card as a SIM card for responding to the data connection request.
Optionally, the selecting module 420 may include: and the first selecting unit is used for taking only one SIM card as the response card if the available service volume of the data service corresponding to the SIM card is larger than a corresponding preset threshold value. A second selecting unit, configured to determine, if available traffic of the data service corresponding to at least two SIM cards in the multiple SIM cards is greater than a corresponding preset threshold, a mobile communication network in which each SIM card of the at least two SIM cards resides; and selecting one SIM card with the highest network type of the resident mobile communication network from the at least two SIM cards as the response card.
Optionally, the second selecting unit may include a first selecting subunit, configured to, if a network type of the mobile communication network where only one SIM card resides is the highest among the at least two SIM cards, use the SIM card as the response card; and the second selection subunit is used for selecting one SIM card with the strongest signal intensity from the two or more SIM cards as a response card if the network formats of the mobile communication networks where the two or more SIM cards reside are the highest and the same in the at least two SIM cards.
Optionally, the second selecting subunit may be specifically configured to, if the signal intensity of only one SIM card of the two or more SIM cards is stronger than that of the other SIM cards, use the SIM card as the response card; and if the signal intensity of more than one SIM card in the two or more SIM cards is the same and stronger than that of other SIM cards, selecting a preset default SIM card from the more than one SIM card as the response card.
Optionally, the apparatus provided in this embodiment of the present application may further include a determining module, configured to determine whether a difference between the time when the SIM card was selected as the response card last time and the time when the SIM card was selected as the response card reaches a preset time threshold. If the determination result is yes, the selecting module 420 is configured to select one SIM card from the SIM cards whose available traffic corresponding to the data service is greater than the corresponding preset threshold as a response card.
Optionally, the selecting module 420 may be further configured to select one SIM card from the SIM cards with unlimited available traffic volume as the response card if the available traffic volume corresponding to the data service is greater than the corresponding preset threshold.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described apparatuses and modules may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, the coupling between the modules may be electrical, mechanical or other type of coupling.
In addition, functional modules in the embodiments of the present application may be integrated into one processing module, or each of the modules may exist alone physically, or two or more modules are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode.
Referring to fig. 5, a block diagram of an electronic device 500 according to an embodiment of the present disclosure is shown. The electronic device 500 may be a mobile phone, a tablet computer, an electronic book, or other electronic devices capable of setting a SIM card and running an application program. The electronic device comprises a processor 510 and a memory 520 coupled to the processor, the memory storing instructions that, when executed by the processor, perform the method described in one or more of the embodiments above.
Processor 510 may include one or more processing cores. The processor 510 interfaces with various components throughout the electronic device 500 using various interfaces and circuitry to perform various functions of the electronic device 500 and process data by executing or executing instructions, programs, code sets, or instruction sets stored in the memory 520 and invoking data stored in the memory 520. Alternatively, the processor 510 may be implemented in hardware using at least one of Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), and Programmable Logic Array (PLA). The processor 510 may integrate one or more of a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), a modem, and the like. Wherein, the CPU mainly processes an operating system, a user interface, an application program and the like; the GPU is used for rendering and drawing display content; the modem is used to handle wireless communications. It is understood that the modem may not be integrated into the processor 510, but may be implemented by a communication chip.
The Memory 520 may include a Random Access Memory (RAM) or a Read-Only Memory (Read-Only Memory). The memory 520 may be used to store instructions, programs, code, sets of codes or sets of instructions, such as instructions or sets of codes for implementing the SIM card selection methods provided by embodiments of the present application. The memory 520 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function, instructions for implementing the various method embodiments described above, and the like. The data storage area can also store data (such as a phone book, audio and video data, chatting record data) and the like created by the electronic equipment in use.
Optionally, in this embodiment of the application, the electronic device may further include a card slot, where the card slot may be used to insert a plurality of SIM cards, specifically, may be used to insert two or more SIM cards.
Optionally, in this embodiment of the application, the electronic device may further include a SIM card.
Referring to fig. 6, a block diagram of a computer-readable storage medium according to an embodiment of the present application is shown. The computer-readable storage medium 600 has stored therein program code that can be called by a processor to execute the method described in the above-described method embodiments.
The computer-readable storage medium 600 may be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read only memory), an EPROM, a hard disk, or a ROM. Alternatively, the computer-readable storage medium 600 includes a non-volatile computer-readable storage medium. The computer readable storage medium 600 has storage space for program code 610 for performing any of the method steps of the method described above. The program code can be read from or written to one or more computer program products. The program code 610 may be compressed, for example, in a suitable form.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same; although the present application has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not necessarily depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

Claims (10)

1. A SIM card selection method is applied to electronic equipment, wherein the electronic equipment is provided with a plurality of SIM cards, and the method comprises the following steps:
receiving a data connection request, wherein the data connection request corresponds to a corresponding data service;
if the difference between the time of the SIM card and the time of the SIM card selected as the response card at the previous time reaches a preset time threshold, executing the following steps:
if the available service volume of the data service corresponding to at least two SIM cards in the plurality of SIM cards is larger than a corresponding preset threshold value, determining a mobile communication network where each SIM card resides in the at least two SIM cards;
if the signal intensity difference of two or more SIM cards with the highest network standard and the same network standard of the resident mobile communication network is smaller than a preset difference value, selecting a default SIM card from the two or more SIM cards as a response card;
and taking the response card as the SIM card responding to the data connection request.
2. The method of claim 1, further comprising:
and if the available service volume of only one SIM card corresponding to the data service is larger than the corresponding preset threshold value, taking the SIM card as the response card.
3. The method of claim 2, further comprising:
and if the network type of the mobile communication network in which only one SIM card resides is the highest in the at least two SIM cards, taking the SIM card as the response card.
4. The method of claim 3, further comprising:
and if the signal intensity of only one SIM card in the two or more SIM cards is stronger than that of other SIM cards, and the difference value between the signal intensity of the SIM card with the stronger signal and that of the other SIM cards is larger than a preset difference value, taking the SIM card with the stronger signal as the response card.
5. The method of claim 1, wherein the data service comprises a mobile network connection service, and before the step of determining if the difference between the time when the SIM card was previously selected as the response card reaches a preset time threshold, the method further comprises:
and judging whether the time difference with the time of selecting the SIM card as the response card at the previous time reaches a preset time threshold value.
6. The method of claim 1, further comprising:
and if the available service volume corresponding to the data service is larger than the corresponding SIM cards with the preset threshold value, selecting one SIM card from the SIM cards with the unlimited available service volume as the response card.
7. The method according to any of claims 1 to 6, wherein the data service is a dial-up call service or a mobile network connection service.
8. A SIM card selecting device, applied to an electronic device, the device comprising:
a request receiving module, configured to receive a data connection request, where the data connection request corresponds to a corresponding data service;
the judging module is used for executing the following steps if the difference between the time of selecting the SIM card as the response card at the previous time and the time of selecting the SIM card as the response card reaches a preset time threshold value:
the selection module is used for selecting one SIM card from the SIM cards of which the available service volume corresponding to the data service is greater than the corresponding preset threshold value as a response card;
the response module is used for taking the response card as the SIM card responding to the data connection request;
the selection module comprises:
the second selection unit is used for determining a mobile communication network where each SIM card resides in the at least two SIM cards if the available service volume of the data service corresponding to the at least two SIM cards in the plurality of SIM cards is greater than a corresponding preset threshold; and if the signal intensity difference of two or more SIM cards with the highest network type and the same network type of the resident mobile communication network is smaller than a preset difference value, selecting a default SIM card from the two or more SIM cards as a response card.
9. An electronic device comprising a memory, a processor, and a card slot for providing a plurality of SIM cards, the memory and the card slot coupled to the processor, the memory storing instructions that, when executed by the processor, the processor performs the method of any of claims 1-7.
10. A computer-readable storage medium, having stored thereon program code that can be invoked by a processor to perform the method according to any one of claims 1 to 7.
CN201910028190.0A 2019-01-11 2019-01-11 SIM card selection method and device, electronic equipment and storage medium Active CN109495875B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910028190.0A CN109495875B (en) 2019-01-11 2019-01-11 SIM card selection method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910028190.0A CN109495875B (en) 2019-01-11 2019-01-11 SIM card selection method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109495875A CN109495875A (en) 2019-03-19
CN109495875B true CN109495875B (en) 2021-03-12

Family

ID=65714480

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910028190.0A Active CN109495875B (en) 2019-01-11 2019-01-11 SIM card selection method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109495875B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110035385B (en) * 2019-05-16 2020-12-22 深圳市沃特沃德股份有限公司 SIM card selection method and device, storage medium and computer equipment
CN110392405B (en) * 2019-07-25 2022-01-11 Oppo广东移动通信有限公司 Method, device, terminal and storage medium for switching mobile data network
CN110475229B (en) * 2019-08-20 2022-12-02 深圳市沃特沃德股份有限公司 Method and device for accessing service data, computer equipment and storage medium
CN111356159B (en) * 2020-05-25 2020-09-29 北京小米移动软件有限公司 Network-resident mode adjusting method, device and storage medium
CN111770437A (en) * 2020-06-09 2020-10-13 Oppo广东移动通信有限公司 Method and device for determining data card, terminal and storage medium
CN113225726B (en) * 2021-03-22 2023-05-16 闻泰通讯股份有限公司 Terminal-based switching method and device, terminal and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102547624A (en) * 2010-12-07 2012-07-04 中国电信股份有限公司 Method, system and gateway for C2G international roaming user to switch international mobile subscriber identity (IMSI)
CN107529154A (en) * 2016-06-22 2017-12-29 中兴通讯股份有限公司 The communication means and device of multimode terminal

Family Cites Families (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101137142A (en) * 2006-08-30 2008-03-05 中兴通讯股份有限公司 Method for CDMA and GSM dual-mode mobile terminal to implement mode switch
KR20090032678A (en) * 2007-09-28 2009-04-01 삼성전자주식회사 Terminal having dual sim card and method for executing function thereof
US8108002B2 (en) * 2008-03-21 2012-01-31 Mediatek Inc. Communication apparatuses equipped with more than one subscriber identity card and capable of providing reliable communication quality
KR101053905B1 (en) * 2008-06-26 2011-08-04 삼성전자주식회사 Apparatus and method for providing network service in mobile communication system
CN101553055B (en) * 2009-02-27 2011-09-28 北京天碁科技有限公司 A mobile terminal communication method and the mobile terminal
CN101854709A (en) * 2010-06-08 2010-10-06 中兴通讯股份有限公司 Method and device for switching dual-card dual-standby terminal wireless communication module
CN102891918B (en) * 2011-07-19 2016-04-20 联发科技股份有限公司 In order to the method for the bluetooth users identity module access specification of configuration communication device
CN103249180B (en) * 2013-04-16 2016-05-04 广东欧珀移动通信有限公司 A kind of intelligent switch method of double-card mobile phone and system
WO2015058545A1 (en) * 2013-10-22 2015-04-30 中兴通讯股份有限公司 Method and device for executing data service
CN103747152B (en) * 2014-01-21 2015-09-02 宇龙计算机通信科技(深圳)有限公司 Process the reminding method of communication service, prompt system and terminal
US9648491B2 (en) * 2014-02-19 2017-05-09 Mediatek Inc. Method of selecting an active SIM from multiple SIMs and a wireless device utilizing the same
CN104581666B (en) * 2014-12-26 2019-10-08 努比亚技术有限公司 A kind of method and device of the standby switching of mobile terminal SIM card
CN104954564B (en) * 2015-06-12 2018-07-27 小米科技有限责任公司 SIM card switching method, device and terminal
CN107912083B (en) * 2015-06-25 2020-01-31 华为技术有限公司 Working mode switching method and device and mobile terminal
CN104994487A (en) * 2015-07-15 2015-10-21 上海与德通讯技术有限公司 Mobile terminal and call switching method for multi-card multi-standby mobile terminal
CN105101164A (en) * 2015-07-23 2015-11-25 努比亚技术有限公司 Dual-card dual-standby terminal and data communication method
CN105933944A (en) * 2016-05-20 2016-09-07 广东欧珀移动通信有限公司 4G network optimum usage method and device and mobile terminal
CN107708168B (en) * 2017-11-23 2020-04-21 Oppo广东移动通信有限公司 SIM card switching method, mobile terminal and computer readable storage medium

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102547624A (en) * 2010-12-07 2012-07-04 中国电信股份有限公司 Method, system and gateway for C2G international roaming user to switch international mobile subscriber identity (IMSI)
CN107529154A (en) * 2016-06-22 2017-12-29 中兴通讯股份有限公司 The communication means and device of multimode terminal

Also Published As

Publication number Publication date
CN109495875A (en) 2019-03-19

Similar Documents

Publication Publication Date Title
CN109495875B (en) SIM card selection method and device, electronic equipment and storage medium
US9918219B2 (en) Call management method and apparatus for multi-SIM multi-active terminal
CN110249661B (en) Network connection method and device
CN109089327B (en) Wireless network connection method, device, terminal and storage medium
WO2017156833A1 (en) Method and device for selecting esim card-based operator service, and terminal
CN111182602A (en) SIM card switching method of mobile terminal, mobile terminal and computer storage medium
CN110730445A (en) Paging processing method, device, electronic equipment and storage medium
CN107529154B (en) Communication method and device of multimode terminal
US20220322088A1 (en) Network roaming method, terminal device, and computer readable storage medium
CN112714482A (en) Network switching method, device, terminal and storage medium
CN111273769B (en) Equipment control method and device, electronic equipment and storage medium
CN107277871B (en) VoLTE network registration method, device and terminal thereof
CN113660653B (en) Transmission method and device and electronic equipment
CN113225726B (en) Terminal-based switching method and device, terminal and storage medium
US8855619B2 (en) Method for state transition and network device
CN107734496B (en) Network searching control method and device of mobile terminal and mobile terminal
CN107431524B (en) Antenna configuration method and terminal
CN112312565B (en) Communication processing method, device, apparatus and storage medium
CN111726849B (en) WiFi hotspot type identification method and device and storage medium
EP3846538B1 (en) Method for controlling display of service identifier, and related product
CN113038556B (en) Method for accessing dual-card dual-standby terminal to network, dual-card dual-standby terminal and storage medium
CN108616870B (en) Method and device for identifying terminal customized preferentially
CN113873608A (en) Voice communication method, device, storage medium and terminal
CN111586781A (en) Call method and device
CN107343300B (en) eSIM card network communication method and device

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
GR01 Patent grant
GR01 Patent grant