Lock plate address allocation method and device, equipment and medium

By clearing dial information, sending broadcasts and stopping response instructions, verifying the lock plate information format, and detecting the number of lock plates, the problems of low efficiency and low accuracy of lock plate address allocation in the prior art are solved, and efficient and accurate address allocation is achieved.

CN120512422APending Publication Date: 2025-08-19SHENZHEN HIVE BOX NETWORK TECH LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510764889.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-09
Publication Date
2025-08-19

AI Technical Summary

Technical Problem

The existing express cabinet lock plate dialing scheme has low address allocation efficiency and low accuracy when the number of cabinet machines is large.

Method used

After receiving the address allocation command, clear the dialing information of all lock plates, send broadcast information, wait for the target lock plate to respond and verify the information format, send a stop response command, and detect the number of lock plates until all lock plate addresses are allocated.

Benefits of technology

Improve the accuracy and efficiency of lock plate address allocation, avoid invalid information allocation and communication competition, and ensure that all lock plate addresses are allocated.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120512422A_ABST
    Figure CN120512422A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of address allocation, and discloses a lock plate address allocation method, device and equipment and a medium, and the method comprises the steps: clearing dial information of all lock plates after an address allocation instruction is received, and sending broadcast information to all lock plates; after the random waiting time, receiving lock plate information returned by the target lock plate, and checking whether the format of the lock plate information is correct or not; when the format of the lock plate information is correct, a stop response instruction is sent to all lock plates, and after stop response information returned by all the lock plates is received, a lock plate address corresponding to the target lock plate is set; and detecting whether the number of the lock plates with the set lock plate addresses reaches a preset number, adding one to the number of the lock plates when the number of the lock plates does not reach the preset number, and allocating addresses to the next lock plate until the addresses of all the lock plates are allocated. According to the invention, through automatic address allocation, the allocation of lock plate addresses is realized, and the efficiency and accuracy of address allocation are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of address allocation, and in particular to a lock plate address allocation method, device, equipment and medium. Background Art

[0002] Existing locker lock plate dialing solutions use binary physical dials, meaning addresses are set using binary combinations. In scenarios where there are a large number of lockers, using binary dial combinations requires dialing all lockers one by one, resulting in inefficient and inaccurate address allocation. Summary of the Invention

[0003] The embodiments of the present invention provide a lock plate address allocation method, apparatus, device and medium to improve the problem of low efficiency and low accuracy of address allocation caused by physical dialing in the prior art.

[0004] A lock board address allocation method, applied to a server, comprising: After receiving the address allocation instruction, clear the dial code information of all lock plates and send a broadcast message to all the lock plates; After a random waiting time, receiving the lock plate information returned by the target lock plate, and verifying whether the format of the lock plate information is correct; When the format of the lock plate information is correct, sending a stop response instruction to all the lock plates, and after receiving the stop response information returned by all the lock plates, setting the lock plate address corresponding to the target lock plate; Detect whether the number of lock plates with set lock plate addresses reaches a preset number. If the number of lock plates does not reach the preset number, increase the number of lock plates by one and assign an address to the next lock plate until the address assignment of all lock plates is completed.

[0005] A lock plate address allocation method, applied to a cabinet, includes: Receive broadcast information and check whether all lock boards have been assigned lock board addresses; When the lock board has not been assigned a lock board address, a random waiting time is generated, and after the random waiting time has elapsed, lock board information is returned; After receiving the stop response instruction, it stops responding to the broadcast information and returns the stop response information.

[0006] A lock plate address allocation device, applied to a server, comprising: An information clearing module is used to clear the dial code information of all lock plates and send broadcast information to all the lock plates after receiving the address allocation instruction; A format verification module is used to receive the lock plate information returned by the target lock plate after a random waiting time, and verify whether the format of the lock plate information is correct; An address allocation module is configured to send a stop response instruction to all the lock boards when the format of the lock board information is correct, and set a lock board address corresponding to the target lock board after receiving stop response information returned by all the lock boards; The cyclic allocation module is used to detect whether the number of lock plates with set lock plate addresses has reached a preset number. When the number of lock plates has not reached the preset number, the number of lock plates is increased by one, and an address is allocated to the next lock plate until the address allocation of all lock plates is completed.

