Method and device for configuring Bluetooth Mesh network through Bluetooth broadcast

Configure Bluetooth Mesh network through Bluetooth broadcasting, use message labels and address information to match devices, dynamically adjust the propagation range, solving the problems of low efficiency and insufficient flexibility of distribution networks in the existing technology, and achieving efficient device access and resource optimization.

CN120547531AActive Publication Date: 2025-08-26SHENZHEN HEYI INTELLIGENT CONTROL CO LTD

Patent Information

Application Number
CN202510895160.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-30
Publication Date
2025-08-26
Estimated Expiration
2045-06-30

AI Technical Summary

Technical Problem

The existing Bluetooth Mesh network distribution method is inefficient, has high labor costs, and lacks flexibility in large-scale network layout or long-distance scenarios, so it cannot adapt to the equipment access needs in dynamic scenarios.

Method used

Configure the Bluetooth Mesh network through Bluetooth broadcasting, and use the message label and address information in the Bluetooth distribution network broadcasting information to match the device to achieve accurate access; when the matching fails, dynamically adjust the message forwarding mark to control the broadcast information propagation range to ensure that the information finds the target device within a limited distance.

Benefits of technology

Improve distribution network efficiency, reduce resource redundancy, and realize large-scale rapid distribution network without manual connection and factory preset configuration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120547531A_ABST
    Figure CN120547531A_ABST
Patent Text Reader

Abstract

The invention relates to a method and device for configuring a Bluetooth Mesh network through Bluetooth broadcast. The method comprises the following steps: receiving Bluetooth distribution network broadcast information; according to a first matching result of the message label and the cache information, determining a processing state of the Bluetooth network distribution broadcast information by the equipment to be subjected to network distribution; if the first matching result shows that the broadcast information is not processed, determining a matching relationship between the to-be-distributed network equipment and the target to-be-distributed network equipment according to a second matching result of the target address information and the address information of the to-be-distributed network equipment; if the second matching result shows that the two are matched, accessing the to-be-distributed network equipment to the network based on the broadcast information; and if the second matching result shows that the two devices are not matched, updating the message forwarding mark to obtain the updated broadcast message and forwarding the updated broadcast message to the next device until the target device to be subjected to network configuration is obtained through matching within the dynamic message distance determined based on the message forwarding mark and is accessed to the network. By adopting the method, the network distribution efficiency can be improved, and the resource redundancy in the network distribution process can be reduced.
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, and in particular to a method and apparatus for configuring a Bluetooth Mesh network via Bluetooth broadcasting. Background Art

[0002] In the field of Internet of Things technology, it involves setting network parameters for devices to be connected, so as to achieve automatic access and communication of devices in the Bluetooth Mesh network.

[0003] Among the related network configuration methods, on the one hand, a point-to-point connection is established with the device through a mobile phone or a dedicated network adapter via BLE or GATT, and then network parameters are sent to the device, thereby enabling the device to access the Mesh network; however, this method requires the device and the network adapter to be within a physical direct connection range, and the configuration process relies on manual operation and the steps are cumbersome, resulting in low deployment efficiency and high labor costs in large-scale networking or long-distance scenarios, and there is a problem that the network configuration function is limited by physical distance.

[0004] On the other hand, network parameters are preset before the device leaves the factory, so that the device can connect to the Mesh network as soon as it is powered on. However, this method lacks flexibility and needs to be reset once the network structure changes, which cannot adapt to the device access needs in dynamic scenarios. Summary of the Invention

[0005] Based on this, it is necessary to provide a method, device, computer equipment and computer-readable storage medium for configuring a Bluetooth Mesh network through Bluetooth broadcast to address the above technical problems, so as to improve network configuration efficiency and reduce resource redundancy during the network configuration process.

[0006] In a first aspect, the present application provides a method for configuring a Bluetooth Mesh network via Bluetooth broadcast, which is applied to a device to be configured, including: Receive Bluetooth network configuration broadcast information, where the Bluetooth network configuration broadcast information is constructed based on the network configuration information of the Bluetooth Mesh network and the network connection reference information of the configuration node. The network configuration information includes the target address information of the target device to be configured, and the network connection reference information includes the message number and the message forwarding tag. Determining, according to a first matching result between the message label and the cached information in the to-be-paired network device, a processing status of the to-be-paired network device on the Bluetooth network pairing broadcast information; If the first matching result indicates that the device to be networked has not processed the Bluetooth network pairing broadcast information in the historical period, determining a matching relationship between the device to be networked and the target device to be networked based on a second matching result between the target address information and the address information of the device to be networked; If the second matching result indicates that the device to be configured matches the target device to be configured, the device to be configured is used as the target device to be configured and is connected to the Bluetooth Mesh network based on the Bluetooth configuration broadcast information; If the second matching result indicates that the device to be paired does not match the target device to be paired, the message forwarding mark is updated to obtain the updated Bluetooth network pairing broadcast information, and the updated Bluetooth network pairing broadcast information is forwarded to the next device to be paired until the target device to be paired is matched within the dynamic message distance determined based on the message forwarding mark and connected to the Bluetooth Mesh network. In a second aspect, the present application provides a method for configuring a Bluetooth Mesh network via Bluetooth broadcast, which is applied to a network configuration node, including: Broadcast the Bluetooth network broadcast information; If a network configuration response broadcast message is received from the target device to be configured in response to the Bluetooth network configuration broadcast message, it indicates that the network configuration of the target device to be configured is successful; If the network configuration response broadcast information is not received within the preset time period, it indicates that the network configuration of the target device to be configured has failed; Obtaining historical network configuration records from the local storage or cloud storage of the network configuration node, parsing the historical network configuration records, and obtaining a message jump path of the Bluetooth network configuration broadcast information within a historical period; Calculating the expected distance radius corresponding to the response area of ​​the target device to be networked based on the structural distribution characteristics of the message jump path; Dynamically adjust the number of message forwarding times in the Bluetooth network configuration broadcast information according to the expected distance radius, so as to generate adjusted Bluetooth network configuration broadcast information according to the adjusted number of message forwarding times, and the adjusted Bluetooth network configuration broadcast information dynamically covers the response area of ​​the target device to be configured; The adjusted Bluetooth network configuration broadcast information is rebroadcasted until the target device to be configured is successfully configured.

[0007] In a third aspect, the present application also provides a device for configuring a Bluetooth Mesh network via Bluetooth broadcast, which is applied to a device to be configured, including: A receiving module, configured to receive Bluetooth network configuration broadcast information, wherein the Bluetooth network configuration broadcast information is information constructed based on the network configuration information of the Bluetooth Mesh network and the network connection reference information of the configuration node, wherein the network configuration information includes the target address information of the target device to be configured, and the network connection reference information includes the message number and the message forwarding tag; A first matching module is used to determine a processing status of the Bluetooth network configuration broadcast information by the device to be configured according to a first matching result between the message label and the cache information in the device to be configured; a second matching module configured to determine a matching relationship between the device to be configured and the target device to be configured based on a second matching result between the target address information and the address information of the device to be configured, if the first matching result indicates that the device to be configured has not processed the Bluetooth network configuration broadcast information in a historical period; A first analysis module is configured to, if the second matching result indicates that the device to be configured matches the target device to be configured, use the device to be configured as the target device to be configured and access the Bluetooth Mesh network based on the Bluetooth configuration broadcast information; The second analysis module is used to update the message forwarding mark to obtain updated Bluetooth network configuration broadcast information if the second matching result indicates that the device to be configured does not match the target device to be configured, and forward the updated Bluetooth network configuration broadcast information to the next device to be configured until the target device to be configured is matched within the dynamic message distance determined based on the message forwarding mark and connected to the Bluetooth Mesh network.

[0008] In a fourth aspect, the present application further provides a device for configuring a Bluetooth Mesh network via Bluetooth broadcast, which is applied to a network configuration node, including: Broadcast module, used to broadcast Bluetooth configuration network broadcast information; A first detection module is configured to, if a network configuration response broadcast message is received from the target device to be configured in response to the Bluetooth network configuration broadcast message, indicate that the network configuration of the target device to be configured is successful; A second detection module is configured to indicate that network configuration for the target device to be configured has failed if the network configuration response broadcast information is not received within a preset period of time; A third analysis module is configured to obtain historical network configuration records from the local storage or cloud storage of the network configuration node, parse the historical network configuration records, and obtain a message jump path of the Bluetooth network configuration broadcast information within a historical period; A fourth analysis module is configured to calculate an expected distance radius corresponding to a response area of ​​the target device to be networked based on a structural distribution feature of the message jump path; An adjustment module is configured to dynamically adjust the number of message forwarding times in the Bluetooth network configuration broadcast information according to the expected distance radius, so as to generate adjusted Bluetooth network configuration broadcast information according to the adjusted message forwarding times, wherein the adjusted Bluetooth network configuration broadcast information dynamically covers a response area of ​​the target device to be configured; The broadcast module is further configured to rebroadcast the adjusted Bluetooth network configuration broadcast information until the target device to be configured is successfully configured.

[0009] In a fifth aspect, the present application also provides a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the above steps when executing the computer program.

[0010] In a sixth aspect, the present application also provides a computer-readable storage medium on which a computer program is stored, and the computer program implements the above steps when executed by a processor.

[0011] The above-mentioned method, apparatus, computer device and computer-readable storage medium for configuring a Bluetooth Mesh network through Bluetooth broadcasting, first, the device to be configured receives the Bluetooth network configuration broadcast information, and according to the first matching result between the message number in the Bluetooth network configuration broadcast information and the cached information, effectively identifies and excludes the processed broadcast information to avoid repeated processing; secondly, when the first matching result indicates that the device to be configured has not processed the broadcast information, according to the second matching result between the target address information in the Bluetooth network configuration broadcast information and the current device address, the device identity is accurately identified to ensure that the network configuration action is only performed on the target device to be configured; thirdly, if the second matching result indicates that the device to be configured matches If the target device to be paired is found, the access operation is driven, thereby achieving accurate access of the target device to be paired with the Bluetooth Mesh network; furthermore, if the second matching result indicates that the device to be paired does not match the target device to be paired, relay forwarding is performed according to the updated message forwarding tag, thereby achieving the propagation and delivery of Bluetooth pairing broadcast information within a limited range; based on this, a Mesh pairing mechanism with a clear structure, accurate identification, and controlled propagation can be constructed. During the pairing process, no manual connection is required and no factory preset configuration is required. Relay jumps within the dynamic message distance based on customized broadcast information can be achieved to achieve rapid pairing over a large range, thereby improving pairing efficiency and reducing resource redundancy during the pairing process. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0013] Figure 1 A flowchart of a method for configuring a Bluetooth Mesh network through Bluetooth broadcasting in one embodiment is shown; Figure 2 A flowchart of a method for configuring a Bluetooth Mesh network through Bluetooth broadcasting in another embodiment is shown; Figure 3 A flowchart of a method for configuring a Bluetooth Mesh network through Bluetooth broadcasting in another embodiment is shown; Figure 4 A structural block diagram of an apparatus for configuring a Bluetooth Mesh network through Bluetooth broadcasting in one embodiment; Figure 5 FIG. 1 is a structural block diagram of an apparatus for configuring a Bluetooth Mesh network through Bluetooth broadcasting in another embodiment. DETAILED DESCRIPTION

