Activation code query method and device, electronic equipment and readable storage medium

By using the second data relationship or the third data relationship to obtain the motherboard tag in the case of abnormal device identification, the activation code is solved, and the activation code is checked due to abnormal binding relationships is ensured to normal activation and use of the device.

CN120407595APending Publication Date: 2025-08-01GUANGDONG HOTATA TECH GRP
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510530283.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-25
Publication Date
2025-08-01

AI Technical Summary

Technical Problem

When the device rework or irregular operation causes the host label to be unbound from the motherboard label, the system loses the associated information, or the host label is overwritten by a new label but is not rebinded, the existing technology cannot accurately query the activation code.

Method used

By determining the device identifier, using the second data relationship or the third data relationship to obtain the motherboard tag as the target tag, the target string is obtained to determine the activation code, the second data relationship stores the unbinding record, and the third data relationship stores the binding information, providing a multi-channel redundant binding relationship storage method.

Benefits of technology

In the case of abnormal binding relationships, the activation code can still be obtained accurately to ensure normal use of the equipment, avoid user complaints and product quality disputes, and improve the fault tolerance and robustness of the query.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120407595A_ABST
    Figure CN120407595A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an activation code query method and device, electronic equipment and a readable storage medium, and relates to the field of Internet of Things. The method comprises the steps of determining a device identifier of a to-be-queried device, wherein the device identifier comprises at least one of a first type of identifier and a second type of identifier; if the mainboard tag bound with the equipment identifier is not stored in the first data relationship, acquiring the mainboard tag corresponding to the equipment identifier as a target tag according to the second data relationship or the third data relationship; obtaining a target character string corresponding to the target tag, and determining an activation code of the to-be-queried device according to the target character string; the first data relationship stores a binding relationship between the first type of identifier and the mainboard tag; the second data relation stores the first type of identification and the corresponding mainboard label of which the binding relation is unbound; the third data relation stores the binding relation among the second type of identification, the first type of identification and the mainboard label of the equipment, and the problem that the activation code cannot be queried under the condition that the binding relation is abnormal is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of Internet of Things technology. Specifically, the present application relates to an activation code query method, device, electronic device and readable storage medium. Background Art

[0002] In the prior art, a unique binding relationship is usually established by binding a host tag and a motherboard tag. The host tag is used to identify the device externally, and the motherboard tag is stored in a chip inside the device. Under normal circumstances, the motherboard tag is queried through the host tag to obtain the device's activation code.

[0003] However, device rework or improper operation may cause the host label to become unbound from the motherboard label, causing the system to lose the associated information. Alternatively, if the host label is overwritten by a new label but not re-bound, the original activation code association cannot be retrieved. Therefore, there is a problem that activation codes cannot be accurately retrieved in abnormal situations such as unbinding or label replacement. Summary of the Invention

[0004] The embodiments of the present application provide an activation code query method, device, electronic device, and readable storage medium, which are used to solve the technical problem that the activation code cannot be queried when an abnormal binding relationship occurs.

[0005] According to a first aspect of an embodiment of the present application, a method for querying an activation code is provided, the method comprising: Determine a device identification of the device to be queried, where the device identification includes at least one of a first type identification and a second type identification; If the motherboard tag bound to the device identifier is not stored in the first data relationship, obtaining the motherboard tag corresponding to the device identifier as the target tag according to the second data relationship or the third data relationship; Obtain the target string corresponding to the target tag, and determine the activation code of the device to be queried based on the target string; Among them, the first data relationship is used to store the binding relationship between the first type of identifier and the motherboard tag; the second data relationship is used to store multiple unbinding records, each unbinding record is used to record the first type of identifier and the corresponding motherboard tag whose binding relationship has been released; the third data relationship is used to store multiple binding information, each binding information includes the binding relationship between the second type of identifier, the first type of identifier and the motherboard tag of the device.

[0006] In a possible implementation, the type of the device identifier is a first-class identifier; an unbinding record corresponding to the first-class identifier is obtained from the second data relationship; Get the first type of motherboard tag that indicates the unbinding from the unbinding record as the target tag.

[0007] In another possible implementation, the type of the device identifier is a second type identifier; The motherboard tag bound to the second type identifier is obtained from the third data relationship, and the bound motherboard tag is used as the target tag.

[0008] In another possible implementation, the type of device identifier is a first-class identifier and a second-class identifier; the unbinding record corresponding to the first-class identifier is obtained from the second data relationship, and the motherboard tag to which the first-class identifier has been unbound is obtained from the unbinding record as the target tag; or, the motherboard tag bound to the second-class identifier is obtained from the third data relationship, and the bound motherboard tag is used as the target tag.

[0009] In yet another possible implementation, when the device is in the production phase, an activation code is assigned to a motherboard tag of the device, and the activation code is burned into a motherboard chip of the device; Determine the first category identification and second category identification of the device, establish and store the binding relationship between the first category identification of the device and the motherboard label in the first data relationship, and establish and store the binding relationship between the first category identification, second category identification and motherboard label of the device to be queried in the third data relationship.

[0010] In yet another possible implementation, the method for updating the second data relationship includes: During the quality inspection phase after the equipment is produced, if it is determined that the equipment needs to be repaired, the equipment will be treated as equipment to be repaired; In response to receiving a relationship release instruction for the device to be repaired, deleting the binding relationship between the first type identifier of the device to be repaired and the motherboard label in the first data relationship and the third data relationship; Generate an unbinding record for the device to be repaired; the unbinding record includes a correspondence between the first category identifier of the device to be repaired and the motherboard label of the device to be repaired.

[0011] In yet another possible implementation, the target character string is preprocessed; Determine the hash value of the preprocessed target string using a hash algorithm; Extracting a value of a preset number of bits from the hash value as a target value; The target value is converted into a target value of a target base, and a value of a preset number of digits is extracted from the target value of the target base as the activation code of the device to be queried.

[0012] According to a second aspect of an embodiment of the present application, a device for querying an activation code is provided, the device comprising: A determination module, configured to determine a device identification of a device to be queried, where the device identification includes at least one of a first type identification and a second type identification; A processing module, configured to obtain the motherboard label corresponding to the device identifier as the target label according to the second data relationship or the third data relationship if the motherboard label bound to the device identifier is not stored in the first data relationship; An obtaining module, configured to obtain the target string corresponding to the target label and determine the activation code of the device to be queried according to the target string; Wherein, the first data relationship is used to store the binding relationship between the first type of identifier and the motherboard label; the second data relationship is used to store multiple unbinding records, and each unbinding record is used to record the first type of identifier whose binding relationship has been released and the corresponding motherboard label; the third data relationship is used to store multiple binding information, and each binding information includes the binding relationship between the second type of identifier, the first type of identifier and the motherboard label of the device.

