Seed number management method and device for equipment side
By dynamically managing seed number status in IoT devices, the problem of initial seed number conflict is solved, and the success rate of the first boot of the device is improved.
Patent Information
- Application Number
- CN202411770742.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-04
- Publication Date
- 2025-03-11
AI Technical Summary
When the IoT device is deployed, the source of the initial seed number is not large enough, resulting in the same initial seed number conflicting when multiple devices are turned on at the same time, and the device business number cannot be downloaded.
When the device is powered on/reset/restart, the card number status is identified and the seed number is dynamically managed according to the initial seed status, service number status and conventional seed status. Including logging in based on the initial seed number, downloading the service number, switching to a regular seed package, and switching back to the initial seed state in abnormal situations.
It reduces the frequency of the initial seed number and the duration of a single use, reduces the frequency of seed number conflicts, and improves the success rate of the first boot of the device.
Smart Images

Figure CN119603670A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a seed number management method and device at a device end. Background Art
[0002] The main way for IoT devices to connect to the Internet is through the device's embedded identity module (such as an eSIM module, vSIM module, etc.). The identity module uses the code data stored locally in the module to log in to the mobile communication network for authentication. If the authentication is successful, the IoT device is successfully connected to the Internet, otherwise it fails. When the IoT device is deployed, a seed package (also called an initial seed package) with multiple initial seed numbers will be preset in its firmware. When the device is turned on for the first time, it will connect to the Internet based on the initial seed number and download the device business number from the remote server. After the device business number is successfully downloaded, it will connect to the Internet and interact with data based on the device business number. But if that's all, we will find a problem: when the source of the initial seed number is not large enough, it is often encountered that two or more devices are turned on at the same time and use the same initial seed number to log in. In this case, all devices with the same number cannot work normally or successfully download the device business number.
[0003] In order to improve this situation, we have reduced the frequency of use of the initial seed number, shortened the duration of a single use, and relied on dynamically downloaded regular seed numbers for functional replacement. This can reduce the frequency of conflicts in the initial seed number and increase the first boot success rate of the device. Summary of the invention
[0004] The purpose of the present invention is to provide a seed number management method, device, electronic device and computer-readable storage medium for the device end in view of the defects of the prior art. The present invention first identifies the card number status when the device is turned on / reset / restarted; and when the card number status is the initial seed status, the network is logged in and the service number is downloaded based on the initial seed, and when the service number is successfully downloaded, the card number status is set to the service number status A and restarted; and when the card number status is the service number status A, the network is connected based on the service number and the conventional seed package is downloaded, and when the seed package is successfully downloaded, the card number status is set to the service number status B and restarted; and when the card number status is the service number status B, the network is connected based on the service number, and when the service number is abnormal, the network task is undertaken based on the seed number of the conventional seed package, and the card number status is set to the conventional seed state; and when the card number status is the conventional seed state, the network is logged in based on the conventional seed number, and when all conventional seed numbers are abnormal, the card number status is returned to the initial seed state. The present invention can reduce the frequency of use of the initial seed number and shorten the single use time of the initial seed number, thereby achieving the purpose of reducing the frequency of seed number conflicts and improving the first boot success rate.
[0005] To achieve the above object, a first aspect of an embodiment of the present invention provides a seed number management method on a device side, the method comprising:
[0006] When the first device is powered on, reset or restarted, the card number status stored locally on the device is identified; the card number status includes an initial seed status, a business number status A, a business number status B, and a regular seed status, and the initial value of the card number status is the initial seed status;
[0007] If the card number status is the initial seed status, then identify whether the previous card number stored locally on the device is empty; if so, select an initial seed number from the initial seed package preset in the firmware as the current seed number, otherwise select an initial seed number that does not match the previous card number from the initial seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, perform a login operation again based on the current seed number until the number of consecutive login failures exceeds a preset first threshold, then set the previous card number as the current seed number and restart the device; if the login is successful, apply to the remote server for the device business number to be stored locally on the device, and when the device business number is successfully stored, set the card number status to business number status A and restart the device; the initial value of the previous card number is empty; the initial seed package consists of multiple initial seed numbers;
[0008] If the card number status is business number status A, a login operation is performed based on the device business number; if the login fails, a login operation is performed again based on the device business number until the number of consecutive login failures exceeds the first number threshold, the card number status is set to the initial seed state and the device is restarted; if the login is successful, a regular seed package is applied to the remote server to be stored locally on the device, and the card number status is set to business number status B when the regular seed package is successfully stored; the regular seed package consists of multiple regular seed numbers;
[0009] If the card number status is business number status B, the network login operation is performed based on the device business number; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, the card number status is set to the regular seed state and the device is restarted;
[0010] If the card number status is a regular seed status, then identify whether the previous operator identifier stored locally on the device is empty; if so, select one of the regular seed numbers in the regular seed package that belongs to a different telecom operator than the device business number as the current seed number and set the previous operator identifier to the telecom operator identifier corresponding to the current seed number; otherwise, select one of the regular seed numbers that does not match the previous card number from the regular seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, further perform a login operation on all the regular seed numbers in the regular seed package. If the login is successful, apply to the remote server for a new device service number and store it locally, and when the device service number is successfully stored, set the card number status to service number status B and restart the device; the initial value of the previous service provider identifier is empty.
[0011] Preferably, the application for the device service number from the remote server is stored locally on the device, or the application for a new device service number from the remote server is stored locally on the device, specifically includes: the first device sends a service number download request to the remote server; and the service number issued by the remote server is stored locally on the device as the corresponding device service number.
[0012] Preferably, the step of applying to the remote server for storing a regular seed package locally on the device specifically includes: the first device sends a seed package download request to the remote server; and stores the seed package sent by the remote server as the corresponding regular seed package locally on the device.
[0013] Preferably, the method includes: each time the first device sets the card number status to the regular seed status, all the regular seed numbers in the regular seed package are marked as available numbers, and each time the number of consecutive failed attempts to log on to the Internet based on one regular seed number exceeds the first number threshold, the current regular seed number is marked as an unavailable number; and each time it is confirmed whether all the regular seed numbers in the regular seed package have failed to log on to the Internet, if all the regular seed numbers are unavailable numbers, the confirmation result is set to yes, and if at least one of the regular seed numbers is an available number, the confirmation result is set to no.
[0014] Preferably, the method includes: the first device monitors the networking status in real time after each successful network login, and immediately restarts the device once a network disconnection occurs.
[0015] Preferably, the initial seed package contains the initial seed numbers of multiple telecom operators, and the ratio of the number quantities of each telecom operator meets the preset first ratio; the regular seed package contains the initial seed numbers of multiple telecom operators, and the ratio of the number quantities of each telecom operator meets the preset second ratio; the first ratio is more balanced than the second ratio.
[0016] A second aspect of an embodiment of the present invention provides a device for implementing the seed number management method of a device end as described in the first aspect, the device comprising: a card number status identification module, a first status processing module, a second status processing module, a third status processing module and a fourth status processing module;
[0017] The card number status identification module is used to identify the card number status stored locally on the device when the device is powered on, reset or restarted; the card number status includes initial seed status, business number status A, business number status B, and regular seed status, and the initial value of the card number status is the initial seed status;
[0018] The first state processing module is used to identify whether the previous card number stored locally on the device is empty when the card number state is the initial seed state; if so, select an initial seed number from the initial seed package preset in the firmware as the current seed number; otherwise, select an initial seed number that does not match the previous card number from the initial seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, perform a login operation again based on the current seed number until the number of consecutive login failures exceeds a preset first threshold, then set the previous card number as the current seed number and restart the device; if the login is successful, apply to the remote server for the device business number to be stored locally on the device, and set the card number state to business number state A and restart the device when the device business number is successfully stored; the initial value of the previous card number is empty; the initial seed package is composed of multiple initial seed numbers;
[0019] The second status processing module is used to perform a network login operation based on the device business number when the card number status is business number status A; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, the card number status is set to the initial seed state and the device is restarted; if the network login is successful, a regular seed package is applied to the remote server to be stored locally on the device, and the card number status is set to business number status B when the regular seed package is successfully stored; the regular seed package consists of multiple regular seed numbers;
[0020] The third status processing module is used to perform a login operation based on the device business number when the card number status is business number status B; if the login fails, the login operation is performed again based on the device business number until the number of consecutive login failures exceeds the first number threshold, then the card number status is set to a regular seed status and the device is restarted;
[0021] The fourth state processing module is used to identify whether the previous operator identifier stored locally in the device is empty when the card number state is a regular seed state; if so, select one of the regular seed numbers belonging to a different telecom operator from the device business number from the regular seed package as the current seed number and set the previous operator identifier to the telecom operator identifier corresponding to the current seed number; otherwise, select one of the regular seed numbers that does not match the previous card number from the regular seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, further perform a login operation on all the regular seed numbers in the regular seed package. It is confirmed whether all the regular seed numbers have failed to log in to the network. If it is confirmed to be yes, the previous card number and the previous operator identifier are cleared, the card number status is set to the initial seed status and the device is restarted; if it is confirmed to be no, the network login operation is performed again based on the current seed number until the number of consecutive network login failures exceeds the first threshold, the previous card number is set to the current seed number and the device is restarted; if the network login is successful, an application is made to the remote server for a new device business number to be stored locally on the device, and when the device business number is successfully stored, the card number status is set to business number status B and the device is restarted; the initial value of the previous operator identifier is empty.
[0022] A third aspect of an embodiment of the present invention provides an electronic device, including: a memory, a processor, and a transceiver;
[0023] The processor is used to couple with the memory, read and execute instructions in the memory, so as to implement the method steps described in the first aspect above;
[0024] The transceiver is coupled to the processor, and the processor controls the transceiver to send and receive messages.
[0025] A fourth aspect of an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions. When the computer instructions are executed by a computer, the computer executes the instructions of the method described in the first aspect above.
[0026] The embodiment of the present invention provides a device-side seed number management method, device, electronic device and computer-readable storage medium. As can be seen from the above content, the embodiment of the present invention first identifies the card number status when the device is turned on / reset / restarted; and when the card number status is the initial seed status, the network is logged in and the service number is downloaded based on the initial seed, and when the service number is successfully downloaded, the card number status is set to the service number status A and restarted; and when the card number status is the service number status A, the network is connected based on the service number and the conventional seed package is downloaded, and when the seed package is successfully downloaded, the card number status is set to the service number status B and restarted; and when the card number status is the service number status B, the network is connected based on the service number, and when the service number is abnormal, the network task is undertaken based on the seed number of the conventional seed package, and the card number status is set to the conventional seed state; and when the card number status is the conventional seed state, the network is logged in based on the conventional seed number, and when all conventional seed numbers are abnormal, the card number status is returned to the initial seed state. The embodiment of the present invention reduces the use frequency of the initial seed number and shortens the single use time of the initial seed number, thereby further reducing the seed number conflict frequency and improving the first boot success rate. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 A schematic diagram of a seed number management method for a device provided in Embodiment 1 of the present invention;
[0028] Figure 2 A module structure diagram of a seed number management device on a device side provided in the second embodiment of the present invention;
[0029] Figure 3 A schematic diagram of the structure of an electronic device provided in Embodiment 3 of the present invention. DETAILED DESCRIPTION
[0030] In order to make the purpose, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0031] Embodiment 1 of the present invention provides a seed number management method for a device end, such as Figure 1 As shown in the schematic diagram of a seed number management method for a device provided in the first embodiment of the present invention, the method mainly includes the following steps:
[0032] Step 1: When the first device is powered on, reset or restarted, the card number status stored locally on the device is identified.
[0033] Here, the card number status of the embodiment of the present invention includes initial seed status, business number status A, business number status B, and regular seed status; and before the first device is powered on for the first time, the initial value of the card number status is set to the initial seed status.
[0034] Step 2, if the card number status is the initial seed status, then identify whether the previous card number stored locally in the device is empty; if so, select an initial seed number from the initial seed package preset in the firmware as the current seed number, if not, select an initial seed number that does not match the previous card number from the initial seed package as the current seed number; and log in based on the current seed number; if the login fails, then log in again based on the current seed number until the number of consecutive login failures exceeds the preset first threshold, then set the previous card number as the current seed number and restart the device; if the login is successful, apply to the remote server for the device business number to be stored locally in the device, and when the device business number is successfully stored, set the card number status to business number status A and restart the device.
[0035] Here, the initial value of the previous card number is empty; the first number threshold is a preset threshold parameter; and the initial seed packet is composed of multiple initial seed numbers.
[0036] Applying for a device service number from a remote server and storing it locally on the device specifically includes: firstly, the device sends a service number download request to the remote server; and stores the service number sent by the remote server as the corresponding device service number locally on the device.
[0037] Step 3, if the card number status is business number status A, the network login operation is performed based on the device business number; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, the card number status is set to the initial seed state and the device is restarted; if the network login is successful, apply to the remote server for a regular seed package to be stored locally on the device, and set the card number status to business number status B when the regular seed package is successfully stored.
[0038] Here, the regular seed package consists of multiple regular seed numbers.
[0039] Applying for a regular seed package from a remote server to be stored locally on a device is specifically as follows: first, the device sends a seed package download request to the remote server; and stores the seed package sent by the remote server as a corresponding regular seed package locally on the device.
[0040] Step 4, if the card number status is business number status B, the network login operation is performed based on the device business number; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, the card number status is set to the normal seed status and the device is restarted.
[0041] Step 5, if the card number status is a regular seed status, then identify whether the previous operator identifier stored locally on the device is empty; if so, select a regular seed number from the regular seed package that belongs to a different telecom operator than the device service number as the current seed number and set the previous operator identifier to the telecom operator identifier corresponding to the current seed number; otherwise, select a regular seed number from the regular seed package that does not match the previous card number as the current seed number; and perform a network login operation based on the current seed number; if the network login fails, further confirm whether all regular seed numbers in the regular seed package have failed to log on to the network, if confirmed to be yes, clear the previous card number and the previous operator identifier, set the card number status to the initial seed status and restart the device, if confirmed to be no, perform a network login operation again based on the current seed number until the number of consecutive network login failures exceeds the first number threshold, set the previous card number to the current seed number and restart the device; if the network login is successful, apply to the remote server for a new device service number to be stored locally on the device, and set the card number status to service number status B and restart the device when the device service number is successfully stored.
[0042] Here, the initial value of the previous operator identifier is empty.
[0043] It should be noted that applying for a new device service number from a remote server and storing it locally on the device specifically includes: firstly, the device sends a service number download request to the remote server; and stores the service number sent by the remote server as the corresponding device service number locally on the device.
[0044] It should be noted that each time the first device sets the card number status to the regular seed status, it marks all regular seed numbers in the regular seed package as available numbers, and each time the number of consecutive failures to log in to the Internet based on a regular seed number exceeds the first number threshold, it marks the current regular seed number as an unavailable number; and each time when confirming whether all regular seed numbers in the regular seed package have failed to log in to the Internet, if all regular seed numbers are unavailable numbers, the confirmation result is set to yes, and if at least one regular seed number is an available number, the confirmation result is set to no.
[0045] It should also be noted that the first device monitors the network status in real time after each successful network login, and restarts the device immediately if a network disconnection occurs.
[0046] It should also be noted that the initial seed package of the embodiment of the present invention contains the initial seed numbers of multiple telecom operators, and the ratio of the number of each telecom operator meets the preset first ratio; the regular seed package contains the initial seed numbers of multiple telecom operators, and the ratio of the number of each telecom operator meets the preset second ratio; wherein the first ratio is more evenly distributed than the second ratio. For example, the initial seed package contains 60 initial seed numbers, and the telecom operators include operators A / B / C, and the first ratio is 1:1:1; the regular seed package contains 60 regular seed numbers of operators A / B / C, and the second ratio is 2:2:1.
[0047] Figure 2 The module structure diagram of a seed number management device on the device side provided in the second embodiment of the present invention is a terminal device or server that implements the aforementioned method embodiment, and can also be a device that enables the aforementioned terminal device or server to implement the aforementioned method embodiment. For example, the device can be a device or chip system of the aforementioned terminal device or server. Figure 2 As shown, the device includes: a card number status identification module 201, a first status processing module 202, a second status processing module 203, a third status processing module 204 and a fourth status processing module 205.
[0048] The card number status identification module 201 is used to identify the card number status stored locally on the device when the device is powered on, reset or restarted; the card number status includes the initial seed status, business number status A, business number status B, and regular seed status, and the initial value of the card number status is the initial seed status.
[0049] The first state processing module 202 is used to identify whether the previous card number stored locally on the device is empty when the card number state is the initial seed state; if so, an initial seed number is selected from the initial seed package preset in the firmware as the current seed number, if not, an initial seed number that does not match the previous card number is selected from the initial seed package as the current seed number; and the network login operation is performed based on the current seed number; if the network login fails, the network login operation is performed again based on the current seed number until the number of consecutive network login failures exceeds the preset first number threshold, the previous card number is set as the current seed number and the device is restarted; if the network login is successful, the device business number is applied to the remote server for storage in the local device, and the card number state is set to business number state A and the device is restarted when the device business number is successfully stored; the initial value of the previous card number is empty; the initial seed package consists of multiple initial seed numbers.
[0050] The second status processing module 203 is used to perform network login operations based on the device business number when the card number status is business number status A; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, then the card number status is set to the initial seed status and the device is restarted; if the network login is successful, a regular seed package is applied to the remote server to be stored locally on the device, and the card number status is set to business number status B when the regular seed package is successfully stored; the regular seed package consists of multiple regular seed numbers.
[0051] The third status processing module 204 is used to perform network login operations based on the device business number when the card number status is business number status B; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, then the card number status is set to the regular seed status and the device is restarted.
[0052] The fourth state processing module 205 is used to identify whether the previous operator identifier stored locally in the device is empty when the card number state is the conventional seed state; if so, select a conventional seed number from the conventional seed package that belongs to a different telecommunications operator from the device service number as the current seed number and set the previous operator identifier to the telecommunications operator identifier corresponding to the current seed number; if not, select a conventional seed number from the conventional seed package that does not match the previous card number as the current seed number; and perform a network login operation based on the current seed number; if the network login fails, further confirm whether all conventional seed numbers in the conventional seed package have failed to log in, if confirmed to be yes, clear the previous card number and the previous operator identifier, set the card number state to the initial seed state and restart the device, if confirmed to be no, perform a network login operation again based on the current seed number until the number of consecutive network login failures exceeds the first number threshold, set the previous card number to the current seed number and restart the device; if the network login is successful, apply to the remote server for a new device service number to be stored locally in the device, and set the card number state to service number state B when the device service number is successfully stored and restart the device; the initial value of the previous operator identifier is empty.
[0053] A seed number management device on the device side provided in an embodiment of the present invention can execute the method steps in the above method embodiment, and its implementation principle and technical effect are similar, which will not be repeated here.
[0054] It should be noted that it should be understood that the division of the various modules of the above device is only a division of logical functions. In actual implementation, they can be fully or partially integrated into one physical entity, or they can be physically separated. And these modules can all be implemented in the form of software called by processing elements; they can also be all implemented in the form of hardware; some modules can also be implemented in the form of software called by processing elements, and some modules can be implemented in the form of hardware. For example, the card number status identification module can be a separate processing element, or it can be integrated in a chip of the above device. In addition, it can also be stored in the memory of the above device in the form of program code, and called and executed by a processing element of the above device. The implementation of other modules is similar. In addition, these modules can be fully or partially integrated together, or they can be implemented independently. The processing element described here can be an integrated circuit with signal processing capabilities. In the implementation process, each step of the above method or each module above can be completed by an integrated logic circuit of hardware in the processor element or instructions in the form of software.
[0055] For example, the above modules may be one or more integrated circuits configured to implement the above methods, such as one or more application specific integrated circuits (ASIC), or one or more digital signal processors (DSP), or one or more field programmable gate arrays (FPGA). For another example, when a module above is implemented in the form of a processing element scheduling program code, the processing element may be a general-purpose processor, such as a central processing unit (CPU) or other processor that can call program code. For another example, these modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).
[0056] In the above embodiments, all or part of the embodiments may be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments may be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the above method embodiments are generated. The above computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The above-mentioned computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the above-mentioned computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center through wired (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, Bluetooth, microwave, etc.) methods. The above-mentioned computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or data center that includes one or more available media integrated. The above-mentioned available medium can be a magnetic medium (such as a floppy disk, a hard disk, a tape), an optical medium (such as a DVD), or a semiconductor medium (such as a solid state disk (SSD)), etc.
[0057] Figure 3 This is a schematic diagram of the structure of an electronic device provided in Embodiment 3 of the present invention. The electronic device may be a terminal device or a server for implementing the method of the aforementioned embodiment, or may be a terminal device or a server for implementing the method of the aforementioned embodiment connected to the aforementioned terminal device or server. Figure 3 As shown, the electronic device may include: a processor 301 (such as a CPU), a memory 302, and a transceiver 303; the transceiver 303 is coupled to the processor 301, and the processor 301 controls the transceiver 303. Various instructions may be stored in the memory 302 to complete various processing functions and implement the processing steps described in the aforementioned embodiment method. Preferably, the electronic device involved in the embodiment of the present invention also includes: a power supply 304, a system bus 305 and a communication port 306. The system bus 305 is used to realize the communication connection between components. The above-mentioned communication port 306 is used for connecting and communicating between the electronic device and other peripherals.
[0058] exist Figure 3The system bus 305 mentioned in the figure can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The system bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus. The communication interface is used to realize the communication between the database access device and other devices (such as clients, read-write libraries, and read-only libraries). The memory may include random access memory (RAM), and may also include non-volatile memory (Non-Volatile Memory), such as at least one disk storage.
[0059] The above-mentioned processor can be a general-purpose processor, including a central processing unit CPU, a network processor (Network Processor, NP), a graphics processing unit (Graphics Processing Unit, GPU), etc.; it can also be a digital signal processor DSP, an application-specific integrated circuit ASIC, a field programmable gate array FPGA or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0060] It should be noted that an embodiment of the present invention further provides a computer-readable storage medium, in which instructions are stored. When the computer-readable storage medium is run on a computer, the computer executes the method and processing process provided in the above embodiments.
[0061] The embodiment of the present invention provides a device-side seed number management method, device, electronic device and computer-readable storage medium. As can be seen from the above content, the embodiment of the present invention first identifies the card number status when the device is turned on / reset / restarted; and when the card number status is the initial seed status, the network is logged in and the service number is downloaded based on the initial seed, and when the service number is successfully downloaded, the card number status is set to the service number status A and restarted; and when the card number status is the service number status A, the network is connected based on the service number and the conventional seed package is downloaded, and when the seed package is successfully downloaded, the card number status is set to the service number status B and restarted; and when the card number status is the service number status B, the network is connected based on the service number, and when the service number is abnormal, the network task is undertaken based on the seed number of the conventional seed package, and the card number status is set to the conventional seed state; and when the card number status is the conventional seed state, the network is logged in based on the conventional seed number, and when all conventional seed numbers are abnormal, the card number status is returned to the initial seed state. The embodiment of the present invention reduces the use frequency of the initial seed number and shortens the single use time of the initial seed number, thereby further reducing the seed number conflict frequency and improving the first boot success rate.
[0062] The professionals should further realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to the function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0063] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0064] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A seed number management method for a device, characterized in that: The method comprises: When the first device is powered on, reset or restarted, the card number status stored locally on the device is identified; the card number status includes an initial seed status, a business number status A, a business number status B, and a regular seed status, and the initial value of the card number status is the initial seed status; If the card number status is the initial seed status, then identify whether the previous card number stored locally on the device is empty; if so, select an initial seed number from the initial seed package preset in the firmware as the current seed number, otherwise select an initial seed number that does not match the previous card number from the initial seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, perform a login operation again based on the current seed number until the number of consecutive login failures exceeds a preset first threshold, then set the previous card number as the current seed number and restart the device; if the login is successful, apply to the remote server for the device business number to be stored locally on the device, and when the device business number is successfully stored, set the card number status to business number status A and restart the device; the initial value of the previous card number is empty; the initial seed package consists of multiple initial seed numbers; If the card number status is business number status A, a login operation is performed based on the device business number; if the login fails, a login operation is performed again based on the device business number until the number of consecutive login failures exceeds the first number threshold, the card number status is set to the initial seed state and the device is restarted; if the login is successful, a regular seed package is applied to the remote server to be stored locally on the device, and the card number status is set to business number status B when the regular seed package is successfully stored; the regular seed package consists of multiple regular seed numbers; If the card number status is business number status B, the network login operation is performed based on the device business number; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, the card number status is set to the regular seed state and the device is restarted; If the card number status is a regular seed status, then identify whether the previous operator identifier stored locally on the device is empty; if so, select one of the regular seed numbers in the regular seed package that belongs to a different telecom operator than the device business number as the current seed number and set the previous operator identifier to the telecom operator identifier corresponding to the current seed number; otherwise, select one of the regular seed numbers that does not match the previous card number from the regular seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, further perform a login operation on all the regular seed numbers in the regular seed package. If the login is successful, apply to the remote server for a new device service number and store it locally, and when the device service number is successfully stored, set the card number status to service number status B and restart the device; the initial value of the previous service provider identifier is empty.
2. The device-side seed number management method according to claim 1, characterized in that: The step of applying to the remote server for a device service number and storing it locally on the device, or applying to the remote server for a new device service number and storing it locally on the device, specifically includes: The first device sends a service number download request to the remote server; and stores the service number sent by the remote server as the corresponding device service number in the local device.
3. The device-side seed number management method according to claim 1, characterized in that: The step of applying to the remote server for storing a conventional seed package locally on the device specifically includes: The first device sends a seed package download request to the remote server; and stores the seed package sent by the remote server as the corresponding regular seed package in the local device.
4. The device-side seed number management method according to claim 1, characterized in that: The method comprises: Each time the first device sets the card number status to the regular seed status, all the regular seed numbers in the regular seed package are marked as available numbers, and each time the number of consecutive failed attempts to log on to the Internet based on one regular seed number exceeds the first number threshold, the current regular seed number is marked as an unavailable number; and each time it is confirmed whether all the regular seed numbers in the regular seed package have failed to log on to the Internet, if all the regular seed numbers are unavailable numbers, the confirmation result is set to yes, and if at least one of the regular seed numbers is an available number, the confirmation result is set to no.
5. The device-side seed number management method according to claim 1, characterized in that: The method comprises: The first device monitors the network status in real time after each successful network login, and immediately restarts the device if a network disconnection occurs.
6. The device-side seed number management method according to claim 1, characterized in that: The initial seed package contains the initial seed numbers of multiple telecom operators, and the number ratio of each telecom operator meets the preset first ratio; The regular seed package contains the initial seed numbers of multiple telecom operators, and the number ratio of each telecom operator meets the preset second ratio; the first ratio is more balanced than the second ratio.
7. A device for executing the seed number management method of a device end according to any one of claims 1 to 6, characterized in that: The device comprises: a card number status identification module, a first status processing module, a second status processing module, a third status processing module and a fourth status processing module; The card number status identification module is used to identify the card number status stored locally on the device when the device is powered on, reset or restarted; the card number status includes initial seed status, business number status A, business number status B, and regular seed status, and the initial value of the card number status is the initial seed status; The first state processing module is used to identify whether the previous card number stored locally on the device is empty when the card number state is the initial seed state; if so, select an initial seed number from the initial seed package preset in the firmware as the current seed number; otherwise, select an initial seed number that does not match the previous card number from the initial seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, perform a login operation again based on the current seed number until the number of consecutive login failures exceeds a preset first threshold, then set the previous card number as the current seed number and restart the device; if the login is successful, apply to the remote server for the device business number to be stored locally on the device, and set the card number state to business number state A and restart the device when the device business number is successfully stored; the initial value of the previous card number is empty; the initial seed package is composed of multiple initial seed numbers; The second status processing module is used to perform a network login operation based on the device business number when the card number status is business number status A; if the network login fails, the network login operation is performed again based on the device business number until the number of consecutive network login failures exceeds the first number threshold, the card number status is set to the initial seed state and the device is restarted; if the network login is successful, a regular seed package is applied to the remote server to be stored locally on the device, and the card number status is set to business number status B when the regular seed package is successfully stored; the regular seed package consists of multiple regular seed numbers; The third status processing module is used to perform a login operation based on the device business number when the card number status is business number status B; if the login fails, the login operation is performed again based on the device business number until the number of consecutive login failures exceeds the first number threshold, then the card number status is set to a regular seed status and the device is restarted; The fourth state processing module is used to identify whether the previous operator identifier stored locally in the device is empty when the card number state is a regular seed state; if so, select one of the regular seed numbers belonging to a different telecom operator from the device business number from the regular seed package as the current seed number and set the previous operator identifier to the telecom operator identifier corresponding to the current seed number; otherwise, select one of the regular seed numbers that does not match the previous card number from the regular seed package as the current seed number; and perform a login operation based on the current seed number; if the login fails, further perform a login operation on all the regular seed numbers in the regular seed package. It is confirmed whether all the regular seed numbers have failed to log in to the network. If it is confirmed to be yes, the previous card number and the previous operator identifier are cleared, the card number status is set to the initial seed status and the device is restarted; if it is confirmed to be no, the network login operation is performed again based on the current seed number until the number of consecutive network login failures exceeds the first threshold, the previous card number is set to the current seed number and the device is restarted; if the network login is successful, an application is made to the remote server for a new device business number to be stored locally on the device, and when the device business number is successfully stored, the card number status is set to business number status B and the device is restarted; the initial value of the previous operator identifier is empty.
8. An electronic device, characterized in that: include: memory, processors, and transceivers; The processor is used to couple with the memory, read and execute instructions in the memory, so as to implement the method according to any one of claims 1 to 6; The transceiver is coupled to the processor, and the processor controls the transceiver to send and receive messages.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and when the computer instructions are executed by a computer, the computer executes the method according to any one of claims 1 to 6.