[0014] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.

[0015] In one embodiment, Figure 1 As shown, a method for configuring a Bluetooth Mesh network through Bluetooth broadcasting is provided. This embodiment uses the method applied to a device to be configured as an example, and the method includes the following steps S101 to S105.

[0016] Step S101: Receive Bluetooth network configuration broadcast information. The Bluetooth network configuration broadcast information is information constructed based on the network configuration information of the Bluetooth Mesh network and the network connection reference information of the configuration node. The network configuration information includes the target address information of the target device to be configured, and the network connection reference information includes the message number and the message forwarding tag.

[0017] Bluetooth provisioning broadcast information refers to a collection of data frames constructed by a provisioning node and sent via Bluetooth broadcast to implement Bluetooth Mesh network provisioning operations, guiding target devices through the network access process. A provisioning node represents a Mesh device node that has access to a Bluetooth Mesh network and is capable of sending Bluetooth provisioning broadcast information. It is used to proactively initiate network access guidance broadcasts to other unprovisioned devices in the network, such as gateways and dedicated provisioners.

[0018] The "to-be-provisioned device" refers to a device that receives Bluetooth mesh network configuration broadcast information during the Bluetooth mesh network configuration process and participates in identifying and processing the information to determine whether it is an access target. The "target to-be-provisioned device" refers to the access target device explicitly specified in the Bluetooth mesh network configuration broadcast information.

[0019] Among them, the network configuration information represents the core parameter set required to guide the target device to be configured to complete the Bluetooth Mesh network access process, that is, it is used to identify the target device to be configured and initialize the network parameters and security parameters of the target device to be configured; the target address information represents the address field in the Bluetooth configuration broadcast information used to indicate the identity of the target device to be configured, which is used to guide each device to be configured to perform address comparison to determine whether it is the target of this access operation.

[0020] Among them, the network connection reference information represents a set of auxiliary parameters used to indicate the transmission status, forwarding path and processing history of the Bluetooth network configuration broadcast information, that is, it is used to guide the transmission and identification of the Bluetooth network configuration broadcast information between multiple devices to be configured; the message number represents an identification number used to identify the uniqueness of the Bluetooth network configuration broadcast information, that is, it is used to assist the device to be configured that receives the broadcast information to determine whether the current broadcast information has been processed, so as to avoid repeated responses and redundant processing; the message forwarding mark represents a control field in the Bluetooth network configuration broadcast information used to record the message forwarding status, that is, it is used to limit the propagation range and forwarding path length of the broadcast information to ensure the reasonable propagation of the broadcast information in the network.

[0021] Exemplarily, the device to be configured is in a state where it can monitor broadcast signals and continuously parse the content of the received Bluetooth network configuration broadcast information. The received Bluetooth network configuration broadcast information is a data set generated by encapsulating and structurally encoding the network configuration information preset in the Bluetooth Mesh network and the network connection reference information of the configuration node. On the one hand, the network configuration information is used to accurately indicate which devices to be configured are the target access objects during the broadcast process, and usually includes the target address information of the target device to be configured. The target address information is used to accurately compare with the address of the monitoring device itself. On the other hand, the network connection reference information contains the message number and message forwarding mark corresponding to the network configuration broadcast. These contents are used to determine the forwarding status of the broadcast message between the subsequent devices to be configured and to determine whether to continue forwarding the current Bluetooth network configuration broadcast information.

[0022] Step S102: determining a processing status of the Bluetooth network configuration broadcast information by the device to be configured according to a first matching result between the message identifier and the cache information in the device to be configured.

[0023] The cache information in the device to be configured refers to a temporary data set stored inside the device to be configured, which records the identifiers of the Bluetooth configuration broadcast information that has been recently received and processed, and is used to support the device to be configured to determine whether the newly received broadcast information is repeated.

[0024] Among them, the first matching result represents the judgment result after the device to be paired compares the message label in the currently received Bluetooth pairing network broadcast information with the cached information, which is used to identify whether the current Bluetooth pairing network broadcast information is historically processed information, for example, after comparison, a processing status judgment value of "unprocessed" or "processed" is obtained.

[0025] For example, after receiving the Bluetooth network configuration broadcast information, the device to be configured needs to compare and analyze the message number of the information with the cache information stored in the device; the role of the message number is to assign a unique identifier to each Bluetooth network configuration broadcast information, so that each device to be configured can determine whether the currently received Bluetooth network configuration broadcast information is received for the first time based on the message identifier, or whether the same broadcast information has been processed within a certain period of time before. Specifically, to implement this comparison process, the network device to be configured needs to maintain a cache mechanism based on historical broadcast identifiers, which stores message labels that have been processed within a certain time range. When executing the comparison logic, the network device to be configured extracts the message label in the current Bluetooth network configuration broadcast information and compares it with all the recorded message labels in the cache information. If the corresponding message label is not found in the cache information, it can be determined that the Bluetooth network configuration broadcast information is received for the first time, and then it is determined that the current network device to be configured is in a state where the Bluetooth network configuration broadcast information has not yet been processed. Conversely, if the message label already exists in the cache information, it means that the current Bluetooth network configuration broadcast information has been processed, and the network device to be configured can directly discard the broadcast information to avoid redundant processing. Based on this, the unique identification of Bluetooth network configuration broadcast information is achieved, duplicate processing is prevented, and the logical clarity and operational efficiency of the entire broadcast configuration process are improved. At the same time, it ensures that each network device to be configured can correctly distinguish between processed and unprocessed information content.

[0026] Step S103: If the first matching result indicates that the device to be paired has not processed Bluetooth pairing broadcast information in the historical period, a matching relationship between the device to be paired and the target device to be paired is determined based on a second matching result between the target address information and the address information of the device to be paired.

[0027] Among them, the second matching result indicates the judgment result after the device to be paired compares the target address information in the Bluetooth network pairing broadcast information with the address of the device itself, on the premise that the current Bluetooth network pairing broadcast information is received for the first time. This is used to determine whether the device is the target of the current network pairing operation, for example, an address identification result of "match" or "mismatch" is obtained after comparison.

[0028] For example, after confirming that the current Bluetooth network configuration broadcast information is received for the first time, the device to be configured further extracts the target address information in the Bluetooth network configuration broadcast information and compares it with its internally stored device address information one by one to determine whether the current Bluetooth network configuration broadcast information is intended for this device. The target address information is the target device address set by the configuration node, which is used to indicate the scope of objects for which the Bluetooth network configuration broadcast information is intended. Specifically, during this comparison process, the device to be configured must completely read the target address information and match it bit by bit with its own address information to ensure that the address content is consistent in terms of format, encoding length, specific value, etc. before it can be determined to be a successful match. If a difference is found between the two during the comparison process, whether it is a format deviation or a value inconsistency, it should be considered a mismatch. Based on this, it is ensured that each Bluetooth network configuration broadcast information is only accessed and processed by the target device to be configured, preventing non-target devices from participating in the incorrect network configuration process due to mismatching, thereby maintaining the accuracy and orderliness of the Bluetooth Mesh network configuration operation.

[0029] Step S104: If the second matching result indicates that the device to be configured matches the target device to be configured, the device to be configured is used as the target device to be configured and is connected to the Bluetooth Mesh network based on the Bluetooth configuration broadcast information.

[0030] For example, if the second matching result indicates that the address information of the device to be configured is completely consistent with the target address information in the Bluetooth configuration broadcast information, then the current device to be configured is determined to be the target device to be configured that the Bluetooth configuration broadcast information points to. At this point, the target device to be configured needs to perform access operations based on the content of the received complete Bluetooth configuration broadcast information, that is, perform network initialization settings and resource mapping operations based on the network configuration information therein. This access process involves reading the parameter content provided in the Bluetooth configuration broadcast information item by item and mapping it to the local configuration configuration module of the target device to be configured, including configuring the network group ID, subnet grouping parameters, and network communication control parameters. Furthermore, after completing the loading of these parameter contents, the target device to be configured further enters the Bluetooth Mesh network access process, sends a network access request flag to the network through the device's internal communication protocol stack mechanism, and updates its own network status flag to reflect the current access status. Based on this, a logical closed loop is achieved from broadcast reception and judgment to formal network access, completing the identity confirmation and network ownership conversion of the target device to be configured.

[0031] Step S105: If the second matching result indicates that the device to be paired does not match the target device to be paired, the message forwarding mark is updated to obtain updated Bluetooth pairing broadcast information, and the updated Bluetooth pairing broadcast information is forwarded to the next device to be paired until the target device to be paired is matched within the dynamic message distance determined based on the message forwarding mark and connected to the Bluetooth Mesh network.

[0032] The dynamic message distance represents a distance control parameter indicating the maximum transmission range or remaining number of hops within which Bluetooth network configuration broadcast information can be forwarded in the Bluetooth Mesh network. It is used to limit the forwarding chain length of Bluetooth network configuration broadcast information to ensure that it reaches the target device to be configured within a limited propagation path. For example, the number of hops initialized to 3 is reduced by 1 after each forwarding until it reaches 0, terminating the transmission.

[0033] For example, if the second matching result indicates that the current device to be configured does not match the target address information in the Bluetooth configuration network broadcast information, that is, the current device to be configured is not the target device to be configured pointed to by the Bluetooth configuration network broadcast information, then the current device to be configured does not perform the access operation, but processes the current Bluetooth configuration network broadcast information so as to continue forwarding it to other devices to be configured in the network. To this end, it is necessary to update the content of the message forwarding mark in the Bluetooth configuration network broadcast information to update the forwarding status of the Bluetooth configuration network broadcast information, thereby indicating that the current Bluetooth configuration network broadcast information has been processed by this device. Specifically, the update of the message forwarding mark is reflected in the adjustment of the dynamic message distance of the broadcast transmission, for example, by marking the remaining transmission hops in a decreasing form, thereby limiting the transmission range of the Bluetooth configuration network broadcast information in the network, and preventing unlimited propagation from causing network congestion. Furthermore, after completing the message forwarding mark update, the current device to be configured repackages the updated Bluetooth configuration network broadcast information according to the broadcast mechanism in the protocol stack, and forwards it to the surrounding devices to be configured through the local wireless communication channel.