[0013] According to the third aspect of the embodiments of the present application, an electronic device is provided. The electronic device includes a memory, a processor, and a computer program stored on the memory. When the processor executes the program, the steps of the method provided in the first aspect are implemented.

[0014] According to the fourth aspect of the embodiments of the present application, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method provided in the first aspect are implemented.

[0015] According to the fifth aspect of the embodiments of the present application, a computer program product is provided. The computer program product includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. When the processor of the computer device reads the computer instructions from the computer-readable storage medium and the processor executes the computer instructions, the computer device is enabled to execute the steps of the method provided in the first aspect.

[0016] The beneficial effects brought by the technical solutions provided by the embodiments of the present application are: The activation code query method provided by the embodiments of the present application determines a device identifier including at least one of a first type of identifier and a second type of identifier. When it is determined that the motherboard label bound to the device identifier is not stored in the binding relationship between the first type of identifier and the motherboard label, the motherboard label corresponding to the device identifier is obtained as the target label according to the second data relationship or the third data relationship, and the string corresponding to the target label is obtained. Then, the activation code of the device to be queried is determined according to the target string. Since the second data relationship stores the first type of identifier with the unbound relationship and the corresponding motherboard label, when an abnormal situation occurs where the binding relationship is temporarily released on the system and forgotten to be restored due to human error, the motherboard label corresponding to the first type of identifier can still be obtained according to the unbinding record in the second data relationship, so as to successfully obtain the corresponding activation code. Since the third data relationship stores the binding relationship between the first type of identifier, the second type of identifier and the motherboard label, when the first type of identifier corresponding to the motherboard label is replaced and the binding relationship in the first data relationship is forgotten to be updated due to human error, the corresponding motherboard label can still be obtained from the third data relationship according to the second type of identifier, so as to obtain the activation code of the device to be queried, solving the problem that the activation code of the device to be queried cannot be obtained in the case of abnormal binding relationship. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for description in the embodiments of the present application.

[0018] Figure 1 It is a schematic diagram of the system architecture for implementing the activation code query method provided by the embodiments of the present application; Figure 2 It is a schematic flowchart of a method for querying an activation code provided by the embodiments of the present application; Figure 3 It is a schematic flowchart of a method for obtaining a target label in a method for querying an activation code provided by the embodiments of the present application; Figure 4 It is a schematic flowchart of the update method of the first data relationship and the third data relationship in a method for querying an activation code provided by the embodiments of the present application; Figure 5 It is a schematic flowchart of the update method of the second data relationship in a method for querying an activation code provided by the embodiments of the present application; Figure 6 It is a schematic flowchart of the defect method of the activation code in a method for querying an activation code provided by the embodiments of the present application; Figure 7 It is a schematic flowchart of another method for querying an activation code provided by the embodiments of the present application; Figure 8Schematic structural diagram of an activation code query device provided by an embodiment of the present application; Figure 9 Schematic structural diagram of an electronic device provided by an embodiment of the present application. Detailed implementation manners

[0019] The embodiments of the present application will be described below with reference to the accompanying drawings in the present application. It should be understood that the embodiments described below in conjunction with the accompanying drawings are exemplary descriptions for explaining the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions of the embodiments of the present application.

[0020] Those skilled in the art of the present technology can understand that, unless specifically stated otherwise, the singular forms "a", "an", "" and "the" used herein may also include the plural forms. It should be further understood that the terms "including" and "comprising" used in the embodiments of the present application mean that the corresponding features can be implemented as the presented features, information, data, steps, operations, elements, and / or components, but do not exclude the implementation of other features, information, data, steps, operations, elements, components, and / or their combinations supported by the art of the present technology. It should be understood that when we say that an element is "connected" or "coupled" to another element, the one element can be directly connected or coupled to the other element, or it can mean that the one element and the other element establish a connection relationship through an intermediate element. In addition, the "connection" or "coupling" used herein may include a wireless connection or a wireless coupling. The term "and / or" used herein indicates at least one of the items defined by the term, for example, "A and / or B" can be implemented as "A", or implemented as "B", or implemented as "A and B".

[0021] To make the objectives, technical solutions, and advantages of the present application clearer, the embodiments of the present application will be described in further detail below in conjunction with the accompanying drawings.

[0022] The technical solutions of the embodiments of the present application and the technical effects produced by the technical solutions of the present application will be described below through the description of several exemplary embodiments. It should be noted that the following embodiments can refer to, draw on, or combine with each other. For the same terms, similar features, and similar implementation steps in different embodiments, they will not be described repeatedly.

[0023] Figure 1 Schematic diagram of the system architecture for implementing the activation code query method provided by an embodiment of the present application, where the system architecture includes: a terminal 120 and a server 140.

[0024] The terminal 120 installs and runs an application program for the activation code query method. The terminal 120 is used to obtain the activation code of the device to be queried according to the determined device identifier of the device to be queried.

[0025] The terminal 120 is connected to the server 140 via a wireless network or a wired network.

[0026] The server 140 includes at least one of a single server, multiple servers, a cloud computing platform, and a virtualization center. Schematically, the server 140 includes a processor 144 and a memory 142. The memory 142 includes a display module 1421, a control module 1422, and a receiving module 1423. The server 140 is used to provide background services for the application programs of the method. Optionally, the server 140 undertakes the main computing work, and the terminal 120 undertakes the secondary computing work; or, the server 140 undertakes the secondary computing work, and the terminal 120 undertakes the main computing work; or, a distributed computing architecture is adopted between the server 140 and the terminal 120 for collaborative computing.

[0027] Optionally, the device types of the terminal include at least one of a smart phone, a tablet computer, an e-book reader, a Moving Picture Experts Group Audio Layer III (MP3) player, a Moving Picture Experts Group Audio Layer IV (MP4) player, a laptop computer, and a desktop computer.

[0028] Those skilled in the art can know that the number of the above terminals can be more or less. For example, the above terminal can be only one, or the above terminals can be dozens or hundreds, or even more. The embodiments of the present application do not limit the number and device types of the terminals.

[0029] An activation code query method is provided in the embodiments of the present application. As Figure 2 shown, the method includes: S101, determining the device identifier of the device to be queried.

