A public network private network number switching method, device and equipment
Patent Information
- Application Number
- CN202611111707.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-24
- Publication Date
- 2026-10-16
AI Technical Summary
[0003]本申请实施例提供了一种公网专网号码切换方法、装置及设备,用以解决现有技术中在进行公网专网号码切换时,需人工插拔更换专网SIM卡与个人公网SIM卡,存在操作复杂,便利性低的问题
[0008]在本申请实施例中,终端内插接有SIM卡,其中,SIM卡中写入有专网号码以及公网号码;终端获取当前终端预设属性的属性值;其中,终端当前基于第一网络对应的号码通信,预设属性包括:地理位置、接收到的小区广播的网络标识信息的至少一种;在基于属性值,确定终端满足从第一网络切换到第二网络的情况下,切换为基于第二网络对应的目标号码通信;其中,第二网络与第一网络不同。SIM卡中写入有专网和公网等多个网络号码,并通过获取当前终端预设属性的属性值;在基于属性值,确定终端满足从第一网络切换到第二网络的情况下,切换为基于第二网络对应的目标号码通信,实现了公网号码和专网号码的自动化切换,无需人工插拔更换专网SIM卡与个人公网SIM卡,降低操作复杂度,提高了便利性。
Smart Images

Figure CN122934394A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of mobile communication technology, and in particular to a method, apparatus and device for switching public network and private network numbers. Background Technology
[0002] Currently, most private network terminals are customized devices that integrate industrial production functions and support public network communication. To ensure production data security, private network production services need to be isolated from public network personal services. Existing private network terminals and private network user identity module (SIM) cards use independent numbers and network architectures, which cannot be integrated and reused with the public network. Workers entering and leaving the work area need to repeatedly insert and remove private network SIM cards and personal public network SIM cards, resulting in cumbersome procedures and insufficient ease of use. Summary of the Invention
[0003] This application provides a method, apparatus, and device for switching between public and private network numbers, which solves the problem in the prior art that when switching between public and private network numbers, it is necessary to manually insert and remove the private network SIM card and the personal public network SIM card, which is complicated and inconvenient.
[0004] In a first aspect, embodiments of this application provide a method for switching between public and private network numbers, applied to a terminal, wherein a SIM card is inserted into the terminal, and the SIM card contains both a private network number and a public network number; the method includes: Obtain the attribute values of the current terminal's preset attributes; wherein, the terminal is currently communicating based on the number corresponding to the first network, and the preset attributes include at least one of the following: geographical location and network identification information received from cell broadcasts; Based on attribute values, if it is determined that the terminal meets the requirements for switching from the first network to the second network, then the communication is switched to the target number corresponding to the second network; wherein the second network is different from the first network.
[0005] Secondly, embodiments of this application provide a public / private network number switching device, applied to a terminal, wherein a SIM card is inserted into the terminal, and the SIM card contains a private network number and a public network number; the device includes: The acquisition module is used to acquire the attribute values of the current terminal's preset attributes; wherein, the terminal is currently communicating based on the number corresponding to the first network, and the preset attributes include at least one of the following: geographical location and network identification information received from cell broadcasts; The processing module is used to switch to communication based on the target number corresponding to the second network when the terminal meets the requirement of switching from the first network to the second network based on the attribute value; wherein the second network is different from the first network.
[0006] Thirdly, embodiments of this application also provide an electronic device, which includes at least a processor and a memory. The processor is used to execute a computer program stored in the memory to implement the steps of any of the above-described public network / private network number switching methods.
[0007] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of any of the above-described public / private network number switching methods.
[0008] In this embodiment, a SIM card is inserted into the terminal, containing a private network number and a public network number. The terminal obtains attribute values of its current preset attributes. The terminal currently communicates based on a number corresponding to a first network, and the preset attributes include at least one of the following: geographical location and network identifier information received from a cell broadcast. If, based on the attribute values, it is determined that the terminal meets the requirements for switching from the first network to a second network, communication is switched to a target number corresponding to the second network. The second network is different from the first network. By having multiple network numbers, such as private and public network numbers, written into the SIM card, and by obtaining the attribute values of the current terminal's preset attributes, and by switching to a target number corresponding to the second network when the terminal meets the requirements for switching from the first network to the second network, automated switching between public and private network numbers is achieved. This eliminates the need for manual insertion and replacement of the private network SIM card and the personal public network SIM card, reducing operational complexity and improving convenience. Attached Figure Description
[0009] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0010] Figure 1 A schematic diagram illustrating a public / private network number switching process provided in this application embodiment; Figure 2 A schematic diagram of a public network / private network number switching device provided in this application embodiment; Figure 3 This is a schematic diagram of an electronic device structure provided in an embodiment of this application. Detailed Implementation
[0011] To make the objectives and implementation methods of this application clearer, the exemplary implementation methods of this application will be clearly and completely described below with reference to the accompanying drawings of the exemplary embodiments of this application. Obviously, the exemplary embodiments described are only some embodiments of this application, and not all embodiments.
[0012] It should be noted that the brief descriptions of terms in this application are only for the convenience of understanding the embodiments described below, and are not intended to limit the embodiments of this application. Unless otherwise stated, these terms should be understood in their ordinary and common meaning.
[0013] The terms "first," "second," "third," etc., used in the specification, claims, and accompanying drawings of this application are used to distinguish similar or related objects or entities, and do not necessarily imply a specific order or sequence, unless otherwise specified. It should be understood that such terms are interchangeable where appropriate.
[0014] The terms “comprising” and “having”, and any variations thereof, are intended to cover but not exclude inclusion, for example, a product or device that includes a range of components is not necessarily limited to all of the components that are clearly listed, but may include other components that are not clearly listed or that are inherent to such product or device.
[0015] The term "module" refers to any known or subsequently developed hardware, software, firmware, artificial intelligence, fuzzy logic, or combination of hardware and / or software code that is capable of performing the functions associated with that element.
[0016] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
[0017] For ease of explanation, the above description has been provided in conjunction with specific embodiments. However, the above exemplary discussion is not intended to be exhaustive or to limit the embodiments to the specific forms disclosed above. Various modifications and variations can be obtained based on the above teachings. The selection and description of the above embodiments are for the purpose of better explaining the principles and practical applications, thereby enabling those skilled in the art to better utilize the described embodiments and various different variations of embodiments suitable for specific use considerations.
[0018] This application provides a method, apparatus, and device for switching between public and private network numbers. The method is applied to a terminal with a SIM card inserted, wherein the SIM card contains both a private network number and a public network number. The method obtains the attribute values of preset attributes of the current terminal. The terminal is currently communicating based on a number corresponding to a first network, and the preset attributes include at least one of the following: geographical location and network identifier information received from a cell broadcast. If, based on the attribute values, it is determined that the terminal meets the requirements for switching from the first network to a second network, the method switches to communicating based on a target number corresponding to the second network. The second network is different from the first network. This method achieves automated switching between public and private network numbers, eliminating the need for manual insertion and replacement of private network SIM cards and personal public network SIM cards, reducing operational complexity, and improving convenience.
[0019] Example 1: Figure 1 This application provides a schematic diagram of a public / private network number switching process, which includes: S101: Obtain the attribute value of the current terminal's preset attribute; wherein, the terminal is currently communicating based on the number corresponding to the first network, and the preset attribute includes at least one of the following: geographical location and network identification information received from cell broadcast.
[0020] The public / private network number switching method provided in this application is applied to a terminal, which can be a mobile terminal (such as a mobile phone). The terminal has a SIM card inserted, and to achieve automated switching between public and private network numbers, the SIM card is configured with multiple numbers per card. Separate, isolated public network parameter security storage partitions and private network parameter security storage partitions are set within the SIM card. The public network number and private network number are written to these isolated security storage partitions, specifically, the public network number is written to the public network parameter security storage partition of the SIM card, and the private network number is written to the private network parameter storage partition of the SIM card.
[0021] In addition, the SIM card provided in this application embodiment has a user identification application toolkit (STK) program embedded in it. The STK program can call network parameters in any partition and set them as the currently effective network identity.
[0022] To determine whether to switch the currently used number, the terminal first identifies the number it is currently using for communication and its corresponding first network. Specifically, the terminal sends an STK query command to the STK program on its SIM card. Upon receiving the STK query command, the STK program sends the currently used number and its corresponding communication network type (i.e., the first network) identifier to the terminal. The terminal receives the currently used number and its corresponding first network identifier, and determines the first network to which the number belongs based on the first network identifier and the stored correspondence between communication network type identifiers and communication network types.
[0023] The first network is either a private network or a public network.
[0024] Furthermore, in order to determine whether the terminal needs to be switched from the current first network to the second network, the terminal will also obtain the attribute value of the current preset attribute.
[0025] Among them, the preset attributes are those that can be used to determine the type of communication network the terminal is in.
[0026] For example, since the geographical location of a terminal determines the base station signals it can receive (private network signals emitted by private network base stations or public network signals emitted by public network base stations), the type of communication network the terminal is in can be determined by the attribute value of its geographical location. Furthermore, the network identification information received by the terminal from the cell broadcast is a network identification parameter carried in the System Information Block Type 1 (SIB1) message sent by the base station. The network identification information configured for public networks and private networks is different; that is, the network identification information corresponds one-to-one with the communication network type. Therefore, the attribute value of the network identification information can be used to determine the type of communication network the terminal is in.
[0027] Therefore, in this embodiment of the application, the preset attributes include at least one of geographical location and network identification information received from cell broadcast.
[0028] Therefore, if the preset attributes include geographic location, the attribute value of the current terminal's geographic location is obtained through the Global Positioning System (GPS) or the BeiDou Navigation Satellite System. The geographic location attribute value is the current location coordinates of the terminal; these current location coordinates are the latitude and longitude of the current terminal location.
[0029] If the preset attributes include the network identification information received from the cell broadcast, the terminal receives the SIB1 message broadcast from the cell and parses the SIB1 message to obtain the attribute value of the network identification information carried in the SIB1 message. The attribute value of the network identification information is the specific string of the network identification information carried in the SIB message broadcast by the current cell.
[0030] S102: If, based on the attribute value, it is determined that the terminal meets the requirements for switching from the first network to the second network, then the communication is switched to the target number corresponding to the second network; wherein, the second network is different from the first network.
[0031] In this embodiment, after obtaining the attribute value of the current terminal's preset attribute, it is determined based on the attribute value whether the terminal currently meets the requirements for switching from the first network to the second network. The specific process of determining whether the terminal currently meets the requirements for switching from the first network to the second network based on the attribute value will be described in subsequent embodiments and will not be repeated here.
[0032] It is understandable that the second network is different from the first network; that is, if the first network is a private network, then the second network is a public network; if the first network is a public network, then the second network is a private network.
[0033] If, based on the attribute value, it is determined that the terminal meets the requirement to switch from the first network to the second network, then the terminal will switch the number used for communication to the target number corresponding to the second network, and conduct subsequent communication based on the target number.
[0034] Specifically, the terminal sends a switching command to the STK program in the SIM card, which carries the identification information of the second network.
[0035] After receiving the handover command, the STK program parses the command to obtain the identification information of the second network carried in the command; disables the parameters of the currently active first network; and, based on the identification information of the second network, reads the International Mobile Subscriber Identity (IMSI) and network parameters corresponding to the second network; based on the IMSI and network parameters of the second network, sets the second network as the currently effective network identity, and sends a handover completion feedback message back to the terminal.
[0036] After receiving the feedback message indicating that the handover is complete, the terminal sends a de-attachment signaling to the base station corresponding to the first network, disconnects the data and voice links of the first network, and clears the local registration context of the first network; it scans the dedicated frequency point of the second network and captures the synchronization signal of the second network base station; it uses the IMSI corresponding to the second network in the SIM card to initiate the authentication and attachment process, completes the registration of the second network, and thus realizes the handover to the target number corresponding to the second network for communication.
[0037] In this embodiment, the SIM card contains multiple network numbers, including private network and public network numbers. By obtaining the attribute values of the current terminal's preset attributes, and determining that the terminal meets the requirements for switching from the first network to the second network based on the attribute values, the communication is switched to the target number corresponding to the second network. This achieves automated switching between public network numbers and private network numbers, eliminating the need for manual insertion and replacement of private network SIM cards and personal public network SIM cards, reducing operational complexity and improving convenience.
[0038] Example 2: Based on the above embodiments, in this application embodiment, if the preset attributes include geographical location and network identifier information received from cell broadcast, determining the conditions for the terminal to switch from the first network to the second network based on the attribute values includes: Based on the attribute values of geographic location, determine whether the terminal meets the first result of switching from the first network to the second network; Based on the attribute values of the network identifier information received from the cell broadcast, determine whether the terminal meets the second result of switching from the first network to the second network; If both the first and second results indicate that the terminal satisfies the condition of switching from the first network to the second network, then it is determined that the terminal satisfies the condition of switching from the first network to the second network.
[0039] In this application embodiment, if there are multiple preset attributes, that is, if the preset attributes include geographical location and network identification information received from cell broadcast, then based on the attribute value of each preset attribute, it is determined whether the terminal meets the requirement of switching from the first network to the second network.
[0040] Specifically, based on the attribute value of the current terminal's geographical location, it is determined whether the terminal meets the first result of switching from the first network to the second network; based on the attribute value of the network identifier information received by the terminal from the cell broadcast, it is determined whether the terminal meets the second result of switching from the first network to the second network. The specific process of determining whether the terminal meets the requirement of switching from the first network to the second network based on the attribute value of the current terminal's geographical location and the attribute value of the received cell broadcast network identifier information will be explained in subsequent embodiments and will not be repeated here.
[0041] If both the first and second results indicate that the terminal satisfies the condition of switching from the first network to the second network, then it is determined that the terminal satisfies the condition of switching from the first network to the second network.
[0042] If at least one of the first and second results indicates that the terminal does not meet the requirement of switching from the first network to the second network, then it is determined that the current terminal does not meet the requirement of switching from the first network to the second network.
[0043] Example 3: Based on the above embodiments, in this embodiment, if the preset attribute includes geographical location, determining whether the terminal meets the requirements for switching from the first network to the second network based on the attribute value includes: Based on whether the geographic location corresponding to the attribute value is within the preset private network geofence, a first judgment result is determined; based on the first judgment result and the type of the first network, it is determined whether the terminal meets the requirement to switch from the first network to the second network.
[0044] Based on the attribute value of the geographic location, it is determined whether the current geographic location of the terminal is within the preset private network geofence, and the first determination result is determined. The preset private network geofence is a virtual independent boundary stored within the terminal and defined by the positioning coordinates. The area enclosed by the preset private network geofence is the coverage area of the private network base station corresponding to the private network number. The terminal can determine whether it is within the private network area by comparing its own positioning information with this boundary.
[0045] Specifically, if the preset private network geofence is a circular fence, then based on the current location coordinates corresponding to the terminal's geographical location, the distance between the current location coordinates and the center point of the fence is calculated. If the distance is less than the preset radius, the first judgment result is determined to be that the current terminal is located within the preset private network geofence; if the distance is not less than the preset radius, the first judgment result is determined to be that the current terminal is not located within the preset private network geofence.
[0046] If the preset private network geofence is a polygonal fence, then the ray method or point containment algorithm is used to determine whether the current location coordinates of the terminal fall inside the polygon. If yes, the first judgment result is determined to be that the current terminal is located within the preset private network geofence; if no, the first judgment result is determined to be that the current terminal is not located within the preset private network geofence.
[0047] Furthermore, it is understood that, in order to avoid drift misjudgment, in this embodiment of the application, the first judgment result can be determined as the current terminal being located within the preset private network geofence only if the terminal's location results fall within the preset private network geofence for N consecutive times; otherwise, the first judgment result is determined as the current terminal not being located within the preset private network geofence. Here, N is a positive integer greater than 1.
[0048] After obtaining the first judgment result, based on the first judgment result of whether the current terminal is located within the preset private network geofence, the first predicted network type corresponding to the terminal is determined; based on the first predicted network type corresponding to the terminal and the type of the first network, it is determined whether the terminal meets the requirement of switching from the first network to the second network.
[0049] Specifically, if the type of the first predicted network currently corresponding to the terminal is different from the type of the first network, then the terminal is determined to meet the requirement of switching from the first network to the second network. If the type of the first predicted network currently corresponding to the terminal is the same as the type of the first network, then the terminal is determined not to meet the requirement of switching from the first network to the second network.
[0050] Example 4: Based on the above embodiments, in this embodiment, determining whether the terminal meets the requirements for switching from the first network to the second network based on the first judgment result and the type of the first network includes: If the first network is a private network, and the first determination result is that the geographical location is outside the preset private network geofence, then it is determined that the terminal meets the requirements for switching from the private network to the public network; If the first network is a public network, and the first judgment result is that the final geographical location is within the preset private network geofence, then it is determined that the terminal meets the requirements for switching from the public network to the private network.
[0051] In this embodiment of the application, if the first determination result is that the geographical location is outside the preset private network geofence, then the first predicted network type corresponding to the terminal is determined to be the public network. If the first network where the terminal is currently located is a private network, then it is determined that the communication network type of the terminal needs to be switched, and it is determined that the terminal meets the requirements for switching from the private network to the public network, that is, it is determined that the terminal meets the requirements for switching from the first network to the second network. If the first network where the terminal is currently located is a public network, then it is determined that the terminal does not meet the requirements for switching from the private network to the public network, so there is no need to switch the communication network type of the terminal.
[0052] If the first judgment result is that the geographical location is within the preset private network geofence, then the first predicted network type corresponding to the terminal is determined to be a private network. If the first network where the terminal is currently located is a public network, then it is determined that the terminal's communication network type needs to be switched, and it is determined that the terminal meets the requirements for switching from a public network to a private network, that is, it is determined that the terminal meets the requirements for switching from the first network to the second network. If the first network where the terminal is currently located is a private network, then it is determined that the terminal does not meet the requirements for switching from a public network to a private network, so there is no need to switch the terminal's communication network type.
[0053] Example 5: Based on the above embodiments, in this application embodiment, if the preset attribute includes the network identifier information received from the cell broadcast, then determining whether the terminal meets the requirements for switching from the first network to the second network based on the attribute value includes: The attribute values are matched with the saved private network identification information to determine whether a second judgment result is successful; based on the second judgment result and the type of the first network, it is determined whether the terminal meets the requirements for switching from the first network to the second network.
[0054] In this embodiment, if the preset attribute includes the network identifier information received from the cell broadcast, the attribute value of the network identifier information is matched with the stored private network identifier information to determine a second judgment result indicating whether the match is successful. The private network identifier information is the private network identifier information corresponding to the private network number in the SIM card.
[0055] Based on the second judgment result of whether the match is successful, the second predicted network type corresponding to the terminal is determined; according to the second predicted network type corresponding to the terminal, i.e. the type of the first network, it is determined whether the terminal meets the requirement of switching from the first network to the second network.
[0056] Specifically, if the type of the second predicted network currently corresponding to the terminal is different from the type of the first network, then the terminal is determined to meet the requirement of switching from the first network to the second network. If the type of the second predicted network currently corresponding to the terminal is the same as the type of the first network, then the terminal is determined not to meet the requirement of switching from the first network to the second network.
[0057] Example 6: Based on the above embodiments, in this application embodiment, the network identification information includes at least one of the following: Public Land Mobile Network (PLMN) information and extended field field in SIB1 message.
[0058] In this embodiment of the application, the network identification information includes at least one of the following: PLMN information and extended field fields within the SIB1 message.
[0059] Specifically, if the network identification information includes PLMN information, then the private network identification information is the PLMN string corresponding to the private network number. After receiving the SIBI message broadcast by the cell and parsing the SIB1 message, the terminal obtains the target PLMN information carried in the SIB1 message and uses the string of the target PLMN information as the attribute value corresponding to the network identification information.
[0060] Then, the target PLMN information is matched with the PLMN string corresponding to the saved private network number to determine whether the match is successful.
[0061] If the network identification information includes an extended field field within the SIB1 message, then the private network identification information is the target private network string corresponding to the private network number. When a terminal receives an SIB1 message broadcast by the cell, it parses the SIB1 message and first determines whether the SIB1 message carries an extended field field.
[0062] If it is determined that the SIB1 message carries an extended field, the target string within the extended field is used as the attribute value corresponding to the network identification information; and the target string is matched with the target private network string corresponding to the private network number to determine whether the match is successful.
[0063] If it is determined that the SIB1 message does not carry an extended field, the second judgment result is determined to be a match failure.
[0064] Example 7: Based on the above embodiments, in this embodiment, determining whether the terminal meets the requirements for switching from the first network to the second network based on the second judgment result and the type of the first network includes: If the first network is a private network and the second judgment result is a match failure, then it is determined that the terminal meets the requirements for switching from the private network to the public network. If the first network is a public network and the second judgment result is a successful match, then it is determined that the terminal meets the requirements for switching from the public network to the private network.
[0065] In this embodiment of the application, if the second judgment result is a matching failure, it is determined that the second predicted network type currently corresponding to the terminal is a public network; then if the first network where the terminal is currently located is a private network, it is determined that the communication network type of the terminal needs to be switched, and it is determined that the terminal meets the requirements for switching from a private network to a public network, that is, it is determined that the terminal meets the requirements for switching from the first network to the second network; if the first network where the terminal is currently located is a public network, it is determined that the terminal does not meet the requirements for switching from a private network to a public network, so there is no need to switch the communication network type of the terminal.
[0066] If the second judgment result is a successful match, then the second predicted network type corresponding to the terminal is determined to be a private network. If the first network where the terminal is currently located is a public network, then it is determined that the terminal's communication network type needs to be switched, and the terminal is determined to meet the requirements for switching from a public network to a private network, that is, the terminal is determined to meet the requirements for switching from the first network to the second network. If the first network where the terminal is currently located is a private network, then it is determined that the terminal does not meet the requirements for switching from a public network to a private network, so there is no need to switch the terminal's communication network type.
[0067] Example 8: Based on the above embodiments, the method in this application embodiment further includes: If, based on attribute values, it is determined that the terminal does not meet the requirements for switching from the first network to the second network, communication continues based on the first network.
[0068] In this embodiment of the application, for each preset attribute, based on the attribute value corresponding to the preset attribute, it is determined whether the terminal meets the requirement of switching from the first network to the second network corresponding to the preset attribute.
[0069] If a terminal does not meet the requirements for switching from the first network to the second network corresponding to any preset attribute, it is determined that there is no need to switch the current communication network type, and communication will continue based on the first network.
[0070] Example 9: Based on the same technical concept, and on the basis of the above embodiments, this application provides a public network and private network number switching device, which is applied to a terminal. The terminal has a SIM card inserted in it, wherein the SIM card has a private network number and a public network number written in it. Figure 2 A schematic diagram of a public / private network number switching device provided in this application embodiment is shown below. Figure 2 As shown, the device includes: The acquisition module 201 is used to acquire the attribute values of the current terminal's preset attributes; wherein, the terminal is currently communicating based on the number corresponding to the first network, and the preset attributes include at least one of the following: geographical location and network identification information received from cell broadcasts; The processing module 202 is used to switch to communication based on the target number corresponding to the second network when it is determined, based on the attribute value, that the terminal meets the requirements for switching from the first network to the second network; wherein the second network is different from the first network.
[0071] In one possible implementation, if the preset attributes include geographic location and network identification information received from cell broadcast, then the processing module 202 is specifically used to determine whether the terminal meets the first result of switching from the first network to the second network based on the attribute value of geographic location; and to determine whether the terminal meets the second result of switching from the first network to the second network based on the attribute value of the network identification information received from cell broadcast; and if both the first result and the second result are that the terminal meets the condition of switching from the first network to the second network, then it is determined that the terminal meets the condition of switching from the first network to the second network.
[0072] In one possible implementation, if the preset attribute includes geographic location, then the processing module 202 is specifically used to determine a first judgment result based on whether the geographic location corresponding to the attribute value is within a preset private network geofence; and based on the first judgment result and the type of the first network, determine whether the terminal meets the requirement to switch from the first network to the second network.
[0073] In one possible implementation, the processing module 202 is specifically configured to determine that the terminal meets the requirements for switching from the private network to the public network if the first network is a private network and the first determination result is that the geographical location is outside the preset private network geofence; and to determine that the terminal meets the requirements for switching from the public network to the private network if the first network is a public network and the first determination result is that the terminal geographical location is inside the preset private network geofence.
[0074] In one possible implementation, if the preset attribute includes the network identification information received from the cell broadcast, then the processing module 202 is specifically used to match the attribute value with the stored private network identification information to determine a second judgment result of whether the match is successful; based on the second judgment result and the type of the first network, to determine whether the terminal meets the requirement of switching from the first network to the second network.
[0075] In one possible implementation, the network identification information includes at least one of the following: Public Land Mobile Network (PLMN) information and extended field fields within the System Information Block (SIB1) message.
[0076] In one possible implementation, the processing module 202 is specifically configured to determine that the terminal meets the requirements for switching from the private network to the public network if the first network is a private network and the second judgment result is a matching failure; and to determine that the terminal meets the requirements for switching from the public network to the private network if the first network is a public network and the second judgment result is a matching success.
[0077] In one possible implementation, the processing module 202 is further configured to continue communication based on the first network if, based on the attribute value, it is determined that the terminal does not meet the requirements for switching from the first network to the second network.
[0078] Example 10: Based on the same technical concept, this application also provides an electronic device. Figure 3 This application provides a schematic diagram of an electronic device structure, such as... Figure 3 As shown, it includes: processor 301, communication interface 302, memory 303 and communication bus 304, wherein processor 301, communication interface 302 and memory 303 communicate with each other through communication bus 304; The memory 303 stores a computer program. When the program is executed by the processor 301, the processor 301 performs the following steps: Obtain the attribute values of the current terminal's preset attributes; wherein, the terminal is currently communicating based on the number corresponding to the first network, and the preset attributes include at least one of the following: geographical location and network identification information received from cell broadcasts; Based on attribute values, if it is determined that the terminal meets the requirements for switching from the first network to the second network, then the communication is switched to the target number corresponding to the second network; wherein the second network is different from the first network.
[0079] In one possible implementation, if the preset attributes include geographic location and network identification information received from cell broadcast, then the processor 301 is specifically used to determine whether the terminal satisfies the first result of switching from the first network to the second network based on the attribute value of geographic location; and to determine whether the terminal satisfies the second result of switching from the first network to the second network based on the attribute value of the network identification information received from cell broadcast; and if both the first result and the second result are satisfactory for the terminal to switch from the first network to the second network, then it is determined that the terminal satisfies the condition of switching from the first network to the second network.
[0080] In one possible implementation, if the preset attribute includes geographic location, then the processor 301 is specifically used to determine a first judgment result based on whether the geographic location corresponding to the attribute value is within a preset private network geofence; and based on the first judgment result and the type of the first network, determine whether the terminal meets the requirement to switch from the first network to the second network.
[0081] In one possible implementation, the processor 301 is specifically configured to determine that the terminal meets the requirements for switching from the private network to the public network if the first network is a private network and the first determination result is that the geographical location is outside the preset private network geofence; and to determine that the terminal meets the requirements for switching from the public network to the private network if the first network is a public network and the first determination result is that the geographical location is inside the preset private network geofence.
[0082] In one possible implementation, if the preset attribute includes the network identification information received from the cell broadcast, then the processor 301 is specifically used to match the attribute value with the stored private network identification information to determine a second judgment result of whether the match is successful; based on the second judgment result and the type of the first network, to determine whether the terminal meets the requirement of switching from the first network to the second network.
[0083] In one possible implementation, the network identification information includes at least one of the following: Public Land Mobile Network (PLMN) information and extended field fields within the System Information Block (SIB1) message.
[0084] In one possible implementation, the processor 301 is specifically configured to determine that the terminal meets the requirements for switching from the private network to the public network if the first network is a private network and the second determination result is a matching failure; and to determine that the terminal meets the requirements for switching from the public network to the private network if the first network is a public network and the second determination result is a matching success.
[0085] In one possible implementation, the processor 301 is further configured to continue communication based on the first network if, based on the attribute value, it is determined that the terminal does not meet the requirements for switching from the first network to the second network.
[0086] The communication bus mentioned in the above electronic devices can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into address bus, data bus, control bus, etc. For ease of illustration, only one thick line is used to represent it in the diagram, but this does not mean that there is only one bus or one type of bus.
[0087] Communication interface 302 is used for communication between the above-mentioned electronic device and other devices.
[0088] The memory may include random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.
[0089] The processors mentioned above can be general-purpose processors, including central processing units, network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits, field-programmable gate arrays or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
[0090] Example 11: Based on the same technical concept, embodiments of this application provide a computer-readable storage medium storing a computer program executable by an electronic device. When the program is run on the electronic device, it causes the electronic device to implement any of the above embodiments.
[0091] The aforementioned computer-readable storage medium can be any available medium or data storage device that can be accessed by the processor in an electronic device, including but not limited to magnetic storage such as floppy disks, hard disks, magnetic tapes, magneto-optical disks (MO), optical storage such as CDs, DVDs, BDs, HVDs, etc., and semiconductor storage such as ROMs, EPROMs, EEPROMs, non-volatile memory (NAND flash), solid-state drives (SSDs), etc.
[0092] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0093] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to this application. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0094] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0095] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0096] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Therefore, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application also intends to include such modifications and variations.
Claims
1. A method for switching between public and private network numbers, characterized in that, The method is applied to a terminal, wherein a SIM card is inserted into the terminal, and the SIM card contains a private network number and a public network number; the method includes: Obtain the attribute value of the current preset attribute of the terminal; wherein the terminal is currently communicating based on the number corresponding to the first network, and the preset attribute includes at least one of the following: geographical location and network identification information received from cell broadcast; Based on the attribute value, if it is determined that the terminal meets the requirement to switch from the first network to the second network, then the terminal switches to communication based on the target number corresponding to the second network; wherein the second network is different from the first network.
2. The method according to claim 1, characterized in that, If the preset attributes include geographical location and network identifier information received from cell broadcasts, determining that the terminal meets the conditions for switching from the first network to the second network based on the attribute values includes: Based on the attribute values of the geographical location, determine whether the terminal meets the first result of switching from the first network to the second network; Based on the attribute values of the network identifier information received from the cell broadcast, determine whether the terminal meets the second result of switching from the first network to the second network; If both the first result and the second result indicate that the terminal satisfies the condition of switching from the first network to the second network, then it is determined that the terminal satisfies the condition of switching from the first network to the second network.
3. The method according to claim 1, characterized in that, If the preset attribute includes geographical location, then based on the attribute value, determining whether the terminal meets the requirements for switching from the first network to the second network includes: Based on whether the geographical location corresponding to the attribute value is within the preset private network geofence, a first judgment result is determined; based on the first judgment result and the type of the first network, it is determined whether the terminal meets the requirement of switching from the first network to the second network.
4. The method according to claim 3, characterized in that, The step of determining whether the terminal meets the requirements for switching from the first network to the second network based on the first judgment result and the type of the first network includes: If the first network is a private network, and the first determination result is that the geographical location is outside the preset private network geofence, then it is determined that the terminal meets the requirements for switching from the private network to the public network. If the first network is a public network, and the first determination result is that the final geographical location is within the preset private network geofence, then it is determined that the terminal meets the requirements for switching from the public network to the private network.
5. The method according to claim 1, characterized in that, If the preset attribute includes network identifier information received from a cell broadcast, then determining whether the terminal meets the requirements for switching from the first network to the second network based on the attribute value includes: The attribute value is matched with the stored private network identification information to determine whether a second judgment result is successful; based on the second judgment result and the type of the first network, it is determined whether the terminal meets the requirements for switching from the first network to the second network.
6. The method according to claim 5, characterized in that, The network identification information includes at least one of the following: Public Land Mobile Network (PLMN) information and extended field fields within the System Information Block (SIB1) message.
7. The method according to claim 5, characterized in that, The step of determining whether the terminal meets the requirements for switching from the first network to the second network based on the second judgment result and the type of the first network includes: If the first network is a private network and the second judgment result is a matching failure, then it is determined that the terminal meets the requirements for switching from the private network to the public network; If the first network is a public network and the second judgment result is a successful match, then it is determined that the terminal meets the requirements for switching from the public network to the private network.
8. The method according to any one of claims 1-7, characterized in that, The method further includes: If, based on the attribute value, it is determined that the terminal does not meet the requirement of switching from the first network to the second network, communication continues based on the first network.
9. A public / private network number switching device, characterized in that, Applied to a terminal, the terminal having a SIM card inserted therein, wherein the SIM card contains a private network number and a public network number; the device includes: The acquisition module is used to acquire the attribute value of the current preset attribute of the terminal; wherein the terminal is currently communicating based on the number corresponding to the first network, and the preset attribute includes at least one of the following: geographical location and network identification information received from cell broadcast; The processing module is configured to, based on the attribute value, determine that the terminal meets the requirement of switching from the first network to the second network, and then switch to communication with the target number corresponding to the second network; wherein the second network is different from the first network.
10. An electronic device, characterized in that, The electronic device includes at least a processor and a memory, wherein the processor is used to execute a computer program stored in the memory to implement the steps of the public network / private network number switching method as described in any one of claims 1-8.