[0034] Subsequent receiving devices will continue the reception, matching, and forwarding processes based on the same judgment mechanism as the current one, until a device to be provisioned is identified as the target device within the specified transmission hop count and access is completed. Based on this, by building a forwarding chain for Bluetooth provisioning broadcast information and combining it with the hop count limit mechanism of the message forwarding tag, the propagation of Bluetooth provisioning broadcast information in the Bluetooth Mesh network is controlled, ensuring that the information can accurately find the target device to be provisioned within a controllable range and complete the provisioning process.

[0035] In the above method for configuring a Bluetooth Mesh network through Bluetooth broadcasting, first, the device to be configured receives the Bluetooth network configuration broadcast information, and according to the first matching result between the message label in the Bluetooth network configuration broadcast information and the cached information, effectively identifies and excludes the processed broadcast information to avoid repeated processing; secondly, when the first matching result indicates that the device to be configured has not processed the broadcast information, according to the second matching result between the target address information in the Bluetooth network configuration broadcast information and the current device address, the device identity is accurately identified to ensure that the network configuration action is only performed on the target device to be configured; thirdly, if the second matching result indicates that the device to be configured matches the target device to be configured, Then the access operation is driven, thereby achieving accurate access of the target device to be configured and the Bluetooth Mesh network; furthermore, if the second matching result indicates that the device to be configured does not match the target device to be configured, relay forwarding is performed according to the updated message forwarding tag, thereby achieving the propagation and delivery of Bluetooth configuration broadcast information within a limited range; based on this, a Mesh configuration mechanism with a clear structure, accurate identification, and controlled propagation can be constructed. During the configuration process, no manual connection is required and no factory preset configuration is required. Relay jumps within the dynamic message distance based on customized broadcast information can be achieved to achieve rapid configuration over a large range, thereby improving configuration efficiency and reducing resource redundancy during the configuration process.

[0036] In an exemplary embodiment, if the second matching result indicates that the device to be configured matches the target device to be configured, the device to be configured is used as the target device to be configured and is connected to the Bluetooth Mesh network based on the Bluetooth configuration broadcast information, including steps S201 to S202; the method also includes steps S203 to S205.

[0037] Step S201: If the second matching result indicates that the network device to be configured matches the target network device to be configured, the network key, application key and network device address in the network configuration information are obtained.

[0038] The network key represents the basic key used to encrypt and decrypt communication data between devices in a Bluetooth Mesh network. It is used to ensure the security and consistency of communication between the access device and the network. For example, it is used for encryption authentication when the device receives and parses networking messages.

[0039] The application key represents an encryption key used to bind the device's application functions to network permissions, ensuring that the device can only access application-layer control commands that match its own role. For example, the application permissions of a device are limited to the lighting control module.

[0040] The network device address represents a unique address code used to identify the target device to be provisioned in the Bluetooth Mesh network. It is used for data exchange and addressing operations between devices, such as the unicast address used to determine the data target during network forwarding.

[0041] Exemplarily, after confirming that the second matching result shows that the address information of the current device to be networked is consistent with the target address information in the Bluetooth network configuration broadcast information, the current device to be networked is used as the target device to be networked for subsequent access configuration processing. Specifically, in order to achieve effective configuration of the target device to be networked, it is necessary to extract the key parameters required for network access from the received Bluetooth network configuration broadcast information. These parameters include network keys, application keys, and network device addresses. Among them, the network key is a basic parameter that supports communication encryption and network identification. Its role is to maintain the basic communication security and consistency after the target device to be networked joins the network; the application key is an encryption parameter that distinguishes the permission control of the device function module. Its role is to ensure that the target device to be networked can only access application resources or task commands that match its own identity after accessing the network; the network device address is an address field that uniquely identifies the identity of the target device to be networked, and is used to ensure that the target device to be networked and the existing device addresses in the network remain non-duplicative.

[0042] Step S202: During the network configuration of the target device to be configured, the network layer communication parameters of the target device to be configured are encrypted and configured according to the network key, the application function module of the target device to be configured is permission-bound according to the application key, and the network identity of the target device to be configured is identified and configured according to the network device address, so as to obtain the network-configured target device to be configured to access the Bluetooth Mesh network.

[0043] Among them, the network layer communication parameters represent a set of control fields related to the device's communication capabilities obtained based on the network key configuration, which are used to manage the device's data forwarding behavior and encryption verification process at the network layer, such as encryption indexes, receiving lists or forwarding control fields.

[0044] Among them, the application function module represents the logical unit in the device that undertakes specific functions, which is used to respond to upper-layer application control commands and perform corresponding tasks, such as performing light brightness adjustment, sensor collection or switch control.

[0045] Among them, the network identity refers to a set of flag information used to identify and mark the identity of a device in a Mesh network, and is used to bind the device to its address, communication status, etc., such as a node identity description value generated by combining the network address and identity tag.

[0046] For example, during the network configuration process for the target device, the network key must first be loaded into the network communication module within the target device. Based on this network key, the network layer communication parameters used by the device, including the encryption algorithm seed, broadcast group identifier, and related authentication values, are updated to enable the target device to subsequently identify and respond to Mesh network messages. Secondly, the application key must be bound to the application function module identifier preset in the target device. This pairing of the application key with specific function service logic ensures that the target device only activates relevant control function services when authorized. Furthermore, the network device address must be written into the address storage structure of the target device and used as the network identification address for the target device's external communications, for subsequent data transmission and reception, network path identification, and authentication. Finally, throughout the network configuration process, the aforementioned parameters must be verified before writing, allowing the configured target device to connect to the Bluetooth Mesh network.

[0047] Step S203: Obtain the message forwarding times in the network connection reference information and the address information of the network configuration node in the network configuration information, and restore the message forwarding mark according to the message forwarding times to obtain the message forwarding mark in the initial state.

[0048] The message forwarding count indicates the maximum number of times the Bluetooth network configuration broadcast information is allowed to be forwarded in the Mesh network. It is used to limit the message propagation range and prevent broadcast flooding. For example, the network configuration broadcast is allowed to be relayed a maximum of three times.

[0049] For example, during the previous network configuration broadcast process, the message forwarding tag in the Bluetooth network configuration broadcast information will be modified or decremented with each relay to indicate its forwarding status and remaining transmission depth. Therefore, after the target network configuration device completes the network access configuration, in order to construct the response information broadcasted back to the configuration node, the relevant control fields for message forwarding in the current device need to be restored to support subsequent broadcast return. Specifically, first, the message forwarding count and the address information of the configuration node originally contained in the Bluetooth network configuration broadcast information are obtained. The message forwarding count records the maximum propagation distance or allowed hop value originally set for the Bluetooth network configuration broadcast information. The address information of the configuration node records the information source of the Bluetooth network configuration broadcast information and the target sending address corresponding to the response information of the target network configuration device; secondly, based on the message forwarding count, the message forwarding tag that was originally decremented is restored to a value consistent with the initial state, so that the response information has the same propagation capability when constructing the broadcast return path, and ensures that the response information can be smoothly propagated back to the original configuration node in the subsequent return broadcast, thereby completing the network access confirmation. Step S204: obtain a randomly generated target message number, and encapsulate the message forwarding mark, message forwarding times, target message number, and address information of the distribution network node in the initial state to obtain distribution network response broadcast information.

[0050] The network configuration response broadcast information refers to the broadcast data packet generated and sent by the target device to be configured after completing the network configuration, which is used to inform the configuration node that it has successfully connected to the network.

[0051] The target message number represents a unique identification number created by the target device to be configured when generating a configuration response broadcast message, and is used to distinguish different configuration response broadcasts to confirm the response source.

[0052] For example, first, a new target message number is generated. This target message number can be generated in a manner consistent with the message number generation method in the Bluetooth network configuration broadcast information to meet uniqueness and traceability requirements. The generated target message number is used to identify the identity of this network configuration response broadcast and is used as a pairing basis after the network configuration node receives it. Subsequently, the message forwarding flag restored to its initial state, the message forwarding count extracted from the Bluetooth network configuration broadcast information, the newly generated target message number, and the network configuration node address information are packaged to form a structured network configuration response broadcast message. The packaging process requires field encoding and content combination according to the established data frame structure in the mesh network to ensure that the network configuration node can correctly identify the semantics of each field upon reception and verify their source and matching relationship. Furthermore, the packaged network configuration response broadcast message should also carry the current device's access status, so that the network configuration node can be informed of the network access completion status through this access status.

[0053] Step S205 : Based on the dynamic message distance determined by the message forwarding flag in the initial state, broadcast the network configuration response broadcast information until the network configuration node receives the network configuration response broadcast information to determine that the target device to be configured has been connected to the Bluetooth Mesh network.

[0054] For example, a broadcast operation is initiated based on an encapsulated configuration response broadcast message, ensuring that the message is ultimately delivered to the original configuration node to complete network access confirmation. The dynamically changing message forwarding flag in the configuration response broadcast message determines the dynamic message propagation distance, i.e., the maximum number of hops the configuration response broadcast message can be forwarded within the network, to control the propagation range of the configuration response broadcast message and avoid unnecessary network occupation. Furthermore, during the broadcast initiation process, the configuration response broadcast message is sent according to the standard Mesh broadcast protocol and is progressively decremented by the current hop count during each relay process until the hop count is exhausted or the configuration response broadcast message is received by the configuration node. Furthermore, throughout the broadcast propagation path, the mesh network's relay devices identify and compare the identification field of the configuration response broadcast message to ensure its validity and propagation authority, while avoiding confusion with other broadcast messages. Finally, upon receiving the configuration response broadcast message carrying the corresponding target message ID and configuration node address, the configuration node confirms that the corresponding target device has completed the access configuration operation.

[0055] In this embodiment, first, based on the extraction and processing of the network key, application key and network device address in the Bluetooth network configuration broadcast information, a complete network access parameter basis is provided for the target network device to be configured; secondly, based on the corresponding configuration behavior of the network key, application key and network device address, comprehensive access initialization of the target network device to be configured at the network layer, application layer and address layer is achieved; thirdly, the message forwarding tag is restored, and the corresponding information is encapsulated into a network configuration response broadcast message with uniqueness and integrity, thereby restoring the propagation capability of the response information and ensuring the effective return path of the response information; thirdly, based on the broadcast mechanism under dynamic message distance control, the network configuration node can reliably perceive the network access status of the target network device to be configured, thereby improving the traceability of the network configuration process and the network feedback capability of the completed configuration.

[0056] In an exemplary embodiment, if the second matching result indicates that the device to be paired does not match the target device to be paired, the message forwarding mark is updated to obtain updated Bluetooth pairing broadcast information, and the updated Bluetooth pairing broadcast information is forwarded to the next device to be paired, including steps S301 to S302; the method also includes step S303.