[0030] In the embodiments of the present application, the device to be queried refers to a smart device that needs to query and obtain an activation code to be activated through the activation code. The device to be queried can be a smart home device, such as a smart thermostat, a smart lamp, a smart door lock, etc. The device to be queried can also be a smart home appliance, such as a smart refrigerator, a smart air conditioner, a smart washing machine, a smart clothes dryer, etc.

[0031] In the embodiments of the present application, the device identifier refers to an identifier that can be used to characterize the identity of the device to be queried. The device identifier includes at least one of a first type of identifier and a second type of identifier.

[0032] In the embodiments of the present application, when querying the activation code of the device to be queried, various abnormal situations may occur. Therefore, it is possible that the obtained device identifier only contains the first type of identifier, and it is also possible that the obtained device identifier only contains the second type of identifier. Similarly, even if an abnormal situation occurs, it is possible to obtain both the first type of identifier and the second type of identifier.

[0033] In the embodiments of the present application, the first type of identifier may be the host label of the device to be queried. The host label is a label used to help the system identify information such as the model, function, and version of the device. The host label usually includes the following information: device model, device number, hardware version, software version, function characteristics, production date, etc. The host label usually appears in the form of barcodes, QR codes, etc., which is convenient for scanning and reading.

[0034] In the embodiments of the present application, the second type of identifier may be the body anti-counterfeiting code of the device to be queried. The body anti-counterfeiting code is used to ensure the authenticity of the device and represent the identity of the device. The body anti-counterfeiting code usually appears on the body of the device in the form of QR codes, barcodes, anti-counterfeiting labels, etc., and the body anti-counterfeiting code on the body can be ensured to be difficult to be replaced or modified by using technologies such as laser engraving.

[0035] S102. If the motherboard label bound to the device identifier is not stored in the first data relationship, obtain the motherboard label corresponding to the device identifier as the target label according to the second data relationship or the third data relationship.

[0036] In the embodiments of the present application, the first data relationship is used to store the binding relationship between the first type of identifier and the motherboard label. That is to say, the binding relationships between the first type of identifiers of each device and the motherboard labels of the devices are all stored in the first data relationship. If the device identifier includes the first type of identifier, the motherboard label bound to the first type of identifier can be directly obtained from the first data relationship.

[0037] In the embodiments of the present application, after obtaining the device identifier, if it is determined that the device identifier includes the first type of identifier, it is judged whether the motherboard label bound to the first type of identifier is stored in the first data relationship. If the motherboard label bound to the device identifier is not stored in the first data relationship, it indicates that the binding relationship is lost, that is, an abnormal situation has occurred. At this time, it is necessary to obtain the motherboard label corresponding to the device identifier as the target label through the second data relationship or the third data relationship.

[0038] In an embodiment of the present application, the equipment will undergo quality inspection after the production stage. If there is a problem with the equipment quality inspection, the equipment will be reworked and repaired. Due to maintenance requirements, before the equipment is reworked and repaired, the first-class identification and the mainboard label of the equipment need to be unbound on the system, so that the binding relationship between the first-class identification and the mainboard label of the equipment that needs to be reworked and repaired will be deleted from the first data relationship. After the equipment is reworked and repaired, the binding relationship between the first-class identification and the mainboard label will be re-established and stored in the first data relationship. However, due to human errors and other reasons, the binding relationship between the first-class identification and the mainboard label of the above-mentioned equipment is not re-stored in the first data relationship from the time the equipment is reworked and repaired until it is shipped out of the factory for sale. Therefore, there may be a situation where the bound mainboard label cannot be obtained through the first-class identification of the device to be queried.

[0039] However, in an embodiment of the present application, the second data relationship is used to store multiple unbinding records, each unbinding record is used to record the first-class identifier and the corresponding mainboard label whose binding relationship has been untied, that is, by generating a binding record to record the first-class identifier and the corresponding mainboard label whose binding relationship has been untied when the binding relationship between the first-class identifier and the mainboard label is untied, and the above-mentioned binding record is stored in the second data relationship, so that when the mainboard label cannot be obtained in the first data relationship due to human error or other reasons, the corresponding mainboard label can be obtained through the second data relationship.

[0040] In an embodiment of the present application, after obtaining the device identification, if it is determined that the device identification does not include the first type of identification, since the first data relationship stores the binding relationship between the first type of identification and the motherboard label, it can be directly judged that the motherboard label bound to the device identification is not stored in the first data relationship. Therefore, at this time, it is also necessary to obtain the motherboard label corresponding to the device identification through the second data relationship or the third data relationship as the target label.

[0041] In an embodiment of the present application, the device will undergo quality inspection after the production stage. If the quality inspection detects problems with the device, the device will need to be reworked and repaired. After the rework and repair is completed, in some cases, the host label of the device needs to be updated, that is, the old host label is replaced with a new host label. However, due to human errors and other reasons, after removing the old host label, the new host may be forgotten to be pasted, or after the new host label is pasted, the binding relationship between the new host label and the old host label may be forgotten to be established, so that when querying the activation code of the device, the first type of identification cannot be obtained, and thus the bound motherboard label cannot be obtained from the first data relationship according to the first type of identification, or after obtaining the first type of identification, the corresponding motherboard label cannot be obtained from the first data relationship.

[0042] To solve the above problems, an embodiment of the present application proposes a third data relationship, which is used to store multiple binding information. Each binding information includes the binding relationship between the second type identifier, the first type identifier, and the motherboard label of the device. That is, in the case where the first type identifier is not obtained, the corresponding motherboard label can be obtained as the target label from the third data relationship that pre-stores the binding relationship between the body anti-counterfeiting code and the motherboard label.

[0043] S103, obtain the target string corresponding to the target label, and determine the activation code of the device to be queried according to the target string.

[0044] In an embodiment of the present application, the target string is composed of information related to the device to be queried. After the motherboard label is generated, the target string corresponding to the motherboard label is stored in the fourth database. When the system assigns an activation code to the motherboard label during the production stage, the activation code is obtained according to the target string corresponding to the motherboard label. Therefore, after the target label is obtained, the target string corresponding to the target label is obtained from the fourth database, and then the activation code of the device to be queried is generated by combining the target string according to the activation code generation method used when the activation code is assigned.

[0045] In an embodiment of the present application, the blockchain technology can also be used to record the binding relationship between the first type identifier and the motherboard label, the contact record between the first type identifier and the motherboard label, and the binding relationship between the second type identifier and the motherboard label.