[0007] A lock plate address distribution device, applied to a cabinet end, comprising: The lock board address detection module is used to receive broadcast information and detect whether all lock boards have been assigned lock board addresses; An information time generating module, configured to generate a random waiting time when the lock board has not been assigned a lock board address, and return the lock board information after the random waiting time has elapsed; The stop response instruction module is used to stop responding to the broadcast information and return the stop response information after receiving the stop response instruction.

[0008] A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor is configured to execute the lock board address allocation method.

[0009] A computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the lock board address allocation method is implemented.

[0010] The lock plate address allocation method, apparatus, device, and medium described above, and the lock plate address allocation method of the present invention, by receiving an address allocation instruction, achieves the clearing of the lock plate dial code information, thereby achieving the sending of the broadcast information, and then achieving the start of the address allocation operation. By verifying the format of the lock plate information of the target lock plate returned in response to the broadcast information, it is ensured that the lock plate information is valid information, thereby avoiding the allocation of addresses to invalid lock plate information, thereby improving the accuracy of address allocation. By sending a stop response instruction to all lock plates, the stop response information is received, avoiding communication competition among all lock plates, further improving the accuracy of address allocation, and thus achieving the allocation of lock plate addresses. By detecting whether the number of lock plates has reached a preset number, the lock plates that have been assigned addresses are detected, thereby ensuring that addresses are assigned to all lock plates, thereby improving the efficiency of address allocation. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments of the present invention. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0012] Figure 1 is a flow chart of a method for allocating lock board addresses in one embodiment of the present invention; Figure 2 is a flowchart of step S10 of the lock board address allocation method in one embodiment of the present invention; Figure 3 is a flow chart of step S20 of the lock board address allocation method in one embodiment of the present invention; Figure 4 is a flow chart of step S30 of the lock board address allocation method in one embodiment of the present invention; Figure 5 is a flowchart of step S30 of the lock board address allocation method in another embodiment of the present invention; Figure 6 is a flow chart of a lock board address allocation method according to another embodiment of the present invention; Figure 7 This is a principle block diagram of a lock plate address allocation device in another embodiment of the present invention; Figure 8 This is a principle block diagram of a lock board address allocation device in one embodiment of the present invention. DETAILED DESCRIPTION

[0013] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.

[0014] In one embodiment, if Figure 1 As shown, a lock board address allocation method is provided, which is applied to the server and includes the following steps: S10: After receiving the address allocation instruction, clear the dial code information of all the lock plates and send broadcast information to all the lock plates.

[0015] Understandably, an address assignment instruction refers to an address assignment command triggered by clicking a button or virtual button. DIP information refers to the relevant address information generated by the DIP switch setting. A DIP switch is a manually controlled switch, typically consisting of multiple independent switches, each of which can be in the "ON" (connected) or "OFF" (disconnected) state. Different switch state combinations represent different coded information, thereby realizing the address assignment function for the device. The lock board refers to the electronic control circuit board used to control the opening and locking status of the cabinet door. Broadcast information refers to various data information sent by the main control system in broadcast form.

[0016] Specifically, after clicking the Auto-Address Assignment button and triggering the address assignment command, the system checks whether a lock panel address has already been assigned. If no lock panel address has been assigned, the system clears the dial code information for all lock panels. Next, the system sends a broadcast message to all lock panels. Specifically, the system sends the broadcast message to all lock panels using a pre-set communication method with varying delays. For example, the broadcast message can be transmitted to all lock panels via a bus mode.

[0017] S20: After a random waiting time, receiving the lock board information returned by the target lock board, and verifying whether the format of the lock board information is correct.

[0018] Understandably, the random wait time refers to a wait time randomly generated by the lock panel, such as 220 milliseconds, 550 milliseconds, or 1 second. The target lock panel refers to the lock panel that returns lock panel information, and in this embodiment, it refers to the first lock panel to return information. The lock panel information refers to information such as the geographic address and chip ID of the cabinet lock panel.

[0019] Specifically, after a random waiting time has elapsed, the lock plate information returned by the target lock plate is received. Specifically, after receiving the signal, if the lock plate detects that it has not been assigned an address, it generates a random waiting time, and only returns the lock plate information of the lock plate after the random waiting time has elapsed. The correct format of the lock plate information is then verified, specifically by obtaining a preset standard format and validating the lock plate information using the preset standard format, or alternatively, validating the lock plate information using a regular expression. If all of the lock plate information conforms to the preset standard format, the format of the lock plate information is determined to be correct. If at least one of the lock plate information does not conform to the preset standard format, the format of the lock plate information is determined to be incorrect.