[0057] Step S301: If the second matching result indicates that the device to be networked does not match the target device to be networked, the message forwarding tag is updated decrementally according to a preset update step to obtain an updated message forwarding tag, and updated Bluetooth network pairing broadcast information is obtained according to the updated message forwarding tag.

[0058] The update step size represents the fixed reduction unit used to decrement the message forwarding tag, that is, it is used to reduce the remaining value of the message forwarding tag after each relay process, thereby controlling the propagation depth of the broadcast information in the Mesh network.

[0059] For example, after completing a comparison operation between the target address information in the Bluetooth network configuration broadcast information and the address information of the device to be configured, if the second matching result indicates that the two are inconsistent, that is, it is determined that the device to be configured is not the target device to be configured for this network configuration broadcast, then the device to be configured should not proceed with network configuration, but should instead enter the relay forwarding process of the Bluetooth network configuration broadcast information. In order to control the transmission depth of the Bluetooth network configuration broadcast information within the network and prevent the unlimited spread of the Bluetooth network configuration broadcast information, the device to be configured needs to perform a decremental update operation on the message forwarding flag carried in the Bluetooth network configuration broadcast information; specifically, this update is based on a preset step value, usually a fixed update step of one, indicating that the current device to be configured has completed a forwarding behavior. Based on this, the updated message forwarding tag indicates that the Bluetooth network configuration broadcast message has undergone a new relay process and the current hop count has been reduced. Subsequently, the device to be configured embeds the updated message forwarding tag into the corresponding field of the original Bluetooth network configuration broadcast message to construct a new Bluetooth network configuration broadcast message. This new Bluetooth network configuration broadcast message retains the original fields in structure and only changes the message forwarding tag value. This ensures that the propagation path length of the Bluetooth network configuration broadcast message can be tracked after each device node, and provides a basis for determining whether to continue forwarding.

[0060] Step S302: If the updated message forwarding flag meets the preset threshold condition, the device to be networked is used as a message relay node to forward the updated Bluetooth network pairing broadcast information to the next device to be networked.

[0061] Among them, the preset threshold condition represents the numerical limit standard used to determine whether the message forwarding mark reaches the condition for allowing continued forwarding, and is used to determine whether the current network device to be configured has relay authority. For example, the minimum allowed forwarding mark value is set to 1. If the current value of the message forwarding mark is less than 1, it will no longer be forwarded.

[0062] The message relay node refers to a device node that receives, updates, and rebroadcasts the broadcast information during the configuration network broadcast process, and is used to relay and transmit Bluetooth configuration network broadcast information between devices.

[0063] For example, after the device to be configured completes the update of the message forwarding tag, it needs to perform a conditional judgment on the current value of the updated message forwarding tag to determine whether the current device to be configured has the authority to continue forwarding the Bluetooth network configuration broadcast information to the next device to be configured. Specifically, the judgment is performed based on the set threshold condition, that is, when the current value of the message forwarding tag is greater than zero, it indicates that the relay can continue, otherwise the forwarding is stopped. Furthermore, under the premise that the current value of the message forwarding tag satisfies the threshold condition, the device to be configured needs to set itself as the logical role of a message relay node. In this state, the device to be configured sends the updated Bluetooth network configuration broadcast information through its local broadcast mechanism, so that the updated Bluetooth network configuration broadcast information is received by other devices to be configured in the network within its communication range. Based on this, it is ensured that the Bluetooth network configuration broadcast information can be received and judged by multiple devices within a reasonable hop count range, which helps to improve the probability of discovering the target device to be configured. At the same time, it also controls the depth of the forwarding path to avoid network congestion caused by excessive broadcasting.

[0064] Step S303: If the updated message forwarding flag does not meet the preset threshold condition, the device to be configured is used as a message abort node to discard the updated Bluetooth configuration broadcast information.

[0065] Exemplarily, the message termination node refers to a device node that performs a termination operation on the broadcast information after determining that the broadcast information has reached the maximum allowed number of transmission times during the distribution network broadcast process, so as to prevent the further spread of the broadcast information.

[0066] For example, if the device to be configured completes the threshold judgment on the updated message forwarding tag and finds that the current value of the updated message forwarding tag does not meet the preset threshold condition, that is, the current value has decreased to zero or reached the specified termination state, it means that the Bluetooth configuration network broadcast information has been propagated to the maximum allowed number of hops in the network and cannot continue to propagate to other devices. In this case, the device to be configured needs to identify the currently received Bluetooth configuration network broadcast information as information that exceeds the propagation range and set itself as the logical role of the message termination node. In this state, the device to be configured will actively discard the Bluetooth configuration network broadcast information that has reached the propagation limit to terminate the further spread of the Bluetooth configuration network broadcast information in the network. Based on this, the circular propagation or invalid propagation of the Bluetooth configuration network broadcast information in the network is effectively avoided, the propagation efficiency of the overall network is improved, and the controllable allocation of network resources is guaranteed, which logically realizes the automatic termination mechanism of the Mesh broadcast path.

[0067] In this embodiment, first, when the second matching result indicates that the device to be configured does not match the target device to be configured, the propagation depth of the Bluetooth configuration broadcast information is dynamically adjusted and a clear propagation hierarchy is established based on the decremental update processing of the message forwarding mark; secondly, it is determined whether the updated message forwarding mark meets the preset threshold condition, so that the device to be configured that meets the relay conditions performs the forwarding operation and continues the broadcast path, while the device to be configured that does not meet the relay conditions performs the discarding operation to realize the automatic termination of the broadcast information at the propagation limit and the release of resources; based on this, a Mesh broadcast management mechanism with controlled forwarding range, adaptive node role and terminable propagation path can be constructed, thereby improving the efficiency of configuration broadcast and the orderliness of network transmission.

[0068] In an exemplary embodiment, if the second matching result indicates that the device to be paired does not match the target device to be paired, the message forwarding mark is incrementally updated according to a preset update step to obtain an updated message forwarding mark, including steps S401 to S402; and the updated Bluetooth pairing broadcast information is forwarded to the next device to be paired, including step S403.

[0069] Step S401: If the second matching result indicates that the device to be configured does not match the target device to be configured, the forwarding priority of the device to be configured is obtained. The forwarding priority of the device to be configured is determined based on the network characteristics and historical operation characteristics of the device to be configured in the current network environment.

[0070] Among them, the forwarding priority indicates the priority processing level of the device to be configured when performing the Bluetooth configuration broadcast relay forwarding operation. It is used to measure the ability and applicability of the device to be configured to undertake the forwarding task in the network. For example, it is rated as a high-priority device based on node stability and forwarding success rate.

[0071] Among them, the network characteristics and historical operation characteristics in the current network environment represent a set of dynamic parameters used to evaluate the forwarding priority of the device. The network characteristics represent information such as the connection density, neighbor node quality, and location channel stability of the current device. The historical operation characteristics represent the number of successes, response delay, broadcast coverage, etc. of the current device in previous forwarding processes, which are used to comprehensively judge the forwarding performance of the current device.

[0072] For example, if the second match result indicates that the device to be provisioned is not the target device for the Bluetooth provisioning broadcast message, the network access operation is not performed, and the preparatory phase for forwarding the broadcast message begins. Specifically, to further optimize the forwarding efficiency and propagation path selection mechanism for Bluetooth provisioning broadcast messages, the forwarding priority of the current device to be provisioned is required. This forwarding priority is not a fixed parameter, but rather a comprehensive assessment of the actual network characteristics of the network environment in which the device is currently located and its historical operational characteristics formed during previous communications. Network characteristics may include factors such as the connection density and stability between the device and surrounding nodes, the transmission quality of the communication link, and the physical or topological location of the device node. Historical operational characteristics include operational indicators such as the device's past participation frequency, success rate, and response latency in forwarding tasks. Based on this, by analyzing the parameters in these multiple dimensions, a numerical evaluation is ultimately generated to measure the device's relay capability and network effectiveness, which serves as the forwarding priority of the device to be provisioned. This forwarding priority is used to guide step size selection and delay control in subsequent forwarding behaviors and forms the basis for building a multi-level broadcast strategy.

[0073] Step S402: determining an update step corresponding to the device to be configured according to its forwarding priority, and decreasingly updating the message forwarding mark according to the update step corresponding to the device to be configured to obtain an updated message forwarding mark.

[0074] For example, after obtaining and confirming its forwarding priority, the network device to be provisioned determines an update step size based on the forwarding priority to decrement the message forwarding tag. Specifically, there is a corresponding relationship between the update step size and the forwarding priority. Generally, the higher the forwarding priority, the smaller the update step size, indicating that the device has stronger forwarding capabilities or is in a more advantageous position, and its broadcast information should be transmitted as many hops as possible to expand coverage. Conversely, devices with lower forwarding priorities have larger update step sizes to limit their broadcast range and avoid unnecessary network load. During this process, the network device to be provisioned converts its current forwarding priority into a corresponding update step size using a preset mapping function or lookup table structure. The corresponding update step size is then subtracted from the original message forwarding tag to obtain the updated message forwarding tag. Furthermore, after performing the decrement operation, the network device to be provisioned verifies the value range of the message forwarding tag to ensure that it does not exceed the allowable limit and avoid overflow or negative values. This achieves a dynamic correspondence between forwarding depth and device capabilities, thereby improving the rationality of broadcast paths in the network and the accuracy of resource allocation for message dissemination.

[0075] Step S403: determine the forwarding delay corresponding to the device to be configured according to the forwarding priority of the device to be configured, and forward the updated Bluetooth configuration broadcast information to the next device to be configured according to the forwarding delay corresponding to the device to be configured.

[0076] Among them, the forwarding delay refers to the waiting time set according to the forwarding priority of the device to be configured after receiving the Bluetooth configuration network broadcast information to be forwarded. It is used to disperse the broadcast conflicts caused by multiple devices forwarding at the same time, thereby orderly controlling the broadcast order. For example, the device node with high forwarding priority is set to broadcast forwarding after 20 milliseconds, while the device node with low forwarding priority is set to broadcast forwarding after 100 milliseconds.

[0077] For example, after a device updates its message forwarding flag, it enters the broadcast information transmission phase. Before executing the broadcast operation, a forwarding delay setting is further determined based on the forwarding priority of the device. This forwarding delay represents the waiting time between a device receiving a broadcast message and initiating forwarding. It is used to control conflicts caused by concurrent forwarding by multiple nodes in a mesh network. Specifically, devices with higher forwarding priorities are assigned shorter forwarding delays, allowing them to send broadcast messages first, thereby increasing the utilization of efficient paths. Devices with lower forwarding priorities, on the other hand, are required to wait longer to avoid redundant conflicts in the network. Based on this, the device searches for the corresponding forwarding delay value based on its forwarding priority and waits for it. When the set time for the forwarding delay value is reached, the device uses the local broadcast function to transmit the updated Bluetooth network configuration broadcast information to all other devices within the current broadcast range. This ensures not only the timing of broadcasts but also optimizes the coordination of concurrent forwarding by multiple devices in the mesh network by introducing a delay mechanism, thereby enhancing the orderliness and transmission efficiency of the entire configuration broadcast process.