[0046] In the above solution, by determining the device identifier including at least one of the first type identifier and the second type identifier, and when it is determined that the motherboard label bound to the device identifier is not stored in the binding relationship for storing the first type identifier and the motherboard label, the motherboard label corresponding to the device identifier is obtained as the target label according to the second data relationship or the third data relationship, and the string corresponding to the target label is obtained, so as to determine the activation code of the device to be queried according to the target string. Since the second data relationship stores the first type identifier and the corresponding motherboard label with the binding relationship released, in the event of an abnormal situation where the binding relationship is temporarily released on the system and forgotten to be restored due to human error, the motherboard label corresponding to the first type identifier can still be obtained according to the unbinding record recorded in the second data relationship, so as to successfully obtain the corresponding activation code; since the third data relationship stores the binding relationship between the first type identifier, the second type identifier, and the motherboard label, in the event that the first type identifier corresponding to the motherboard label is replaced and the binding relationship in the first data relationship is forgotten to be updated due to human error, the corresponding motherboard label can still be obtained from the third data relationship according to the second type identifier, so as to obtain the activation code of the device to be queried, solving the problem that the activation code of the device to be queried cannot be obtained in the case of abnormal binding relationship.

[0047] Based on the above embodiments, as an optional embodiment, the type of device identification is the first type of identification, and the method for obtaining the target tag is as follows: Figure 3 The specific contents are as follows: S201, obtaining an unbinding record corresponding to the first type of identifier from the second data relationship; S202: Obtain a first-category motherboard tag that indicates that the motherboard has been unbound from the unbinding record as a target tag.

[0048] In S201 of the embodiment of the present application, when the type of the device identifier is a first-class identifier, if the bound motherboard tag cannot be obtained from the first data relationship, it means that the binding relationship between the first-class identifier and the motherboard tag has been released and deleted from the first data relationship, and when the binding relationship between the first-class identifier and the motherboard tag needs to be re-established and stored, the rebinding and storage are forgotten. Since the first-class identifier will generate an unbinding record when it is unbound from the motherboard tag, the unbinding record records the motherboard tag that is unbound from the first-class identifier. Therefore, when the above-mentioned motherboard tag bound to the first-class identifier cannot be obtained from the first data relationship, the unbinding record corresponding to the first-class identifier can be obtained from the second data relationship.

[0049] In S202 of the embodiment of the present application, the unbinding record records the motherboard tag that has been unbound from the first type of identifier. Therefore, the motherboard tag that has been unbound from the first type of identifier is obtained from the unbinding record as the target tag.

[0050] In the above scheme, when the first type of identification and the motherboard tag are unbound, the unbinding record corresponding to the first type of identification is stored in the second data relationship, so that when the unbound first type of identification and the motherboard tag are forgotten to be re-bound due to human error in the future, the corresponding motherboard tag can be obtained according to the first type of identification, thereby smoothly obtaining the activation code of the device to be queried, ensuring that the system can still correctly query the activation code when an abnormality occurs, ensuring the normal use of the device to be queried, improving the user experience, and avoiding user complaints and product quality disputes due to failure to activate normally.

[0051] Based on the above embodiments, as an optional embodiment, the type of the device identifier is a second-class identifier, the motherboard tag bound to the second-class identifier is obtained from the third data relationship, and the bound motherboard tag is used as the target tag.

[0052] In the embodiment of the present application, the device identification type is the second type of identification, indicating that the first type of identification of the device to be queried is missing, and the first data relationship stores the binding relationship between the first type of identification and the motherboard label. Therefore, when the device identification type is the second type of identification, the motherboard label cannot be obtained from the first data relationship. Therefore, according to the device identification type being the second type of identification, the motherboard label bound to the second type of identification is obtained from the third data relationship as the target label.

[0053] In the above solution, by storing the binding relationship between the second type of identification and the motherboard label in the third data relationship, when the first type of identification cannot be obtained, or the obtained first type of identification is a first type of identification without a binding relationship, the corresponding motherboard label can still be obtained through the body anti-counterfeiting code, ensuring that the system can correctly query the activation code of the device to be queried when an abnormality occurs, ensuring the normal use of the device to be queried, improving the user experience, and avoiding user complaints and product quality disputes caused by inability to activate normally.

[0054] Based on the above embodiments, as an optional embodiment, the device identification type is the first type of identification and the second type of identification; the unbinding record corresponding to the first type of identification is obtained from the second data relationship, and the motherboard label unbound from the first type of identification is obtained from the unbinding record as the target label; or, the motherboard label bound to the second type of identification is obtained from the third data relationship, and the bound motherboard label is used as the target label.

[0055] In the embodiment of the present application, when the device identification type is the first type of identification and the second type of identification, and the bound motherboard label cannot be obtained from the first data relationship according to the device identification, it indicates that there is an abnormality in the storage or update of the binding relationship at this time. Therefore, the unbinding record corresponding to the first type of identification can be obtained from the second data relationship through the first type of identification, so as to obtain the motherboard label unbound from the first type of identification from the unbinding record as the target label, or the motherboard label bound to the second type of identification can be obtained from the third data relationship through the second type of identification as the target label.

[0056] In one example, the first type of identifier is the host tag, and the second type of tag is the body anti-counterfeiting code. If the motherboard tag cannot be obtained from the first data relationship based on the host tag and the body anti-counterfeiting code at this time, it indicates that there is an abnormality in the cached relationship stored in the current first data relationship. Therefore, at this time, consider obtaining the motherboard tag through the second data relationship or the third data relationship. First, determine whether there is an unbinding record corresponding to the host tag stored in the second data relationship. If there is an unbinding record corresponding to the host tag stored in the second data relationship, then the motherboard tag recorded in the unbinding record can be directly used as the target tag. If there is no unbinding record corresponding to the host tag stored in the second data relationship, it means that the abnormality in the cached relationship that occurred in the current first data relationship is because after replacing the original host tag with a new host tag on the body of the device to be queried, due to human error, the binding relationship between the new host tag and the motherboard tag was forgotten to be established (that is, the binding relationship between the new host tag and the motherboard tag was not stored in the first data relationship), resulting in the inability to obtain the bound motherboard tag from the first data relationship using the new host tag. And since the new host tag has no binding relationship, there will be no unbinding record either. Therefore, the corresponding motherboard tag cannot be obtained from the second data relationship either. Then, at this time, it is necessary to obtain the corresponding motherboard tag from the third data relationship through the body anti-counterfeiting code as the target tag.