[0020] S30: When the format of the lock board information is correct, sending a stop response instruction to all the lock boards, and after receiving stop response information returned by all the lock boards, setting a lock board address corresponding to the target lock board.

[0021] Understandably, the stop response command means stopping the current broadcast information feedback. The stop response information is the information returned by the lock board in response to the stop response command, used to indicate that the lock board has stopped responding to the broadcast information. The lock board address is a code or identifier used to uniquely identify the lock board.

[0022] Specifically, if the lock panel information is formatted correctly, a stop response command is triggered and sent to all lock panels except the target lock panel. Then, upon receiving stop response information from all lock panels except the target lock panel, all lock panels cease responding to the broadcast information. Next, the address information of the target lock panel is set, and the set lock panel address is saved and recorded.

[0023] S40: Detect whether the number of lock plates with set lock plate addresses reaches a preset number. If the number of lock plates does not reach the preset number, increase the number of lock plates by one and assign an address to the next lock plate until the address assignment of all lock plates is completed.

[0024] It is understood that the number of lock plates refers to the total number of lock plates for which lock plate addresses have been set. The preset number refers to the total number of all lock plates, which can be input when triggering address allocation.

[0025] Specifically, the number of target lock plates with set lock plate addresses is counted, and a check is performed to determine whether the number of lock plates with set lock plate addresses reaches a preset number. When the number of lock plates reaches the preset number, a determination is made to allocate addresses to all lock plates, and address allocation ends. If the number of lock plates does not reach the preset number, the number of lock plates is incremented by one, i.e., the number of target lock plates is incremented by one, and the next round of address allocation begins, i.e., allocating addresses to all lock plates using the aforementioned address allocation method, until address allocation for all lock plates is completed.

[0026] In the lock plate address allocation method of the present invention, by receiving an address allocation instruction, the lock plate dial code information is cleared, thereby enabling the transmission of a broadcast message and, in turn, initiating the address allocation operation. By verifying the format of the lock plate information of the target lock plate returned in response to the broadcast message, the lock plate information is ensured to be valid, thereby avoiding the allocation of addresses to invalid lock plate information and improving the accuracy of address allocation. By sending a stop response instruction to all lock plates, the stop response information is received, thereby avoiding communication competition among all lock plates, further improving the accuracy of address allocation and achieving the allocation of lock plate addresses. By detecting whether the number of lock plates has reached a preset number, the lock plates to which addresses have been allocated are detected, thereby ensuring that addresses are allocated to all lock plates and improving the efficiency of address allocation.

[0027] In one embodiment, if Figure 2 As shown, after step S10, after sending the broadcast information to all the lock plates, the method further includes: S101, determining a reply waiting time, and detecting whether the reply waiting time exceeds a preset reply time threshold.

[0028] S102: When it is detected that the reply waiting time exceeds a preset reply time threshold, it is determined whether the number of times the broadcast information is sent exceeds a preset repetition threshold.

[0029] S103: When the number of broadcast transmissions exceeds a preset repetition threshold, stop sending the broadcast information to all the lock plates.

[0030] The reply wait time refers to the duration between the time the broadcast message was sent and the current time. The preset reply time threshold refers to the preset reply wait time, for example, 2 seconds, 3 seconds, etc. The preset repetition threshold refers to the preset threshold for the number of times the broadcast message is sent, for example, 3 times, 5 times, etc. The broadcast transmission count refers to the number of times the broadcast message is sent to all lock panels. This count is only counted when the timer expires and is not counted when round-robin address allocation occurs.