[0078] Furthermore, first, an adaptive priority update mechanism based on real-time network topology changes can be introduced. This mechanism continuously collects environmental parameters such as network connectivity, node density changes, and channel stability during device operation, and adjusts the forwarding priority of the device currently being provisioned in real time, thereby dynamically optimizing the broadcast path. Secondly, for forwarding delay control, a conflict prediction model can be introduced, combining the forwarding behavior records of neighboring nodes with the frequency of conflicts. Based on the predictions output by the conflict prediction model, the forwarding delay of the device currently being provisioned can be adjusted, further reducing transmission conflicts caused by concurrent broadcasts. Furthermore, a priority backoff mechanism can be introduced. When multiple high-priority nodes in adjacent areas simultaneously attempt to forward, some nodes are probabilistically guided to delay forwarding to maintain the dispersion of broadcast traffic within the network, improving overall network stability and broadcast transmission efficiency. Through these expansions, an intelligent broadcast control mechanism tailored to dynamic network environments is formed, striking a balance between structural controllability and policy flexibility.

[0079] Furthermore, a segmented adjustment logic can be introduced into the update step mechanism. For example, the current update step size can be determined based on the forwarding priority and the current message forwarding tag value, making the propagation strategy at different stages more adaptable and rhythmic. Specifically, when updating the message forwarding tag, a fixed update step size corresponding to the forwarding priority is no longer used. Instead, a dual-factor decision mechanism based on the forwarding priority and the forwarding state is introduced. Specifically, the forwarding priority of the current device to be provisioned is first determined to determine its priority range (e.g., high, medium, or low). Then, the propagation stage (e.g., initial, intermediate, or final) is determined based on the message forwarding tag value currently carried by the broadcast message. Within different stages, even if devices have the same priority, their update step size will be adjusted accordingly. For example, in the initial stage, prioritizing wide propagation, a smaller update step size is assigned, while in the final stage, accelerating propagation termination, a larger update step size is assigned. Through this dynamic mapping method based on two variables, the update step size shows a phased change feature throughout the entire communication life cycle, which not only improves the spatial coverage efficiency of the broadcast, but also effectively compresses redundant paths at the end of the communication, thereby improving the rhythm control ability of the broadcast strategy and network resource utilization.

[0080] In this embodiment, first, the forwarding priority is determined based on the network characteristics and historical operating characteristics of the device to be configured in the current network environment, thereby realizing dynamic evaluation and differentiated identification of the relay capability of the device to be configured; secondly, the update step of the message forwarding tag is determined based on the forwarding priority, thereby realizing fine control of the message propagation depth and resource allocation optimization; thirdly, the forwarding delay is determined based on the forwarding priority, thereby effectively avoiding channel conflicts and information interference caused by concurrent forwarding of multiple devices; based on this, a broadcast information relay mechanism can be realized in which the broadcast forwarding behavior is adapted to the device capability and the transmission order is coordinated with the network status, thereby improving the stability, accuracy and efficiency of network broadcasting.

[0081] In an exemplary embodiment, the message label is information generated by combining the device information, digital signature, and random character string of the target device to be configured in the network configuration node according to a preset encoding algorithm.

[0082] The device information represents a set of identification data related to the target device to be networked, and is used to uniquely identify the identity of the target device to be networked, such as the hardware address, device model or serial number of the target device to be networked.

[0083] Among them, the digital signature refers to an encrypted identification that authenticates the integrity and source of data based on encryption technology to prevent information from being forged or tampered with, such as the verification value after using the device private key to sign the device information and random string.

[0084] Among them, the encoding algorithm represents a logical method for formatting, combining and encoding multiple data fields of different types according to a predefined structure to generate a structured message label, such as constructing identification content through field splicing and hash summary.

[0085] For example, when constructing a Bluetooth configuration broadcast message, a configuration node encodes the target device's device information, a digital signature, and a random string to generate a unique message ID. The device information, which may include the device's type, identification code, or hardware identifier, identifies the target device for the broadcast. The digital signature provides integrity verification, ensuring the message ID cannot be forged or tampered with. The random string enhances the unpredictability and uniqueness of the message ID, thereby preventing identity conflicts caused by multiple configuration operations on the same device. These three elements are incorporated into a pre-defined encoding algorithm, which typically has a fixed field structure and length specification, ensuring that the generated message ID can be accurately parsed by all devices. The resulting message ID serves as a unique identifier for the Bluetooth configuration broadcast message and is transmitted along with the Bluetooth configuration broadcast message to the mesh network for subsequent cache comparison and uniqueness verification by receiving devices. This enables global identity management for configuration broadcasts, laying the foundation for subsequent broadcast processing paths and first match result determination.

[0086] In an exemplary embodiment, the Bluetooth network configuration broadcast information is information generated by verifying and encrypting the network configuration information, network connection reference information, a preset frame header, and a preset frame footer according to a preset layered encryption verification algorithm in the network configuration node.

[0087] Among them, the layered encryption and verification algorithm represents a processing flow for separately performing encryption and verification on different functional data segments in the Bluetooth configuration network broadcast information to improve the security and integrity of the broadcast information, such as symmetric encryption of sensitive parameters, appending verification values ​​to the frame structure, and other combined operations.

[0088] For example, when constructing a Bluetooth configuration broadcast message, a configuration node organizes and protects multiple data segments, including network configuration information, network connection reference information, frame headers, and frame trailers, to generate a complete broadcast message packet. The network configuration information represents core fields required for network configuration, such as the network key, application key, and device address; the network connection reference information represents control fields that control the propagation path, such as the message number, message forwarding count, and message forwarding flag; and the pre-set frame header and frame trailer represent identification fields that define the start and end points of the entire broadcast message packet. Before integrating and encapsulating these multiple data segments, a layered encryption and verification algorithm is executed to encrypt and verify the core fields, control fields, and identification fields, respectively, to ensure that the information has not been tampered with, duplicated, or counterfeited during transmission. Furthermore, the encapsulation process strictly adheres to the protocol structure, resulting in a broadcast message packet with semantic structural integrity, field logical correctness, and information security, enabling it to be accurately parsed and executed by any device in the mesh network to execute the configuration logic.

[0089] Optionally, layered encryption and verification is implemented by dividing Bluetooth network configuration broadcast information into multiple functional layers, with each layer undergoing encryption and verification based on its data type and security requirements. First, the network key, application key, and device address in the network configuration information layer are encrypted using a symmetric encryption algorithm to ensure these sensitive parameters are not leaked during the broadcast process. Second, the message number, message forwarding count, and message forwarding flag in the network connection reference information layer are integrity-verified using a structured verification method. A checksum or hash digest is used to generate a checksum value that is appended to the end of the message for parsing and confirmation by the receiving end. Third, format consistency checks are performed on control fields such as the header and trailer to ensure the integrity of the broadcast frame structure and clear boundaries. Finally, the processing results of each layer are encapsulated into a unified data frame structure to complete the generation of the overall broadcast information. Based on this, through this layered encryption and verification mechanism, data at different layers are processed separately according to their functional characteristics, improving information security while enhancing parsing reliability and network compatibility.

[0090] In an exemplary embodiment, if the Bluetooth configuration network broadcast information is information initially sent by the configuration network node, the message forwarding mark in the network connection reference information is a message forwarding mark in the initial state; if the Bluetooth configuration network broadcast information is information forwarded by any message relay node, the message forwarding mark in the network connection reference information is a message forwarding mark in the updated state.

[0091] For example, when a configuration node first broadcasts Bluetooth configuration broadcast information to the network, the broadcast information has not yet been relayed, so the message forwarding flag included in its network connection reference information should be in the initial state. The message forwarding flag in the initial state is usually set to a maximum forwarding hop count or a default hop value. For example, a value of 3 indicates that the message can be relayed up to three times. Based on this, Bluetooth configuration broadcast information has the manageable propagation depth property from the outset, improving the scheduling efficiency and transmission order of information flow in the mesh network.

[0092] For example, if a Bluetooth network configuration broadcast message is not directly sent by a configuration node but forwarded from any message relay node in the network, the message forwarding tag should be in an updated state to reflect that it has completed a certain number of hops of propagation history. This updated state not only identifies whether the broadcast message has been relayed, but also provides a basis for the next-hop node to determine whether the conditions for continued forwarding are met. Therefore, the process of the message forwarding tag changing from the initial state to the updated state records the trajectory of the Bluetooth network configuration broadcast message as it is relayed layer by layer in the mesh network. It serves as a behavioral identification clue for the entire network configuration propagation path. Based on this, it ensures that the broadcast behavior has path constraints and state recognition capabilities, which helps to build a precise, controllable, and decentralized information flow transmission mechanism.

[0093] In an exemplary embodiment, after determining the processing status of the Bluetooth pairing broadcast information by the device to be paired according to a first matching result between the message label and the cached information in the device to be paired, the method further includes steps S601 to S602.

[0094] Step S601: If the message number does not match the cached information in the device to be networked, the first matching result indicates that the device to be networked has not processed the Bluetooth networked broadcast information, and the message number is stored to obtain new cached information.

[0095] Exemplarily, the cache information of the device to be configured stores several message labels that have been received in the past. The message labels in the cache information can be stored in the form of a queue, a hash table, or a fixed-capacity circular buffer, so as to ensure that the reception record of recent broadcast information is maintained under the premise of resource constraints. Furthermore, when the first matching result shows that the message label in the Bluetooth configuration network broadcast information has not yet appeared in the cache information, it is determined that the device to be configured is in an unprocessed state for the Bluetooth configuration network broadcast information. At this time, the device to be configured needs to append the message label as a new reception record to the cache information. In addition, the device to be configured also needs to set a cache update strategy. For example, when the cache capacity reaches the upper limit, it adopts a first-in-first-out or preferential elimination of older message labels for maintenance. Based on this, the device to be configured can establish an initial mechanism for uniquely identifying broadcast information, thereby ensuring that each broadcast message is processed only once, which helps to improve the orderliness of the overall broadcast processing and the accuracy of resource utilization.

[0096] Step S602: If the message number matches the cached information in the device to be networked, the first matching result indicates that the device to be networked has processed the Bluetooth networked broadcast information, and the Bluetooth networked broadcast information is discarded.