[0057] In the above solution, by storing the unbinding record in the second data relationship and storing the binding relationship between the second type of identifier and the motherboard tag in the third data relationship, the multi-path redundancy of the activation code query is further enhanced, ensuring that the activation code can still be correctly queried in the case of errors or losses in the cached relationship in the first data relationship, ensuring the normal use of the device, and improving the fault tolerance and robustness of the activation code query.

[0058] Based on the above embodiments, as an alternative embodiment, the update methods of the first data relationship and the third data relationship are as Figure 4 shown, and the specific content includes: S301, when the device is in the generation stage, assign an activation code to the motherboard tag of the device and burn the activation code into the motherboard chip of the device; S302, determine the first type of identifier and the second type of identifier of the device, establish and store the binding relationship between the first type of identifier of the device and the motherboard tag in the first data relationship, and establish and store the binding relationship between the first type of identifier, the second type of identifier, and the motherboard tag of the device to be queried in the third data relationship.

[0059] In step S301 of this embodiment, during the device's production phase, a unique activation code is assigned to each motherboard tag and burned into the device's motherboard chip. This allows the device to automatically authenticate and activate upon power-up, without relying on a network connection or external servers. This approach speeds up the activation process and reduces the impact of external factors on the activation process.

[0060] In S302 of the embodiment of the present application, the first category identification and the second category identification of the device are determined, and a binding relationship between the first category identification of the device and the mainboard label is established and stored in the first data relationship, that is, the mainboard label of the same device is bound to the first category identification here, so that the mainboard label can be determined based on the first category identification later, and a binding relationship between the first device identification, the second device identification and the mainboard label is established and stored in the third data relationship. The storage here is equivalent to the backup storage of the first data relationship, and the binding relationship between the second category identification and the mainboard label is also additionally stored, so that in the subsequent activation code query process, when the binding relationship in the first data relationship is erroneous or lost, the mainboard label can be obtained through the backup third data relationship.

[0061] In the above solution, the second type of identification is introduced during the production stage of the device, and the binding relationship between the second type of identification and the motherboard label stored in the third data relationship is used as a backup query channel to ensure that when an abnormal situation occurs in the first data relationship, the activation code can still be accurately queried.

[0062] Based on the above embodiments, as an optional embodiment, the updating method of the second data relationship is as follows: Figure 5 The specific contents include: S401, when the equipment is in the quality inspection stage after the production stage, if it is determined that the equipment needs to be repaired, the equipment is treated as a device to be repaired; S402, in response to receiving a relationship release instruction for the device to be repaired, deleting the binding relationship between the first type identifier of the device to be repaired and the motherboard label in the first data relationship and the third data relationship; S403: Generate an unbinding record for the device to be repaired; the unbinding record includes a correspondence between the first category identifier of the device to be repaired and the motherboard label of the device to be repaired.

[0063] In S401 of the embodiment of the present application, after the equipment has gone through the production stage, it needs to undergo quality inspection, and can only enter the market for sale if it passes the quality inspection. If it is determined during the quality inspection that the equipment needs repair, the equipment will be treated as equipment to be repaired.

[0064] In S402 of the embodiment of the present application, before repairing the equipment to be repaired, it is necessary to unbind the first category identifier and the mainboard tag of the equipment to be repaired. Therefore, when a relationship release indication is received for the equipment to be repaired, the binding relationship between the first category identifier and the mainboard tag of the equipment to be repaired in the first data relationship and the third data relationship is deleted.

[0065] In S403 of the embodiment of the present application, an unbinding record of the device to be repaired is generated and stored in the second data relationship. The unbinding record includes the correspondence between the first type identification of the device to be repaired and the motherboard label of the device to be repaired.

[0066] In the above scheme, by recording the unbinding behavior of the first-class identification and the mainboard label when unbinding the first-class identification and the mainboard label of the equipment to be repaired, it can be ensured that when the first-class identification and the mainboard label are manually forgotten to be re-bound later, the mainboard label can still be accurately obtained based on the first-class identification.

[0067] Based on the above embodiments, as an optional embodiment, the activation code is determined as follows: Figure 6 As shown, the specific process is as follows: S501, preprocessing the target character string; S502, using a hash algorithm to determine a hash value of the preprocessed target character string; S503, extracting a value of a preset number of bits from the hash value as a target value; S504: Convert the target value into a target value in a target base, and extract a value of a preset number of digits from the target value in the target base as an activation code for the device to be queried.

[0068] In S501 of the embodiment of the present application, the target character string is preprocessed. The preprocessing may be removing spaces in the target character string and converting all characters in the target character string to uppercase or lowercase for unified processing.

[0069] In S502 of the embodiment of the present application, the hash algorithms that can be used include: MD5, SHA-1, and SHA-256. The target string is processed according to the selected hash algorithm to obtain a hash value of the target string.

[0070] In S503 of the embodiment of the present application, a preset number of bits of value is extracted from the hash value as the target value. The value of the preset number of bits can be extracted by starting from the highest bit of the hash value and continuously taking a preset number of values toward the lower bits as the target value, or by starting from the lowest bit of the hash value and continuously taking a preset number of values toward the higher bits as the target value, or by taking a preset number of values from a specific position of the hash value as the target value.

[0071] In S504 of the embodiment of the present application, the target system can be binary or decimal. After the target value is converted into the target system, a preset number of bits of value are extracted from the target value of the target system as the activation code of the device to be queried. It can be starting from the lowest bit of the target value of the target system and continuously taking a preset number of values toward the higher bits as the activation code of the device to be queried. It can also be starting from the highest bit of the target value of the target system and continuously taking a preset number of values toward the lower bits as the activation code of the device to be queried. It can also be taking a preset number of values from a specific position of the target value of the target system as the activation code of the device to be queried.

[0072] In one example, after preprocessing the target string, the target string obtained is "random123_supplier456_20240228_batch789". The SHA-256 algorithm is used to calculate the hash value of the target string to obtain the hash value "abcdef1234567890abcdef1234567890abcdef". The first six digits of the above hash value are extracted as the target value "abcdef". The above target value is converted into a decimal number "11259374". The last six digits of the above decimal number are taken as the activation code of the device to be queried, thereby obtaining the activation code "259374".