[0031] Specifically, after sending the broadcast message to all the lock plates, the time the broadcast message was sent is counted, i.e., the moment the broadcast message was sent is determined as the start time. The duration of the broadcast message is counted, and the duration of the broadcast message is determined as the reply waiting time. Then, a preset reply time threshold is obtained, and a check is performed to determine whether the reply waiting time exceeds the preset reply time threshold. i.e., the reply waiting time is compared with the preset reply time threshold. If it is determined that the reply waiting time does not exceed the preset reply time threshold, the system continues to wait until a returned lock plate message is received, or until it is determined that the reply waiting time exceeds the preset reply time threshold. If it is determined that the reply waiting time exceeds the preset reply time threshold, a preset repetition threshold is obtained, the number of broadcast transmissions is counted, and the number of broadcast transmissions is compared with the preset repetition threshold to determine whether the number of broadcast transmissions exceeds the preset repetition threshold. If the number of broadcast transmissions exceeds the preset repetition threshold, the broadcast message is terminated from being sent to all lock plates. If the number of broadcast transmissions does not exceed the preset repetition threshold, the broadcast message is resent to all lock plates.

[0032] In this embodiment, by presetting a reply time threshold and a reply wait time, the reply wait time is detected, thereby reducing the time spent waiting for a reply. By counting the number of broadcast transmissions and presetting a repetition threshold, the number of broadcast transmissions is counted, thereby limiting the number of broadcast transmissions, thereby avoiding long waits for replies and improving address allocation efficiency.

[0033] In one embodiment, if Figure 3 As shown, after step S20, after verifying whether the format of the lock plate information is correct, the method further includes: S201 : When the format of the lock plate information is incorrect, receiving new lock plate information returned by a new target lock plate, and verifying whether the format of the new lock plate information is correct.

[0034] S202: When the format of the new lock plate information is incorrect, continue to receive and verify the format of the lock plate information until it is correct, or end the process until all lock plates return the lock plate information.

[0035] Understandably, the new target lock board refers to the lock board that returns information second and thereafter. The new lock board information refers to the address and chip identification information returned by the new target lock board.

[0036] Specifically, after verifying the correct format of the lock plate information, if the format of the lock plate information is incorrect, the system continues to receive new lock plate information returned by the new target lock plate (i.e., the next target lock plate). The system then verifies the format of the new lock plate information using a preset standard format to verify the correct format of the new lock plate information. If the format of the new lock plate information is correct, a stop response command is sent to all lock plates except the target lock plate. If the new lock plate information is incorrect, the system continues to receive and verify the format of the next lock plate information until the correct format is obtained, or until all lock plates have received lock plate information, the current address allocation process ends.

[0037] In this embodiment, when the format of the lock board information is incorrect, the new target lock board is determined, thereby receiving and verifying the new lock board information, ensuring that the new lock board information is valid, and thus improving the accuracy of address allocation.

[0038] In one embodiment, if Figure 4 As shown, after step S30, after sending the stop response instruction to all the lock plates, the method further includes: S301, determining a response waiting time, and detecting whether the response waiting time exceeds a preset response time threshold.

[0039] S302: When it is detected that the response waiting time exceeds the preset response time threshold, resend a stop response instruction to all the lock plates.

[0040] It is understandable that the response waiting time refers to the time between the time point after the stop response instruction is issued and the current time point. The preset response time threshold refers to the preset waiting time for the instruction response.

[0041] Specifically, after sending the stop response instruction to all the lock panels, the duration of the stop response instruction is counted, i.e., the moment the stop response instruction is sent is determined as the start time, the issuance duration is counted, and the issuance duration is determined as the response waiting time. Then, a preset response time threshold is obtained, and a check is performed to determine whether the response waiting time exceeds the preset response time threshold. i.e., the response waiting time is compared with the preset response time threshold. If it is detected that the response waiting time does not exceed the preset response time threshold, the system continues to wait until a stop response message is received from all lock panels other than the target lock panel, or until it is detected that the response waiting time exceeds the preset response time threshold. Then, if it is detected that the response waiting time exceeds the preset response time threshold, the stop response instruction is resent to all lock panels to ensure that all lock panels stop responding to the broadcast message.

[0042] In this embodiment, by presetting the response time threshold and the response waiting time, the response waiting time is detected, thereby avoiding communication competition among all lock boards and reducing the time for waiting for response, thereby improving the address allocation efficiency.

[0043] In one embodiment, if Figure 5 As shown, after step S30, after setting the lock board address corresponding to the target lock board, the method further includes: S303: Detect whether the lock board address is set successfully, and if the lock board address setting fails, detect whether the address setting times exceeds a preset times threshold.