[0097] For example, when the first matching result indicates that the message ID in the Bluetooth network configuration broadcast information already appears in the cached information, the device to be configured is determined to have processed the Bluetooth network configuration broadcast information. This indicates that the current Bluetooth network configuration broadcast information has already been identified and processed by the device in the previous broadcast cycle, and no further matching judgment, address comparison, or forwarding operations are required. To prevent redundant processing logic, repeated forwarding of information, or network chaos, the device to be configured must immediately discard the Bluetooth network configuration broadcast information. This allows the device to quickly filter identified information, effectively reducing repeated calculations and communication resource usage, thereby optimizing the real-time nature and execution efficiency of broadcast processing.

[0098] In this embodiment, first, the unmatched message labels are stored in the cache information, thereby establishing a unique identification record of the broadcast information to avoid misidentification during subsequent repeated judgments; secondly, the matched message labels are judged to be in a processed state and the Bluetooth pairing network broadcast information is discarded, thereby effectively preventing repeated broadcast information from entering the subsequent processing flow and reducing computing and communication resource consumption; based on this, a closed-loop process for screening broadcast information identified by unique labels provides a low-load, high-response, and simple-structured basic judgment method for information management in the Bluetooth Mesh network, thereby improving the judgment accuracy and resource scheduling efficiency of the entire network broadcast behavior.

[0099] In an exemplary embodiment, Figure 2 As shown, the method is applied to a device to be networked, and includes steps S701 to S711.

[0100] Step S701: Receive Bluetooth network broadcast information and read the message number and target address information therein.

[0101] Step S702: Determine whether the message ID already exists in the cached information of the device to be networked. If not, execute step S703 to cache the message ID; if so, execute step S708 to discard the Bluetooth network configuration broadcast information.

[0102] After executing step S703, step S704 is executed to determine whether the target address information matches the address information of the device to be configured. If not, step S705 is executed to decrement the message forwarding flag in the Bluetooth configuration broadcast information by 1. If so, step S709 is executed to read the network key, application key, and device address in the Bluetooth configuration broadcast information, so that the device to be configured can automatically configure and join the mesh network.

[0103] After executing step S709, execute step S710 to encapsulate the message forwarding times, the message forwarding mark in the initial state, the regenerated message number, and the address information of the configuration node in the Bluetooth configuration network broadcast information to obtain the configuration network response broadcast information and broadcast it.

[0104] After executing step S705, execute step S706 to determine whether the message forwarding flag is 0. If not, execute step S707 to forward the Bluetooth network configuration broadcast information; if so, execute step S711 to discard the Bluetooth network configuration broadcast information.

[0105] In an exemplary embodiment, Figure 3 As shown, a method for configuring a Bluetooth Mesh network through Bluetooth broadcasting is provided. This embodiment takes the method applied to a distribution network node as an example, and the method includes the following steps S801 to 807.

[0106] Step S801: broadcast Bluetooth network broadcast information.

[0107] Step S802: If the target device to be networked is received in response to the Bluetooth network pairing broadcast information, it indicates that the target device to be networked is successfully paired.

[0108] Exemplarily, the address data in the Bluetooth network configuration broadcast information includes the address information of the configuration node and the target address information of the target device to be configured, so that the network configuration response broadcast information generated by the target device to be configured includes matching address data.

[0109] Based on this, on the one hand, if the target device that receives the configuration network response broadcast information is a configuration network node type, then according to the matching result between the address information of the target device and the address information of the configuration network node, it is determined that the target device belongs to the configuration network node and the configuration of the target device to be configured is successful, or the target device does not belong to the configuration network node and the configuration network response broadcast information is processed according to the message forwarding tag in the configuration network response broadcast information.

[0110] On the other hand, if the target device receiving the network configuration response broadcast information is a non-network configuration node type, the network configuration response broadcast information is directly processed according to the message forwarding tag in the network configuration response broadcast information.

[0111] Specifically, after the configuration node broadcasts the Bluetooth configuration broadcast information, when the target device to be configured receives the Bluetooth configuration broadcast information and completes address matching and configuration processing, it will send a configuration response broadcast information carrying the target message number and the MAC address of the specified configuration node to the network in the form of a response. Furthermore, if a configuration node in a continuous listening state listens to a configuration response broadcast information containing the target message number after the broadcast operation, the target message number is compared with the cached information in the configuration node; if the target message number exists in the cached information of the configuration node, it means that the configuration node has processed the configuration response broadcast information in the historical period, and based on the message forwarding tag in the configuration response broadcast information, it determines whether to send the configuration response broadcast information to the next device or discard it. If the target message number does not exist in the cache information of the network distribution node, it means that the network distribution node has not processed the network distribution response broadcast information in the historical period. Then, it is further determined whether the MAC address of the specified network distribution node contained in the network distribution response broadcast information matches the MAC address of the current network distribution node. If so, it is determined based on the network distribution response broadcast information that the target device to be distributed is successfully distributed. If not, it is determined based on the message forwarding mark in the network distribution response broadcast information whether the network distribution response broadcast information is sent to the next device or discarded.

[0112] More specifically, the Bluetooth network configuration broadcast information includes the MAC address of the network configuration node and the MAC address of the target device to be configured. Correspondingly, the network configuration response broadcast information also synchronously includes the MAC address of the above-mentioned network configuration node and the MAC address of the target device to be configured. Based on this, the network configuration response broadcast information can be accurately sent to the network configuration node according to the MAC address of the network configuration node therein, and after receiving the network configuration response broadcast information, the network configuration node can accurately locate the message source according to the MAC address of the target device to be configured.

[0113] Furthermore, if there are multiple network configuration nodes, then after receiving the network configuration response broadcast information, a network configuration node can directly determine whether it is the network configuration node specified by the network configuration response broadcast information based on the MAC address of the specified network configuration node in the network configuration response broadcast information; if so, it can determine whether the target device to be configured is successfully configured based on the network configuration response broadcast information; if not, it can determine whether to send the network configuration response broadcast information to the next device or discard it based on the message forwarding tag in the network configuration response broadcast information. Furthermore, after receiving the network configuration response broadcast information, other types of devices other than network configuration nodes can directly determine whether to send the network configuration response broadcast information to the next device or discard it based on the message forwarding tag in the network configuration response broadcast information, without having to pre-compare the MAC address of the specified network configuration node in the network configuration response broadcast information.

[0114] Step S803: If no network configuration response broadcast information is received within the preset time period, it indicates that the network configuration of the target device to be configured has failed.

[0115] For example, after sending a Bluetooth configuration broadcast message, the configuration node initiates a preset period of time for receiving responses. The length of this preset period is set according to the system configuration to ensure that it covers a reasonable time range required for broadcast transmission, device processing, and return transmission. If no configuration response broadcast message carrying the target message ID is received within this preset period, it is determined that the current broadcast was not successfully received, identified, or processed by the target device to be configured, and the configuration operation is considered a failure. This ensures that the configuration behavior has timeout control and status feedback capabilities.

[0116] Step S804: Obtain historical network configuration records from the local storage or cloud storage of the network configuration node, parse the historical network configuration records, and obtain the message jump path of the Bluetooth network configuration broadcast information within the historical period.

[0117] Among them, the historical network configuration record refers to the data set of the broadcast transmission and device response process recorded by the network configuration node in the previous network configuration process. It is used to reflect the actual propagation trajectory and status feedback of each network configuration broadcast in the Mesh network, such as the network configuration time, target device information, broadcast hop count, forwarding node list, and response reception status.

[0118] The message jump path represents the sequence of message relay nodes that a Bluetooth configuration broadcast message passes through when it propagates from the configuration node to the outside in the Mesh network. It is used to describe the actual route trajectory of the broadcast message in the network.

[0119] For example, in order to solve the path optimization problem after the network configuration fails, the network configuration node needs to parse the data in the historical network configuration records to extract the actual propagation path of the previous Bluetooth network configuration broadcast information in the network, that is, the specific structure of the message jump path. First, the network configuration node calls the historical network configuration records in the local storage or cloud server. These records store key data related to each network configuration operation, including the broadcast initiation time, the corresponding target network device identifier, the forwarding node address list, the reception timestamp of each node, the forwarding order between nodes, and the final response reception status. Secondly, by screening the historical record items corresponding to the current target network device to be configured and the corresponding message label, the relay node information that the Bluetooth network configuration broadcast information passed through in sequence during the last failed propagation process is extracted. Then, based on the reception time of each relay node and the forwarding order in the record, the message jump path before the Bluetooth network configuration broadcast information was sent from the network configuration node to the target network device to be configured is reconstructed. This message hop path restores the information propagation path through the forwarding association structure between nodes. For example, if node B receives the same broadcast message after node A, and there is a forwarding record between A and B, it is considered a valid hop. Similarly, the complete chain of broadcast propagation can be mapped. The parsing process also incorporates additional data such as hop count, signal delay, and node forwarding interval to further enhance the accuracy and timing consistency of the path structure.

[0120] Step S805 : Calculate the expected distance radius corresponding to the response area of ​​the target device to be networked based on the structural distribution characteristics of the message jump path.

[0121] Among them, the structural distribution characteristics of the message jump path represent structural information such as the spatial distribution status, hop level, forwarding density, and path repetition degree of each device node in the propagation chain formed by the message jump path, which is used to analyze the diffusion pattern and effective coverage level of broadcast information when it propagates in the network.

[0122] The response area of ​​the target device to be configured represents the spatial or logical range within which the target device to be configured can receive Bluetooth configuration broadcast information and respond in the Mesh network. It is used to define the area that the Bluetooth configuration broadcast information should effectively cover.

[0123] The expected distance radius represents the maximum number of hops or propagation depth expected to be covered from the distribution network node to the response area of ​​the target device to be distributed.

[0124] For example, based on the structural distribution characteristics such as the positional relationship, hop count level, and distribution density of each relay node in the message jump path, the expected distance radius corresponding to the response area of ​​the target network device to be configured is analyzed. Specifically, the network configuration node first hierarchically classifies the propagation status of each hop according to the order of the relay nodes of each hop recorded in the message jump path, such as the first hop, the second hop, and the last hop, and constructs a complete hierarchical propagation model through the grouped hop count information. Then, in the constructed hierarchical propagation model, the distribution changes of the number of relay nodes in each hop are counted, and combined with the propagation stability of each hop and the degree of redundancy within the hop, it is judged whether the broadcast information has concentrated broadcast delays, propagation interruptions, or dense distribution characteristics within a certain hop. On this basis, the hop count is accumulated layer by layer to determine the propagation depth that the distribution network broadcast is expected to pass through from the initial issuance to the response of the target network device to be configured. If the maximum number of hops in the historical message jump path is 5, and the response information of the target device to be configured has not appeared at the 5th hop, and a stable jump structure and node association are expected between the 5th hop and the 6th hop, the configuration node will infer that the response area of ​​the target device to be configured has extended to the 6th hop range, and will use the 6th hop as the expected distance radius for the next round of broadcast.