[0073] In this solution, activation codes are generated by combining device-related information (i.e., the target string) with a hash algorithm. This ensures that each activation code is unique to each device, making it difficult for malicious users to forge valid activation codes and increasing the difficulty of cracking them. Automatically generating device-specific activation codes reduces the need for manual issuance and management of activation codes. Furthermore, directly calculating the activation code through a hash algorithm reduces the complexity of additional data queries. The user only needs to enter the device information, and the hash algorithm generates an activation code that matches the device. This not only improves efficiency but also reduces the risk of human error.

[0074] Based on the above embodiments, as an optional embodiment, the unbinding record can also include multi-dimensional unbinding information such as unbinding time and unbinding reason, so as to facilitate subsequent tracking and analysis of the devices that have unbinding behavior, thereby further improving the various devices in the production stage.

[0075] Based on the above embodiments, as an optional embodiment, the target character string is obtained by concatenating at least one of the following: Random code; Supplier number; Date of production; Batch number.

[0076] In the embodiments of the present application, the random code is generated by a random number generator during the process of generating the activation code; the supplier number is used to represent the identity of the supplier of the device to be queried, the production date is used to represent the production time of the device to be queried, and the batch number is used to represent the production batch of the device to be queried.

[0077] The activation code query method provided by the embodiments of the present application can be applied to the production management scenario of smart home devices, and can also be applied to the scenario of device identity authentication in industrial manufacturing, and can also be applied to the after-sales support scenario of electronic devices.

[0078] Reference Figure 7 As shown, it exemplarily provides a flowchart of an activation code query method, and the specific content is as follows: S601, obtain the device identifier of the device to be queried; S602, determine whether the main board label bound to the device identifier can be obtained from the first data relationship. If so, execute S603; if not, execute S604; S603, use the obtained main board label as the target label, obtain the target string corresponding to the target label, preprocess the target string, and use the hash algorithm to determine the hash value of the preprocessed target string; extract the value of a preset number of digits from the hash value as the target value; convert the target value to the target value in the target base, and extract the value of a preset number of digits from the target value in the target base as the activation code of the device to be queried.

[0079] S604, determine whether the type of the device identifier includes the first type of identifier. If so, execute step S605; otherwise, execute step S606.

[0080] S605, determine whether the unbinding record corresponding to the first type of identifier can be obtained from the second data relationship. If so, execute step S607; if not, execute step S606.

[0081] S606, if the device identifier includes the second type of identifier, obtain the main board label bound to the second type of identifier from the third data relationship; S607, obtain the main board label that has been unbound from the first type of identifier from the unbinding record; S608, return the activation code.

[0082] The embodiments of the present application provide an activation code query device, as Figure 8 shown. The activation code query device 80 may include: a determination module 801, a processing module 802, and an acquisition module 803.

[0083] Specifically, the determination module 801 is used to determine the device identifier of the device to be queried, and the device identifier includes at least one of the first type of identifier and the second type of identifier; A processing module 802, configured to, if a motherboard label bound to a device identifier is not stored in a first data relationship, obtain, according to a second data relationship or a third data relationship, a motherboard label corresponding to the device identifier as a target label; An obtaining module 803, configured to obtain a target string corresponding to the target label, and determine an activation code of a device to be queried according to the target string; Wherein, the first data relationship is used to store a binding relationship between a first type of identifier and a motherboard label; the second data relationship is used to store a plurality of unbinding records, and each unbinding record is used to record a first type of identifier whose binding relationship has been released and the corresponding motherboard label; the third data relationship is used to store a plurality of binding information, and each binding information includes a binding relationship between a second type of identifier, a first type of identifier, and a motherboard label of a device.

[0084] The activation code query device provided in the embodiment of the present application determines a device identifier including at least one of a first type of identifier and a second type of identifier, and when it is determined that a motherboard label bound to the device identifier is not stored in the data relationship for storing the binding relationship between the first type of identifier and the motherboard label, obtains, according to the second data relationship or the third data relationship, a motherboard label corresponding to the device identifier as a target label, and obtains a string corresponding to the target label, so as to determine the activation code of the device to be queried according to the target string. Since the second data relationship stores a first type of identifier whose binding relationship has been released and the corresponding motherboard label, when an abnormal situation occurs that the binding relationship is forgotten to be restored due to human error after being temporarily released on the system, the motherboard label corresponding to the first type of identifier can still be obtained according to the unbinding record recorded in the second data relationship, so as to successfully obtain the corresponding activation code; Since the third data relationship stores the binding relationship between the first type of identifier, the second type of identifier, and the motherboard label, when the first type of identifier corresponding to the motherboard label is replaced and the binding relationship in the first data relationship is forgotten to be updated due to human error, the corresponding motherboard label can still be obtained from the third data relationship according to the second type of identifier, so as to obtain the activation code of the device to be queried, solving the problem that the activation code of the device to be queried cannot be obtained in the case of an abnormal binding relationship.

[0085] The device in the embodiment of the present application may execute the method provided in the embodiment of the present application, and its implementation principle is similar. The actions performed by each module in the device in each embodiment of the present application correspond to the steps in the method in each embodiment of the present application. For the detailed function descriptions of each module of the device, reference may specifically be made to the descriptions in the corresponding methods shown above, which will not be elaborated herein.

[0086] Further, in a possible implementation manner, the type of the device identifier is a first type of identifier; an unbinding record corresponding to the first type of identifier is obtained from the second data relationship; Get the first type of motherboard tag that indicates the unbinding from the unbinding record as the target tag.

[0087] In another possible implementation, the type of the device identifier is a second type identifier; The motherboard tag bound to the second type identifier is obtained from the third data relationship, and the bound motherboard tag is used as the target tag.

[0088] In another possible implementation, the type of device identifier is a first-class identifier and a second-class identifier; the unbinding record corresponding to the first-class identifier is obtained from the second data relationship, and the motherboard tag to which the first-class identifier has been unbound is obtained from the unbinding record as the target tag; or, the motherboard tag bound to the second-class identifier is obtained from the third data relationship, and the bound motherboard tag is used as the target tag.

[0089] In yet another possible implementation, when the device is in the production phase, an activation code is assigned to a motherboard tag of the device, and the activation code is burned into a motherboard chip of the device; Determine the first category identification and second category identification of the device, establish and store the binding relationship between the first category identification of the device and the motherboard label in the first data relationship, and establish and store the binding relationship between the first category identification, second category identification and motherboard label of the device to be queried in the third data relationship.