[0044] S304: When it is detected that the number of address settings does not exceed the preset number threshold, reset the lock board address of the target lock board.

[0045] S305: When it is detected that the number of address settings exceeds a preset threshold, the address allocation of the target lock board is terminated.

[0046] It is understandable that the number of address settings refers to the number of times the address of the lock plate is set. The preset number threshold refers to a preset threshold of the number of times the address of the lock plate is set.

[0047] Specifically, after setting the lock plate address corresponding to the target lock plate, the returned address setting information is received, and the address setting information is tested to determine whether the lock plate address is set successfully. When the lock plate address is set successfully, the lock plate address and lock plate information of the target lock plate are cached. When the lock plate address setting fails, the number of address settings for the target lock plate is counted, and a preset number threshold is obtained to detect whether the number of address settings exceeds the preset number threshold. When it is detected that the number of address settings does not exceed the preset number threshold, the lock plate address of the target lock plate is reset, and the lock plate address is tested again to determine whether the lock plate address is set successfully, until the lock plate address is set successfully, or exceeds the preset number threshold. When it is detected that the number of address settings exceeds the preset number threshold, the address allocation of the target lock plate is ended.

[0048] In this embodiment, by detecting whether the lock board address is set successfully, the successful setting of the lock board address is ensured. By setting the address number and the preset number threshold, the number of address allocations is limited, the time for address allocation is reduced, and the efficiency of address allocation is improved.

[0049] In one embodiment, if Figure 6 As shown, a lock plate address allocation method is provided, which is applied to the cabinet end and includes the following steps: S50: Receive broadcast information and detect whether all lock boards have been assigned lock board addresses.

[0050] Specifically, each cabinet's lock plate receives the broadcast information. Different lock plates receive the broadcast information at different times, meaning each lock plate receives the broadcast information with varying delays. Then, an address check is performed on all lock plates to see if they have been assigned an address. Specifically, the lock plate checks whether the current lock plate has an assigned address. If a lock plate has already been assigned an address, it does not respond to the broadcast information.

[0051] S60: When the lock board has not been assigned a lock board address, a random waiting time is generated, and after the random waiting time has elapsed, lock board information is returned.

[0052] Specifically, when the lock plate is not assigned a lock plate address, a random waiting time is generated. That is, when the lock plate is not assigned an address, the lock plate generates a random waiting time to avoid communication competition between all lock plates. For example, if 5 lock plates are not assigned an address, a random waiting time is generated for each, such as 60 milliseconds, 80 milliseconds, 95 milliseconds, 125 milliseconds, and 132 milliseconds. Then, after the random waiting time, the lock plate address and the lock plate chip identifier are organized into lock plate information in response to the broadcast information, and the lock plate information is returned. Among them, if the lock plate is sent via an industrial computer, the lock plate information is also returned through the industrial computer when it is returned. If the lock plate is sent directly, the lock plate information is also returned directly when it is returned.

[0053] S70: After receiving the stop response instruction, stop responding to the broadcast information and return stop response information.

[0054] Specifically, after verifying that the format of the lock information of the target lock board that returns the information the fastest is correct, a stop response instruction is triggered. Then, the stop response instruction is sent to all lock boards except the target lock board. After receiving the stop response instruction, all lock boards stop returning lock information and return a stop response message.

[0055] In another embodiment, after receiving the stop response instruction, it is determined whether the assigned address is the first node address. If the assigned address is not the first node address, the lock board is caused to exit the random waiting time and not respond to the broadcast information. If the assigned address is the first node address, the lock board stops returning the lock board information and returns a stop response message.

[0056] In this embodiment, by receiving broadcast information, it is possible to detect whether an address has been assigned, thereby generating a random waiting time and returning information about the lock board, thereby achieving address assignment for the lock board. By receiving a stop response instruction, it is possible to stop responding to broadcast information, avoiding communication contention between lock boards and improving address allocation efficiency.

[0057] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.

[0058] In one embodiment, a lock plate address allocation device is provided, which is applied to a cabinet end. The lock plate address allocation device corresponds to the lock plate address allocation method in the above embodiment. Figure 7 As shown, the lock plate address allocation device includes a lock plate address detection module, an information time generation module and a stop response instruction module. The detailed description of each functional module is as follows: The lock board address detection module is used to receive broadcast information and detect whether all lock boards have been assigned lock board addresses; An information time generating module, configured to generate a random waiting time when the lock board has not been assigned a lock board address, and return the lock board information after the random waiting time has elapsed; The stop response instruction module is used to stop responding to the broadcast information and return the stop response information after receiving the stop response instruction.