[0125] The expected distance radius is not directly equivalent to physical distance. Instead, it refers to the outermost hop level that the broadcast information must traverse in the message jump path at the network forwarding logic level. It represents the minimum coverage capability required for the distribution network broadcast to ensure that it can reach the target network device. Based on this, the distribution characteristics of the historical path structure are converted into parameter control references for the next round of broadcast strategy. This allows subsequent distribution network behavior to be based on data-supported propagation range estimates, thus avoiding blindly setting forwarding depth or hop values, improving the accuracy of broadcast behavior and the rationality of network load.

[0126] Step S806: Dynamically adjust the message forwarding times in the Bluetooth network configuration broadcast information according to the expected distance radius, and generate adjusted Bluetooth network configuration broadcast information according to the adjusted message forwarding times. The adjusted Bluetooth network configuration broadcast information dynamically covers the response area of ​​the target device to be configured.

[0127] Step S807: rebroadcast the adjusted Bluetooth network configuration broadcast information until the target device to be configured is successfully configured.

[0128] For example, first, the expected distance radius is mapped to the corresponding number of message forwarding times. This mapping relationship is usually determined by the hop control rule preset in the network configuration strategy. For example, each hop corresponds to one effective forwarding, so as to achieve dynamic adjustment of the number of message forwarding times. Furthermore, after the adjustment of the number of message forwarding times is completed, the message forwarding mark is restored according to the adjusted number of message forwarding times to obtain the message forwarding mark in the initial state; then, according to the adjusted number of message forwarding times, the message forwarding mark in the initial state, and the regenerated message number are embedded into the data structure of the original Bluetooth network configuration broadcast information, replacing the original field, thereby generating the adjusted Bluetooth network configuration broadcast information; the adjusted Bluetooth network configuration broadcast information has stronger propagation adaptability, and can cover the response area that was not effectively reached before in subsequent broadcast operations, thereby increasing the possibility of successful network configuration.

[0129] In this embodiment, first, the network configuration confirmation is completed according to the network configuration response broadcast information returned by the target device to be configured, so that the network configuration node can quickly determine the access status; secondly, if the network configuration fails, the message jump path is extracted and reconstructed according to the historical network configuration records, and then the expected distance radius is calculated according to the structural distribution characteristics of the message jump path, so as to clarify the response area level that the broadcast needs to cover, and provide data support for the subsequent broadcast range adjustment; thirdly, the number of message forwarding times is adjusted according to the expected distance radius, so as to generate broadcast information with better coverage capability and improve the subsequent network configuration success rate; based on this, a Bluetooth network configuration method with failure response judgment, path intelligent backtracking and parameter adaptive adjustment capabilities can be constructed, thereby improving the accuracy, success rate and resource efficiency of device access in the Mesh network.

[0130] It should be understood that, although the various steps in the flowcharts involved in the various embodiments described above are displayed in sequence according to the instructions of the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least a portion of the steps in the flowcharts involved in the various embodiments described above can include multiple steps or multiple stages, and these steps or stages are not necessarily executed and completed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a portion of steps or stages in other steps.

[0131] Based on the same inventive concept, embodiments of the present application also provide a device for configuring a Bluetooth Mesh network via Bluetooth broadcast, which is used to implement the aforementioned method for configuring a Bluetooth Mesh network via Bluetooth broadcast. The solution provided by this device is similar to the solution described in the aforementioned method. Therefore, the specific limitations of one or more embodiments of the device for configuring a Bluetooth Mesh network via Bluetooth broadcast provided below can be found in the aforementioned method for configuring a Bluetooth Mesh network via Bluetooth broadcast, and will not be further elaborated here.

[0132] In an exemplary embodiment, Figure 4 As shown, a device for configuring a Bluetooth Mesh network through Bluetooth broadcasting is provided, which is applied to a device to be configured, and includes: a receiving module 401, a first matching module 402, a second matching module 403, a first analysis module 404 and a second analysis module 405, wherein: Receiving module 401, configured to receive Bluetooth network configuration broadcast information, which is information constructed based on the network configuration information of the Bluetooth Mesh network and the network connection reference information of the configuration node. The network configuration information includes the target address information of the target device to be configured, and the network connection reference information includes the message number and the message forwarding tag. A first matching module 402 is configured to determine a processing status of the Bluetooth network configuration broadcast information by the device to be configured based on a first matching result between the message label and the cached information in the device to be configured; A second matching module 403 is configured to determine a matching relationship between the device to be configured and the target device to be configured based on a second matching result between the target address information and the address information of the device to be configured, if the first matching result indicates that the device to be configured has not processed Bluetooth network configuration broadcast information in a historical period; The first analysis module 404 is configured to, if the second matching result indicates that the device to be configured matches the target device to be configured, use the device to be configured as the target device to be configured and access the Bluetooth Mesh network based on the Bluetooth configuration broadcast information; The second analysis module 405 is used to update the message forwarding tag to obtain updated Bluetooth network pairing broadcast information if the second matching result indicates that the device to be paired does not match the target device to be paired, and forward the updated Bluetooth network pairing broadcast information to the next device to be paired until the target device to be paired is matched within the dynamic message distance determined based on the message forwarding tag and connected to the Bluetooth Mesh network.

[0133] In an exemplary embodiment, the first analysis module 404 is also used to: if the second matching result indicates that the device to be configured matches the target device to be configured, then obtain the network key, application key and network device address in the network configuration information; in the process of performing network configuration on the target device to be configured, encrypt and configure the network layer communication parameters of the target device to be configured according to the network key, perform permission binding processing on the application function module of the target device to be configured according to the application key, and perform identification configuration processing on the network identity of the target device to be configured according to the network device address, so as to obtain the network-configured target device to be configured to access the Bluetooth Mesh network; the device also includes a response module, The response module is used to: obtain the message forwarding times in the network connection reference information and the address information of the distribution network node in the network configuration information, restore the message forwarding tag according to the message forwarding times to obtain the message forwarding tag in the initial state; obtain the randomly generated target message number, encapsulate the message forwarding tag in the initial state, the message forwarding times, the target message number, and the address information of the distribution network node to obtain the distribution network response broadcast information; broadcast the distribution network response broadcast information based on the dynamic message distance determined by the message forwarding tag in the initial state until the distribution network node receives the distribution network response broadcast information to determine that the target device to be configured has been connected to the Bluetooth Mesh network.

[0134] In an exemplary embodiment, the second analysis module 405 is also used to: if the second matching result indicates that the device to be paired does not match the target device to be paired, then the message forwarding tag is updated incrementally according to the preset update step to obtain an updated message forwarding tag, and the updated Bluetooth pairing network broadcast information is obtained according to the updated message forwarding tag; if the updated message forwarding tag meets the preset threshold condition, the device to be paired is used as a message relay node to forward the updated Bluetooth pairing network broadcast information to the next device to be paired; if the updated message forwarding tag does not meet the preset threshold condition, the device to be paired is used as a message termination node to discard the updated Bluetooth pairing network broadcast information.

[0135] In an exemplary embodiment, the second analysis module 405 is also used for: if the second matching result indicates that the device to be paired does not match the target device to be paired, then obtaining the forwarding priority of the device to be paired, the forwarding priority of the device to be paired is determined based on the network characteristics and historical operation characteristics of the device to be paired in the current network environment; according to the forwarding priority of the device to be paired, determining the update step corresponding to the device to be paired, and decreasingly updating the message forwarding mark according to the update step corresponding to the device to be paired to obtain an updated message forwarding mark; according to the forwarding priority of the device to be paired, determining the forwarding delay corresponding to the device to be paired, and forwarding the updated Bluetooth pairing broadcast information to the next device to be paired according to the forwarding delay corresponding to the device to be paired.

[0136] In an exemplary embodiment, the first matching module 402 is also used to: if the message label does not match the cached information in the device to be paired, the first matching result indicates that the device to be paired has not processed the Bluetooth network pairing broadcast information, and the message label is stored to obtain new cached information; if the message label matches the cached information in the device to be paired, the first matching result indicates that the device to be paired has processed the Bluetooth network pairing broadcast information, and the Bluetooth network pairing broadcast information is discarded.

[0137] In an exemplary embodiment, Figure 5 As shown, a device for configuring a Bluetooth Mesh network through Bluetooth broadcasting is provided, which is applied to a network configuration node, and includes: a broadcast module 501, a first detection module 502, a second detection module 503, a third analysis module 504, a fourth analysis module 505, and an adjustment module 506, wherein: Broadcast module 501, used to broadcast Bluetooth network broadcast information; The first detection module 502 is configured to, if a network configuration response broadcast message is received from the target device to be configured in response to the Bluetooth network configuration broadcast message, indicate that the network configuration of the target device to be configured is successful; The second detection module 503 is configured to indicate that network configuration of the target device to be configured has failed if no network configuration response broadcast information is received within a preset period of time; The third analysis module 504 is used to obtain historical network configuration records from the local storage or cloud storage of the network configuration node, parse the historical network configuration records, and obtain the message jump path of the Bluetooth network configuration broadcast information within the historical period; The fourth analysis module 505 is configured to calculate an expected distance radius corresponding to a response area of ​​a target device to be networked based on a structural distribution feature of a message jump path; An adjustment module 506 is configured to dynamically adjust the number of message forwarding times in the Bluetooth network configuration broadcast information according to the expected distance radius, so as to generate adjusted Bluetooth network configuration broadcast information according to the adjusted message forwarding times, and the adjusted Bluetooth network configuration broadcast information dynamically covers the response area of ​​the target device to be configured; The broadcast module 501 is further configured to rebroadcast the adjusted Bluetooth network configuration broadcast information until the target device to be configured is successfully configured.

[0138] Each module in the apparatus for configuring a Bluetooth Mesh network via Bluetooth broadcasting may be implemented in whole or in part via software, hardware, or a combination thereof. Each module may be embedded in or independent of a processor in a computer device in hardware form, or may be stored in a computer device memory in software form, so that the processor can call and execute the corresponding operations of each module.

[0139] In an exemplary embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor implements the steps in any of the above embodiments when executing the computer program.

[0140] In one embodiment, 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 in any of the above embodiments are implemented.

[0141] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0142] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present application. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present application, and these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present application shall be determined by the appended claims.

Claims