[0090] In yet another possible implementation, the method for updating the second data relationship includes: During the quality inspection phase after the equipment is produced, if it is determined that the equipment needs to be repaired, the equipment will be treated as equipment to be repaired; In response to receiving a relationship release instruction for the device to be repaired, deleting the binding relationship between the first type identifier of the device to be repaired and the motherboard label in the first data relationship and the third data relationship; Generate an unbinding record for the device to be repaired; the unbinding record includes a correspondence between the first category identifier of the device to be repaired and the motherboard label of the device to be repaired.

[0091] In yet another possible implementation, the target character string is preprocessed; Determine the hash value of the preprocessed target string using a hash algorithm; Extracting a value of a preset number of bits from the hash value as a target value; The target value is converted into a target value of a target base, and a value of a preset number of digits is extracted from the target value of the target base as the activation code of the device to be queried.

[0092] An embodiment of the present application provides an electronic device (computer device / equipment / system), including a memory, a processor, and a computer program stored on the memory. The processor executes the above computer program to implement the steps of the activation code query method. Compared with the related art, it can be achieved that: by determining a device identifier including at least one of a first type of identifier and a second type of identifier, and when it is determined that the motherboard label bound to the device identifier is not stored in the binding relationship for storing the binding relationship between the first type of identifier and the motherboard label, obtaining the motherboard label corresponding to the device identifier as the target label according to the second data relationship or the third data relationship, obtaining the string corresponding to the target label, and thus determining the activation code of the device to be queried according to the target string. Since the second data relationship stores the first type of identifier with the unbound relationship and the corresponding motherboard label, when an abnormal situation occurs where the binding relationship is temporarily released on the system and forgotten to be restored due to human error, the motherboard label corresponding to the first type of identifier can still be obtained according to the unbinding record recorded in the second data relationship, so as to successfully obtain the corresponding activation code; since the third data relationship stores the binding relationship between the first type of identifier, the second type of identifier, and the motherboard label, when the first type of identifier corresponding to the motherboard label is replaced and the binding relationship in the first data relationship is forgotten to be updated due to human error, the corresponding motherboard label can still be obtained from the third data relationship according to the second type of identifier, so as to obtain the activation code of the device to be queried, solving the problem that the activation code of the device to be queried cannot be obtained in the case of abnormal binding relationship.

[0093] In an alternative embodiment, an electronic device is provided, as Figure 9 shown. Figure 9 The electronic device 4000 shown includes: a processor 4001 and a memory 4003. Among them, the processor 4001 and the memory 4003 are connected, such as connected through a bus 4002. Optionally, the electronic device 4000 may further include a transceiver 4004, and the transceiver 4004 may be used for data interaction between the electronic device and other electronic devices, such as data sending and / or data receiving, etc. It should be noted that in practical applications, the transceiver 4004 is not limited to one, and the structure of the electronic device 4000 does not constitute a limitation to the embodiments of the present application.

[0094] The processor 4001 may be a CPU (Central Processing Unit), a general-purpose processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It can implement or execute various exemplary logical blocks, modules, and circuits described in connection with the disclosure of this application. The processor 4001 may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.

[0095] The bus 4002 may include a path for transmitting information between the above components. The bus 4002 may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus, etc. The bus 4002 may be divided into an address bus, a data bus, a control bus, etc. For the sake of representation, Figure 9 only a thick line is used to represent it here, but it does not mean that there is only one bus or one type of bus.

[0096] The memory 4003 may be a ROM (Read Only Memory) or other types of static storage devices that can store static information and instructions, a RAM (Random Access Memory) or other types of dynamic storage devices that can store information and instructions, or it may also be an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory), or other optical disc storage, optical disc storage (including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media, other magnetic storage devices, or any other medium that can be used to carry or store computer programs and can be read by a computer, which is not limited here.

[0097] The memory 4003 is used to store the computer program for implementing the embodiments of the present application, and is controlled by the processor 4001 for execution. The processor 4001 is used to execute the computer program stored in the memory 4003 to implement the steps shown in the foregoing method embodiments.

[0098] Among them, the electronic device package may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Tablet Computers), PMPs (Portable Multimedia Players), vehicle terminals (such as vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 9 The shown electronic device is merely an example and should not impose any limitations on the functions and usage scope of the embodiments of the present disclosure.

[0099] The embodiments of the present application provide a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps and corresponding contents shown in the foregoing method embodiments can be implemented. Compared with the prior art, it can be achieved that by determining a device identifier including at least one of a first type of identifier and a second type of identifier, and when it is determined that the motherboard label bound to the first type of identifier and the motherboard label is not stored in the binding relationship, obtaining the motherboard label corresponding to the device identifier as the target label according to the second data relationship or the third data relationship, obtaining the string corresponding to the target label, and thus determining the activation code of the device to be queried according to the target string. Since the second data relationship stores the first type of identifier and the corresponding motherboard label with the unbinding relationship, when an abnormal situation occurs that the binding relationship is forgotten to be restored due to human error after a temporary unbinding relationship on the system, the motherboard label corresponding to the first type of identifier can still be obtained according to the unbinding record recorded in the second data relationship, so as to successfully obtain the corresponding activation code; since the third data relationship stores the binding relationship between the first type of identifier, the second type of identifier and the motherboard label, when the first type of identifier corresponding to the motherboard label is replaced and the binding relationship in the first data relationship is forgotten to be updated due to human error, the corresponding motherboard label can still be obtained from the third data relationship according to the second type of identifier, so as to obtain the activation code of the device to be queried, solving the problem that the activation code of the device to be queried cannot be obtained in the case of abnormal binding relationship.

[0100] It should be noted that the above-mentioned computer-readable medium in the present disclosure can be a computer-readable signal medium, a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples of the computer-readable storage medium can include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium can be any tangible medium that contains or stores a program, and this program can be used by or in combination with an instruction execution system, apparatus, or device. And in the present disclosure, a computer-readable signal medium can include a data signal propagated in a baseband or as part of a carrier wave, in which computer-readable program code is carried. Such a propagated data signal can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, and this computer-readable signal medium can send, propagate, or transmit a program for use by or in combination with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted by any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0101] The embodiments of the present application further provide a computer program product, including a computer program, which when executed by a processor can implement the steps and corresponding contents of the foregoing method embodiments. Compared with the prior art, it can be realized that: by determining a device identifier including at least one of a first type of identifier and a second type of identifier, and when it is determined that the motherboard label bound to the device identifier is not stored in the binding relationship between the first type of identifier and the motherboard label, obtaining the motherboard label corresponding to the device identifier as the target label according to the second data relationship or the third data relationship, obtaining the string corresponding to the target label, and thus determining the activation code of the device to be queried according to the target string. Since the second data relationship stores the first type of identifier and the corresponding motherboard label with the unbinding relationship, when an abnormal situation occurs that the binding relationship is forgotten to be restored due to human error after a temporary unbinding on the system, the motherboard label corresponding to the first type of identifier can still be obtained according to the unbinding record in the second data relationship, so as to successfully obtain the corresponding activation code; since the third data relationship stores the binding relationship between the first type of identifier, the second type of identifier and the motherboard label, when the first type of identifier corresponding to the motherboard label is replaced and the binding relationship in the first data relationship is forgotten to be updated due to human error, the corresponding motherboard label can still be obtained from the third data relationship according to the second type of identifier, so as to obtain the activation code of the device to be queried, solving the problem that the activation code of the device to be queried cannot be obtained in case of abnormal binding relationship.