[0059] In one embodiment, a lock plate address allocation device is provided, which is applied to the server. The lock plate address allocation device corresponds to the lock plate address allocation method in the above embodiment. Figure 8As shown, the lock plate address allocation device includes an information clearing module 10, a format checking module 20, an address allocation module 30 and a cyclic allocation module 40. The functional modules are described in detail as follows: The information clearing module 10 is used to clear the dial code information of all lock plates after receiving the address allocation instruction, and send a broadcast message to all the lock plates; The format verification module 20 is used to receive the lock plate information returned by the target lock plate after a random waiting time, and verify whether the format of the lock plate information is correct; The address allocation module 30 is configured to send a stop response instruction to all the lock boards when the format of the lock board information is correct, and set a lock board address corresponding to the target lock board after receiving stop response information returned by all the lock boards; The cyclic allocation module 40 is used to detect whether the number of lock plates with set lock plate addresses reaches a preset number. When the number of lock plates does not reach the preset number, the number of lock plates is increased by one and an address is allocated to the next lock plate until the address allocation of all lock plates is completed.

[0060] Optionally, the detection model includes a classification detection model, a brand detection model and a defect detection model; The device further comprises: An address setting times unit is used to detect whether the lock plate address is set successfully, and if the lock plate address setting fails, detect whether the address setting times exceeds a preset times threshold; A lock plate address setting unit, configured to reset the lock plate address of the target lock plate when detecting that the number of address settings does not exceed a preset number threshold; The address allocation ending unit is configured to end the address allocation of the target lock plate when detecting that the number of address settings exceeds a preset number threshold.

[0061] Optionally, the device further includes: A new lock plate information verification unit is configured to receive the new lock plate information returned by the new target lock plate when the format of the lock plate information is incorrect, and verify whether the format of the new lock plate information is correct; The information correct ending unit is used to continue receiving and verifying the format of the lock plate information until it is correct when the format of the new lock plate information is incorrect, or until all lock plates return the lock plate information and then end.

[0062] Optionally, the device further includes: A response waiting time unit is used to determine the response waiting time and detect whether the response waiting time exceeds a preset response time threshold; The stop response instruction unit is configured to resend a stop response instruction to all the lock plates when detecting that the response waiting time exceeds the preset response time threshold.

[0063] Optionally, the device further includes: A reply waiting time unit, configured to determine a reply waiting time and detect whether the reply waiting time exceeds a preset reply time threshold; a broadcast sending times unit, configured to determine whether the broadcast sending times of sending the broadcast information exceeds a preset repetition threshold when detecting that the reply waiting time exceeds a preset reply time threshold; The broadcast information ending unit is configured to end sending the broadcast information to all the lock plates when the number of broadcast transmissions exceeds a preset repetition threshold.

[0064] A computer device includes a memory, a processor, and a computer program stored in the memory and runnable on the processor, wherein the processor is configured to execute the lock board address allocation method.

[0065] For specific definitions of the computer device, processor, and its various units and modules, please refer to the definitions of the lock board address allocation method above and will not be repeated here. The various modules in the above-mentioned processor may be implemented in whole or in part through software, hardware, or a combination thereof. It is understood that the processor includes a processor, memory, a network interface, and a database connected via a device bus. The modules of the processor may be embedded in or independent of the processor in hardware form, or stored in the memory in software form, so that the processor can call and execute the corresponding operations of each of the above modules. The processor is used to provide computing and control capabilities. The memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating device, a computer program, and a database. The internal memory provides an environment for the operation of the operating device and computer program in the non-volatile storage medium. The database is used to store data used in the lock board address allocation method described in the above embodiment. The network interface is used to communicate with an external terminal via a network connection. When executed by the processor, the computer program implements a lock board address allocation method.

[0066] In one embodiment, a computer-readable storage medium is provided. The computer-readable storage medium stores a computer program. When the computer program is executed by a processor, the computer program implements the above-mentioned lock board address allocation method.