1. A method for configuring a Bluetooth Mesh network via Bluetooth broadcast, characterized in that: Applied to the device to be networked, the method includes: Receive Bluetooth network configuration broadcast information, where the Bluetooth network configuration broadcast information is constructed based on the network configuration information of the Bluetooth Mesh network and the network connection reference information of the configuration node. The network configuration information includes the target address information of the target device to be configured, and the network connection reference information includes the message number and the message forwarding tag. Determining, according to a first matching result between the message label and the cached information in the to-be-paired network device, a processing status of the to-be-paired network device on the Bluetooth network pairing broadcast information; If the first matching result indicates that the device to be networked has not processed the Bluetooth network pairing broadcast information in the historical period, determining a matching relationship between the device to be networked and the target device to be networked based on a second matching result between the target address information and the address information of the device to be networked; If the second matching result indicates that the device to be configured matches the target device to be configured, the device to be configured is used as the target device to be configured and is connected to the Bluetooth Mesh network based on the Bluetooth configuration broadcast information; If the second matching result indicates that the device to be paired does not match the target device to be paired, the message forwarding mark is updated to obtain the updated Bluetooth network pairing broadcast information, and the updated Bluetooth network pairing broadcast information is forwarded to the next device to be paired until the target device to be paired is matched within the dynamic message distance determined based on the message forwarding mark and connected to the Bluetooth Mesh network.

2. The method according to claim 1, characterized in that If the second matching result indicates that the device to be configured matches the target device to be configured, the device to be configured is used as the target device to be configured and accesses the Bluetooth Mesh network based on the Bluetooth configuration broadcast information, including: If the second matching result indicates that the network device to be configured matches the target network device to be configured, obtaining the network key, application key, and network device address in the network configuration information; In the process of performing network configuration on the target device to be configured, the network layer communication parameters of the target device to be configured are encrypted and configured according to the network key, the application function module of the target device to be configured is permission-bound according to the application key, and the network identity of the target device to be configured is configured according to the network device address, so as to obtain the network-configured target device to be configured for accessing the Bluetooth Mesh network; The method further comprises: Obtaining the message forwarding count in the network connection reference information and the address information of the network configuration node in the network configuration information, and restoring the message forwarding mark according to the message forwarding count to obtain the message forwarding mark in an initial state; Obtaining a randomly generated target message number, encapsulating the message forwarding mark in the initial state, the number of message forwarding times, the target message number, and the address information of the distribution network node to obtain distribution network response broadcast information; Based on the dynamic message distance determined by the message forwarding mark in the initial state, the configuration network response broadcast information is broadcasted until the configuration network node receives the configuration network response broadcast information to determine that the target device to be configured has been connected to the Bluetooth Mesh network.

3. The method according to claim 1, characterized in that If the second matching result indicates that the device to be networked does not match the target device to be networked, updating the message forwarding flag to obtain updated Bluetooth network pairing broadcast information, and forwarding the updated Bluetooth network pairing broadcast information to the next device to be networked, including: If the second matching result indicates that the to-be-paired network device does not match the target to-be-paired network device, the message forwarding tag is decremented and updated according to a preset update step to obtain an updated message forwarding tag, and updated Bluetooth network pairing broadcast information is obtained according to the updated message forwarding tag; If the updated message forwarding flag meets the preset threshold condition, the device to be networked is used as a message relay node to forward the updated Bluetooth network configuration broadcast information to the next device to be networked; The method further comprises: If the updated message forwarding mark does not meet the preset threshold condition, the device to be networked is used as a message abort node to discard the updated Bluetooth network configuration broadcast information.

4. The method according to claim 3, characterized in that If the second matching result indicates that the to-be-configured network device does not match the target to-be-configured network device, then decreasingly updating the message forwarding flag according to a preset update step to obtain an updated message forwarding flag includes: If the second matching result indicates that the network device to be configured does not match the target network device to be configured, obtaining the forwarding priority of the network device to be configured, where the forwarding priority of the network device to be configured is determined based on the network characteristics and historical operation characteristics of the network device to be configured in the current network environment; Determine the update step size corresponding to the device to be configured according to the forwarding priority of the device to be configured, and decrement the message forwarding mark according to the update step size corresponding to the device to be configured to obtain an updated message forwarding mark; The step of forwarding the updated Bluetooth network configuration broadcast information to the next device to be configured includes: According to the forwarding priority of the device to be networked, the forwarding delay corresponding to the device to be networked is determined, and the updated Bluetooth network pairing broadcast information is forwarded to the next device to be networked according to the forwarding delay corresponding to the device to be networked.

5. The method according to claim 1, wherein The message label is information generated by combining the device information, digital signature and random character string of the target device to be configured in the network configuration node according to a preset encoding algorithm; The Bluetooth configuration network broadcast information is generated by verifying and encrypting the network configuration information, network connection reference information, preset frame header and preset frame tail according to a preset layered encryption verification algorithm in the configuration network node; If the Bluetooth network configuration broadcast information is information initially sent by the network configuration node, the message forwarding mark in the network connection reference information is a message forwarding mark in an initial state; if the Bluetooth network configuration broadcast information is information forwarded by any message relay node, the message forwarding mark in the network connection reference information is a message forwarding mark in an updated state; The address data in the Bluetooth network configuration broadcast information includes the address information of the network configuration node and the target address information of the target device to be configured, so that the network configuration response broadcast information generated by the target device to be configured includes matching address data, for: If the target device receiving the network configuration response broadcast information is a network configuration node type, then, based on a match result between the address information of the target device and the address information of the network configuration node, it is determined that the target device belongs to the network configuration node and that the network configuration of the target device to be configured is successful, or the target device does not belong to the network configuration node and the network configuration response broadcast information is processed according to the message forwarding tag in the network configuration response broadcast information; If the target device receiving the network configuration response broadcast information is a non-network configuration node type, the network configuration response broadcast information is directly processed according to the message forwarding tag in the network configuration response broadcast information.

6. The method according to claim 1, characterized in that After determining, based on a first matching result between the message identifier and the cached information in the device to be networked, a processing status of the device to be networked on the Bluetooth network pairing broadcast information, the method further includes: If the message number does not match the cached information in the to-be-connected device, the first matching result indicates that the to-be-connected device has not processed the Bluetooth network connection broadcast information, and the message number is stored to obtain new cached information; If the message number matches the cache information in the device to be networked, the first matching result indicates that the device to be networked has processed the Bluetooth network pairing broadcast information, and the Bluetooth network pairing broadcast information is discarded.

7. A method for configuring a Bluetooth Mesh network via Bluetooth broadcast, characterized in that: Applied to a distribution network node, the method includes: Broadcast the Bluetooth network broadcast information; If a network configuration response broadcast message is received from the target device to be configured in response to the Bluetooth network configuration broadcast message, it indicates that the network configuration of the target device to be configured is successful; The method further comprises: If the network configuration response broadcast information is not received within the preset time period, it indicates that the network configuration of the target device to be configured has failed; Obtaining historical network configuration records from the local storage or cloud storage of the network configuration node, parsing the historical network configuration records, and obtaining a message jump path of the Bluetooth network configuration broadcast information within a historical period; Calculating the expected distance radius corresponding to the response area of ​​the target device to be networked based on the structural distribution characteristics of the message jump path; Dynamically adjust the number of message forwarding times in the Bluetooth network configuration broadcast information according to the expected distance radius, so as to generate adjusted Bluetooth network configuration broadcast information according to the adjusted number of message forwarding times, and the adjusted Bluetooth network configuration broadcast information dynamically covers the response area of ​​the target device to be configured; The adjusted Bluetooth network configuration broadcast information is rebroadcasted until the target device to be configured is successfully configured.

8. A device for configuring a Bluetooth Mesh network via Bluetooth broadcast, characterized in that: Applied to the equipment to be networked, the device includes: A receiving module, configured to receive Bluetooth network configuration broadcast information, wherein the Bluetooth network configuration broadcast information is information constructed based on the network configuration information of the Bluetooth Mesh network and the network connection reference information of the configuration node, wherein the network configuration information includes the target address information of the target device to be configured, and the network connection reference information includes the message number and the message forwarding tag; A first matching module is used to determine a processing status of the Bluetooth network configuration broadcast information by the device to be configured according to a first matching result between the message label and the cache information in the device to be configured; a second matching module configured to determine a matching relationship between the device to be configured and the target device to be configured based on a second matching result between the target address information and the address information of the device to be configured, if the first matching result indicates that the device to be configured has not processed the Bluetooth network configuration broadcast information in a historical period; A first analysis module is configured to, if the second matching result indicates that the device to be configured matches the target device to be configured, use the device to be configured as the target device to be configured and access the Bluetooth Mesh network based on the Bluetooth configuration broadcast information; The second analysis module is used to update the message forwarding mark to obtain updated Bluetooth network configuration broadcast information if the second matching result indicates that the device to be configured does not match the target device to be configured, and forward the updated Bluetooth network configuration broadcast information to the next device to be configured until the target device to be configured is matched within the dynamic message distance determined based on the message forwarding mark and connected to the Bluetooth Mesh network.

9. A device for configuring a Bluetooth Mesh network via Bluetooth broadcast, characterized in that: Applied to a distribution network node, the device includes: Broadcast module, used to broadcast Bluetooth configuration network broadcast information; A first detection module is configured to, if a network configuration response broadcast message is received from the target device to be configured in response to the Bluetooth network configuration broadcast message, indicate that the network configuration of the target device to be configured is successful; A second detection module is configured to indicate that network configuration for the target device to be configured has failed if the network configuration response broadcast information is not received within a preset period of time; A third analysis module is configured to obtain historical network configuration records from the local storage or cloud storage of the network configuration node, parse the historical network configuration records, and obtain a message jump path of the Bluetooth network configuration broadcast information within a historical period; A fourth analysis module is configured to calculate an expected distance radius corresponding to a response area of ​​the target device to be networked based on a structural distribution feature of the message jump path; An adjustment module is configured to dynamically adjust the number of message forwarding times in the Bluetooth network configuration broadcast information according to the expected distance radius, so as to generate adjusted Bluetooth network configuration broadcast information according to the adjusted message forwarding times, wherein the adjusted Bluetooth network configuration broadcast information dynamically covers a response area of ​​the target device to be configured; The broadcast module is further configured to rebroadcast the adjusted Bluetooth network configuration broadcast information until the target device to be configured is successfully configured.

10. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Network configuration method and device for Bluetooth equipment based on Bluetooth mesh

    CN107508714A

  • Network distribution method of Bluetooth Mesh network and related network distribution equipment and system

    CN111263338A

  • Operation method of Bluetooth Mesh network and Bluetooth device

    CN116095653A

  • Enhanced broadcast concurrent OTA firmware upgrade method based on bluetooth mesh

    US20230179668A1

Cited By

  • Multi-device automatic configuration encryption method and system based on Bluetooth

    CN121099315A

  • Smart device having device identification function based on broadcast signal and method thereof

    CN121367897A

  • Method for judging validity of BLE anchor point, electronic equipment, computer storage medium and program product

    CN121547796A