[0102] The terms "first", "second", "third", "fourth", "1", "2", etc. (if any) in the specification, claims and the above drawings of the present application are used to distinguish similar objects and do not necessarily need to be used to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of the present application described herein can be implemented in an order other than that shown or described in words.

[0103] It should be understood that although the flowchart in the embodiments of the present application indicates each operation step by an arrow, the execution order of these steps is not limited to the order indicated by the arrow. Unless there is a clear description in this article, in some implementation scenarios of the embodiments of the present application, the implementation steps in each flowchart can be executed in other orders according to requirements. In addition, some or all of the steps in each flowchart may include multiple sub-steps or multiple stages based on the actual implementation scenario. Some or all of these sub-steps or stages can be executed at the same time, and each sub-step or stage of these sub-steps or stages can also be executed at different times respectively. In the scenario where the execution times are different, the execution order of these sub-steps or stages can be flexibly configured according to requirements, and the embodiments of the present application do not limit this.

[0104] The above are only optional implementation manners of some implementation scenarios of this application. It should be noted that for those of ordinary skill in the art, without departing from the technical concept of the solution of this application, adopting other similar implementation means based on the technical idea of this application also belongs to the protection scope of the embodiments of this application.

Claims

1. A method for querying activation codes, characterized in that, Including: Determine the device identifier of the device to be queried, where the device identifier includes at least one of a first type of identifier and a second type of identifier; If the motherboard label bound to the device identifier is not stored in the first data relationship, obtain the motherboard label corresponding to the device identifier as the target label according to the second data relationship or the third data relationship; Obtain the target string corresponding to the target label, and determine the activation code of the device to be queried according to the target string; Wherein, the first data relationship is used to store the binding relationship between the first type of identifier and the motherboard label; The second data relationship is used to store multiple unbinding records, and each unbinding record is used to record the first type of identifier whose binding relationship has been released and the corresponding motherboard label; the third data relationship is used to store multiple binding information, and each binding information includes the binding relationship between the second type of identifier, the first type of identifier and the motherboard label of the device.

2. The method according to claim 1, wherein The type of the device identifier is the first type of identifier; According to the type of the device identifier, obtaining the target label corresponding to the device identifier from the corresponding data relationship includes: Obtain the unbinding record corresponding to the first type of identifier from the second data relationship; Obtain the motherboard label unbound by the first type of identifier from the unbinding record as the target label.

3. The method according to claim 1, wherein The type of the device identifier is the second type of identifier; According to the type of the device identifier, obtaining the target label corresponding to the device identifier from the corresponding data relationship includes: Obtain the motherboard label bound by the second type of identifier from the third data relationship, and use the bound motherboard label as the target label.

4. The method according to claim 1, wherein The type of the device identifier is the first type of identifier and the second type of identifier; According to the type of the device identifier, obtaining the target label corresponding to the device identifier from the corresponding data relationship includes: Obtain the unbinding record corresponding to the first type of identifier from the second data relationship, and obtain the motherboard label unbound by the first type of identifier from the unbinding record as the target label; Alternatively, obtain the motherboard label bound by the second type of identifier from the third data relationship, and use the bound motherboard label as the target label.

5. The method according to any one of claims 1-4, characterized in that, The method further includes: When the device is in the generation stage, assign an activation code to the motherboard label of the device, and burn the activation code into the motherboard chip of the device; Determine the first type of identifier and the second type of identifier of the device, establish and store the binding relationship between the first type of identifier of the device and the motherboard label in the first data relationship, and establish and store the binding relationship between the first type of identifier, the second type of identifier and the motherboard label of the device to be queried in the third data relationship.

6. The method according to claim 5, wherein The update method of the second data relationship includes: When the device is in the quality inspection stage after the generation stage, if it is determined that the device needs to be repaired, use the device as a device to be repaired; In response to receiving a relationship release instruction for the device to be repaired, delete the binding relationship between the first type of identifier and the motherboard label of the device to be repaired in the first data relationship and the third data relationship; Generate an unbinding record of the device to be repaired; the unbinding record includes a correspondence between the first category identifier of the device to be repaired and the mainboard label of the device to be repaired.

7. The method according to claim 1, characterized in that, Determining the activation code of the device to be queried according to the target character string includes: Preprocessing the target character string; Determine the hash value of the preprocessed target string using a hash algorithm; Extracting a value of a preset number of bits from the hash value as a target value; The target value is converted into a target value of a target base, and a value of a preset number of digits is extracted from the target value of the target base as the activation code of the device to be queried.

8. An activation code query device, characterized in that, include: A determination module, configured to determine a device identification of a device to be queried, wherein the device identification includes at least one of a first type identification and a second type identification; a processing module configured to obtain the motherboard tag corresponding to the device identifier as a target tag according to the second data relationship or the third data relationship if the motherboard tag bound to the device identifier is not stored in the first data relationship; An acquisition module, configured to acquire a target character string corresponding to the target tag, and determine an activation code of the device to be queried according to the target character string; Wherein, the first data relationship is used to store the binding relationship between the first type of identification and the motherboard label; The second data relationship is used to store multiple unbinding records, each unbinding record is used to record the first type identifier and the corresponding motherboard tag of the unbinding relationship; the third data relationship is used to store multiple binding information, each binding information includes the binding relationship between the second type identifier, the first type identifier and the motherboard tag of the device.

9. An electronic device, comprising a memory, a processor, and a computer program stored on the memory, characterized in that The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 7.

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