[0067] Those skilled in the art will understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0068] Those skilled in the art will clearly understand that for the sake of convenience and brevity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0069] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention, and should all be included in the scope of protection of the present invention.

Claims

1. A lock board address allocation method, applied to a server, characterized in that: include: After receiving the address allocation instruction, clear the dial code information of all lock plates and send a broadcast message to all the lock plates; After a random waiting time, receiving the lock plate information returned by the target lock plate, and verifying whether the format of the lock plate information is correct; When the format of the lock plate information is correct, sending a stop response instruction to all the lock plates, and after receiving the stop response information returned by all the lock plates, setting the lock plate address corresponding to the target lock plate; Detect whether the number of lock plates with set lock plate addresses reaches a preset number. If the number of lock plates does not reach the preset number, increase the number of lock plates by one and assign an address to the next lock plate until the address assignment of all lock plates is completed.

2. The lock board address allocation method according to claim 1, wherein: After setting the lock board address corresponding to the target lock board, the method further includes: Detecting whether the lock plate address is set successfully, and if the lock plate address setting fails, detecting whether the address setting times exceeds a preset times threshold; When it is detected that the number of address settings does not exceed the preset number threshold, resetting the lock plate address of the target lock plate; When it is detected that the number of address settings exceeds a preset number threshold, the address allocation of the target lock board is terminated.

3. The lock board address allocation method according to claim 1, wherein: After verifying whether the format of the lock plate information is correct, the method further includes: When the format of the lock plate information is incorrect, receiving new lock plate information returned by the new target lock plate, and verifying whether the format of the new lock plate information is correct; When the format of the new locking plate information is incorrect, the process continues to receive and verify the format of the locking plate information until it is correct, or ends when all locking plates return the locking plate information.

4. The lock board address allocation method according to claim 1, wherein: After sending the stop response instruction to all the lock plates, the method further includes: Determine the response waiting time and detect whether the response waiting time exceeds a preset response time threshold; When it is detected that the response waiting time exceeds the preset response time threshold, a stop response instruction is resent to all the lock plates.

5. The lock board address allocation method according to claim 1, wherein: After sending the broadcast information to all the lock plates, the method further includes: Determining a response waiting time, and detecting whether the response waiting time exceeds a preset response time threshold; When it is detected that the reply waiting time exceeds a preset reply time threshold, determining whether the number of broadcast transmissions of the broadcast information exceeds a preset repetition threshold; When the number of broadcast transmissions exceeds a preset repetition threshold, the sending of the broadcast information to all the lock plates is stopped.

6. A lock plate address allocation method, applied to a cabinet end, characterized in that: include: Receive broadcast information and check whether all lock boards have been assigned lock board addresses; When the lock board has not been assigned a lock board address, a random waiting time is generated, and after the random waiting time has elapsed, lock board information is returned; After receiving the stop response instruction, it stops responding to the broadcast information and returns the stop response information.

7. A lock plate address allocation device, applied to a server, characterized in that: include: An information clearing module is used to clear the dial code information of all lock plates and send broadcast information to all the lock plates after receiving the address allocation instruction; A format verification module is used to receive the lock plate information returned by the target lock plate after a random waiting time, and verify whether the format of the lock plate information is correct; An address allocation module is configured to send a stop response instruction to all the lock boards when the format of the lock board information is correct, and set a lock board address corresponding to the target lock board after receiving stop response information returned by all the lock boards; The cyclic allocation module is used to detect whether the number of lock plates with set lock plate addresses has reached a preset number. When the number of lock plates has not reached the preset number, the number of lock plates is increased by one, and an address is allocated to the next lock plate until the address allocation of all lock plates is completed.

8. A lock plate address distribution device, applied to a cabinet end, characterized in that: include: The lock board address detection module is used to receive broadcast information and detect whether all lock boards have been assigned lock board addresses; An information time generating module, configured to generate a random waiting time when the lock board has not been assigned a lock board address, and return the lock board information after the random waiting time has elapsed; The stop response instruction module is used to stop responding to the broadcast information and return the stop response information after receiving the stop response instruction.

9. A computer device, characterized in that: The invention comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor is configured to execute the lock board address allocation method according to any one of claims 1 to 6.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the lock board address allocation method according to any one of claims 1 to 6 is implemented.