A Bluetooth network access method and related device and storage medium
By defining fields that support fast distribution network in Bluetooth Mesh technology, network providing devices can identify and respond to multiple devices to be accessed, solving the problem of long time for batch devices to be accessed, realizing fast network access and simplifying the process.
Patent Information
- Application Number
- CN202210331910.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-30
- Publication Date
- 2024-11-08
- Estimated Expiration
- 2042-03-30
AI Technical Summary
The existing Bluetooth Mesh technology has problems such as too long access time and increased network burden when batch devices are accessed, and cannot support fast access to the network.
By defining fields that support fast distribution networks, network-providing devices can identify and respond to multiple devices to be entered, simplifying the network access process and realizing fast network access for batch devices.
It reduces the difficulty of configuring target Mesh network information, simplifies the network access process, realizes fast network access for batch devices, and improves the networking scope of the Mesh network.
Smart Images

Figure CN114710823B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of Bluetooth technology, and in particular to a Bluetooth network access method and related devices and storage media. Background Art
[0002] Bluetooth Mesh technology is a many-to-many key technology based on Bluetooth. Mesh network, also known as "multi-hop network", is a dynamic and continuously expandable network architecture that can realize transmission between devices and build the Internet of Things (IOT) through the intelligence of devices.
[0003] Provision (pre-configuration) is the process of adding nodes to be added to the Mesh network. A device must go through the Provision operation before it can communicate with other nodes in the network. At present, a common initial network is set up for Bluetooth Mesh devices when they leave the factory. When using the initial network for communication, the Provisioner (network provider) is required to continuously exchange protocol data packets (PDU, Protocol Data Unit) with the Bluetooth mesh device. If each data packet can be received normally, the theoretical time to complete the Provision process is 3000 milliseconds (3 seconds), but in actual situations, the average time of the Provision process is about 15 seconds. In order to improve the transmission efficiency of data packets, the existing technology is that after the data packet is added to the broadcast queue, the device to be added to the network transmits a confirmation frame of the pre-configured invitation data packet to the network provider device. The Provisioner determines whether the confirmation frame of the node to be added to the network is received within the PB ACK timer, so as to improve the success rate of network access by appropriately delaying the reception of the data packet, thereby improving the overall time efficiency.
[0004] However, when a large number of devices need to access the network at the same time, this delayed waiting mechanism will result in a long access time, and the Provisioner is not clear about which nodes currently need to access the network. A large number of retransmission packets will also increase the burden on the overall Mesh network and cannot support the rapid access of batch devices. Summary of the invention
[0005] The main technical problem solved by the present application is to provide a Bluetooth network access method and related devices and storage media, which can solve the problem that the existing technology cannot support the rapid network access of batch devices.
[0006] In order to solve the above technical problems, the first technical solution adopted in the present application is to provide a Bluetooth network access method, including: a network providing device receives a beacon broadcast sent by at least one first device to be connected to the network; parsing the beacon broadcast, in response to identifying that the beacon broadcast includes a first field, sending the target Mesh network information to the first device to be connected to the network through broadcasting, so that after the first device to be connected to the network receives the target Mesh network information, it sends a first configuration request packet to the network providing device based on the target Mesh network information; wherein the first field is used to characterize that the first device to be connected to the network supports fast network configuration, and the first configuration request packet includes a first source Mesh short address of the first device to be connected to the network; receiving the first configuration request packet, and parsing the first source Mesh short address from the first configuration request packet, and generating a corresponding second field based on the comparison result of the first source Mesh short address and a pre-recorded Mesh short address list; sending the first configuration response packet including the second field to the first device to be connected to the network, so that after the first device to be connected to the network receives and parses the first configuration response packet, it obtains the first Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the first Mesh short address.
[0007] In order to solve the above technical problems, the second technical solution adopted in the present application is to provide a Bluetooth network access method, including: at least one first device to be connected to the network sends a beacon broadcast so that a network providing device receives the beacon broadcast; wherein the beacon broadcast includes a first field, and the first field is used to indicate that the first device to be connected to the network supports fast network configuration; receiving the target Mesh network information sent by the network providing device after parsing the beacon broadcast and identifying the first field; sending a first configuration request packet to the network providing device based on the target Mesh network information, so that the network providing device receives and parses the first configuration request packet; wherein the first configuration request packet includes the first source Mesh short address of the first device to be connected to the network; receiving the first configuration response packet fed back by the network providing device based on the first source Mesh short address; wherein the first configuration response packet includes the corresponding second field generated by the network providing device based on the comparison result of the first source Mesh short address with the pre-recorded Mesh short address list; parsing the first configuration response packet, and obtaining the first Mesh short address that can access the target Mesh network based on the parsing result of the second field; accessing the target Mesh network based on the first Mesh short address and the target Mesh network information.
[0008] To solve the above technical problems, the third technical solution adopted in the present application is to provide a Bluetooth network access method, including: at least one second device to be connected to the network sends a beacon broadcast, so that at least one first device to be connected to the network receives the beacon broadcast and forwards the beacon broadcast to the network providing device; wherein the beacon broadcast sent by the second device to be connected to the network includes a first field, and the first field is used to characterize that the second device to be connected to the network supports fast network configuration; receiving the beacon broadcast sent by the second device to be connected to the network forwarded by the first device to be connected to the network providing device, parsing the beacon broadcast sent by the second device to be connected to the network and identifying that the beacon broadcast sent by the second device to be connected to the network includes the target Mesh network information sent after the first field; sending a second configuration request packet to the first device to be connected based on the target Mesh network information, so that the first device to be connected to the network receives the first field, and the first field is used to characterize that the second device to be connected to the network supports fast network configuration; receiving the first device to be connected to the network forwarded by the network providing device, parsing the beacon broadcast sent by the second device to be connected to the network and identifying that the beacon broadcast sent by the second device to be connected to the network includes the target Mesh network information sent after the first field; based on the target Mesh network information, sending a second configuration request packet to the first device to be connected to the network, so that the first device to be connected to the network receives the first field, and the first field is used to characterize that the second device to be connected to the network supports fast network configuration; The second configuration request packet is forwarded to the network providing device so that the network providing device can parse the second configuration request packet; wherein the second configuration request packet includes the second source Mesh short address of the second device to be connected to the network; receiving the second configuration response packet forwarded by the first device to be connected to the network and fed back by the network providing device based on the second source Mesh short address; wherein the second configuration response packet includes the corresponding second field generated by the network providing device based on the comparison result of the second source Mesh short address with the pre-recorded Mesh short address list; parsing the second configuration response packet, and obtaining the second Mesh short address that can access the target Mesh network based on the parsing result of the second field; accessing the target Mesh network based on the second Mesh short address and the target Mesh network information.
[0009] To solve the above technical problems, the fourth technical solution adopted in the present application is to provide a network providing device, including: a receiving module, used to receive a beacon broadcast sent by at least one first device to be connected to the network; a parsing module, used to parse the beacon broadcast, in response to identifying that the beacon broadcast includes a first field, sending target Mesh network information to the first device to be connected to the network through broadcasting, so that after the first device to be connected to the network receives the target Mesh network information, it sends a first configuration request packet to the network providing device based on the target Mesh network information; wherein the first field is used to indicate that the first device to be connected to the network supports fast network configuration, and the first configuration request packet includes the first source of the first device to be connected to the network Mesh short address; a first configuration request packet receiving module, used to receive the first configuration request packet, and parse the first source Mesh short address from the first configuration request packet, and generate a corresponding second field based on the comparison result of the first source Mesh short address and the pre-recorded Mesh short address list; a first configuration response packet sending module, used to send the first configuration response packet including the second field to the first device to be connected to the network, so that after the first device to be connected to the network receives and parses the first configuration response packet, it obtains the first Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the first Mesh short address.
[0010] In order to solve the above technical problems, the fifth technical solution adopted in the present application is to provide a first device to be connected to the network, including: a first sending module, used to send a beacon broadcast so that a network providing device receives the beacon broadcast; wherein the beacon broadcast includes a first field, and the first field is used to indicate that the first device to be connected to the network supports fast network configuration; a first receiving module, used to receive the target Mesh network information sent by the network providing device after parsing the beacon broadcast and identifying the first field; a first configuration request packet sending module, used to send a first configuration request packet to the network providing device based on the target Mesh network information, so that the network providing device receives and parses the first configuration request packet; wherein the first configuration request packet contains The invention relates to a mesh network comprising a first source Mesh short address of a first device to be connected to the network; a first configuration response packet receiving module, used to receive a first configuration response packet fed back by a network providing device based on the first source Mesh short address; wherein the first configuration response packet includes a corresponding second field generated by the network providing device based on a comparison result of the first source Mesh short address with a pre-recorded Mesh short address list; a first parsing module, used to parse the first configuration response packet, and obtain a first Mesh short address that can be accessed to a target Mesh network based on a parsing result of the second field; and a first access module, used to access a target Mesh network based on the first Mesh short address and target Mesh network information.
[0011] To solve the above technical problems, the sixth technical solution adopted in the present application is to provide a second device to be connected to the network, including: a broadcast sending module, used to send a beacon broadcast, so that at least one first device to be connected to the network receives the beacon broadcast and forwards the beacon broadcast to the network providing device; wherein the beacon broadcast sent by the second device to be connected to the network includes a first field, and the first field is used to characterize that the second device to be connected to the network supports fast network configuration; an information receiving module, used to receive the beacon broadcast sent by the second device to be connected to the network forwarded by the first device to be connected to the network, parse the beacon broadcast sent by the second device to be connected to the network by the network providing device, and identify the beacon broadcast sent by the second device to be connected to the network including the target Mesh network information sent after the first field; a second configuration request packet sending module, used to send a second configuration request packet to the first device to be connected to the network based on the target Mesh network information, so that the first device to be connected to the network sends the second configuration request packet to the first device to be connected to the network. The packet is forwarded to the network providing device so that the network providing device can parse the second configuration request packet; wherein the second configuration request packet includes the second source Mesh short address of the second device to be connected to the network; a second configuration response packet receiving module is used to receive the second configuration response packet forwarded by the first device to be connected to the network and fed back by the network providing device based on the second source Mesh short address; wherein the second configuration response packet includes the corresponding second field generated by the network providing device based on the comparison result of the second source Mesh short address with the pre-recorded Mesh short address list; an address parsing module is used to parse the second configuration response packet, and obtain the second Mesh short address that can access the target Mesh network based on the parsing result of the second field; a network access module is used to access the target Mesh network based on the second Mesh short address and the target Mesh network information.
[0012] In order to solve the above technical problems, the seventh technical solution adopted in the present application is to provide an electronic device, including: a memory for storing program data, and when the stored program data is executed, the steps in the Bluetooth network access method as described in any one of the above items are implemented; a processor for executing program instructions stored in the memory to implement the steps in the Bluetooth network access method as described in any one of the above items.
[0013] To solve the above technical problems, the eighth technical solution adopted in the present application is to provide a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps in the Bluetooth network access method as described in any one of the above items are implemented.
[0014] The beneficial effects of the present application are as follows: Different from the prior art, the present application provides a Bluetooth network access method and related devices and storage medium, which, by defining a first field that supports fast network configuration, enables a network provider to identify multiple first network access devices that support fast network configuration based on the first field, thereby avoiding a complicated matching and identification process. Furthermore, the network provider sends target Mesh network information to multiple first network access devices through a single broadcast, which enables multiple first network access devices to receive network configuration invitations at the same time, thereby reducing the difficulty of configuring the target Mesh network information, further simplifying the network access process, and thus achieving fast network access for batch devices. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. 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 creative work.
[0016] Figure 1 It is a structural diagram of the first implementation mode of the Bluetooth network access system of the present application;
[0017] Figure 2 yes Figure 1 Signal flow diagram of the first implementation of the Bluetooth network access system;
[0018] Figure 3 It is a flowchart of the first implementation method of the Bluetooth network access method of the present application;
[0019] Figure 4 It is a flowchart of the second implementation method of the Bluetooth network access method of the present application;
[0020] Figure 5 It is a structural diagram of the second implementation mode of the Bluetooth network access system of the present application;
[0021] Figure 6 yes Figure 5 Signal flow diagram of the second implementation mode of the Bluetooth network access system;
[0022] Figure 7 It is a flowchart of the second implementation method of the Bluetooth network access method of the present application;
[0023] Figure 8 It is a structural diagram of an implementation method of a network providing device of the present application;
[0024] Fig. 9 It is a structural diagram of an implementation method of the first device to be connected to the network of the present application;
[0025] Fig.10This is a structural diagram of an implementation method of a second device to be connected to the network in the present application;
[0026] Fig.11 It is a structural schematic diagram of an embodiment of the electronic device of the present application;
[0027] Fig.12 It is a structural schematic diagram of an implementation method of a computer-readable storage medium of the present application. DETAILED DESCRIPTION
[0028] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0029] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application. The singular forms of "a", "said", and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless otherwise clearly indicated above, and "multiple" generally includes at least two, but does not exclude the inclusion of at least one.
[0030] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0031] It should be understood that the terms "include", "comprises" or any other variations used herein are intended to cover non-exclusive inclusion, so that a process, method, article or device that includes a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of more restrictions, the elements defined by the sentence "includes..." do not exclude the presence of other identical elements in the process, method, article or device that includes the elements.
[0032] In order to improve the transmission efficiency of data packets, the existing technology is that after the data packet is added to the broadcast queue, the device to be connected to the network provides a confirmation frame of the pre-configured invitation data packet to the network provider, and the Provisioner determines whether the confirmation frame of the node to be connected to the network is received within the PB ACK timer, so as to improve the success rate of network access by appropriately delaying the reception of the data packet, thereby improving the overall time efficiency. However, when a large number of devices to be connected to the network need to access the network at the same time, this delay waiting mechanism will result in a longer network access time, and the Provisioner is not clear about which nodes currently need to access the network. A large number of retransmitted packets will also increase the burden on the overall Mesh network, and cannot support the rapid access of batch devices.
[0033] Based on the above situation, the present application provides a Bluetooth network access method and related devices and storage media, which can solve the problem that the existing technology cannot support the rapid network access of batch devices.
[0034] Based on the above-mentioned Bluetooth network access method, the present application first provides a Bluetooth network access system.
[0035] Specifically, see Figure 1 , Figure 1 This is a schematic diagram of the structure of the first implementation of the Bluetooth network access system of this application. Figure 1 As shown, in this embodiment, the Bluetooth network access system 9 includes a network providing device 10 and a plurality of first network access waiting devices 11 .
[0036] In this embodiment, the network providing device 10 includes one of a mobile phone, a tablet, and a computer.
[0037] In this implementation, the first device to be connected to the network 11 is a Mesh Bluetooth device, for example, a wireless sensor, lighting device, monitoring device, etc. with Bluetooth Mesh function, which is not limited in this application.
[0038] In this embodiment, the first device to be connected to the network 11 is a Mesh Bluetooth device within the coverage of the network providing device 10. The network providing device 10 can receive the beacon broadcast sent by the first device to be connected to the network 11, and the first device to be connected to the network 11 can also directly receive the broadcast sent by the network providing device 10.
[0039] The first devices to be connected to the network 11 can communicate with each other and forward each other's beacon broadcasts, so that the network providing device 10 can receive more beacon broadcasts of the devices to be connected to the network as quickly as possible within a set time.
[0040] See also Figure 2 , Figure 2 yes Figure 1 Signal flow diagram of the first implementation method of the Bluetooth network access system.
[0041] In this embodiment, the first device to be connected to the network 11 communicates with the network providing device 10 based on the initial network (network), and sends a beacon broadcast with a first field, wherein the first field is used to indicate that the first device to be connected to the network 11 supports fast network configuration. After receiving the beacon broadcast with the first field, the network providing device 10 parses the beacon broadcast to identify the first field, and sends the target Mesh network information through broadcast, so that the first device to be connected to the network 11 in the scanning state receives the network access invitation with the target Mesh network information. After receiving the target Mesh network information, the first device to be connected to the network 11 sends a first configuration request packet to the network providing device based on the target Mesh network information, wherein the first configuration request packet includes the first source Mesh short address of the first device to be connected to the network 11. After receiving the first configuration request packet, the network providing device 10 parses the first source mesh short address from the first configuration request packet, generates a corresponding second field based on the comparison result of the first source mesh short address and the pre-recorded mesh short address list, and sends the first configuration response packet including the second field to the first device to be connected to the network 11, so that after the first device to be connected to the network 11 receives and parses the first configuration response packet, it obtains the first mesh short address that can access the target mesh network based on the parsing result of the second field, and accesses the target mesh network based on the first mesh short address.
[0042] After the multiple first devices to be connected to the target Mesh network 11 are connected, they become Mesh Nodes. The multiple Mesh nodes can communicate with each other through their respective corresponding first Mesh short addresses.
[0043] The first Mesh short address may be allocated by the network providing device 10, or may be generated by the Mesh node according to a preset rule.
[0044] See also Figure 3 , Figure 3 This is a flowchart of the first implementation of the Bluetooth network access method of this application. Figure 3 As shown, in this embodiment, the execution subject of the method is a network providing device, and the method includes:
[0045] S31: The network providing device receives a beacon broadcast sent by at least one first network access device.
[0046] In this implementation manner, the first network access device sends an unprovisioned beacon broadcast (unprovision beacon) including a UUID (Universally Unique Identifier) and Mesh access layer data.
[0047] Among them, UUID is a universal unique identifier, which is pre-assigned by the SIG organization to uniquely identify the device and has a 128-bit address.
[0048] Among them, in the Mesh access layer, the data format is opcode+param (Parameters), and opcode is the command defined by both parties of the protocol, which is the most basic unit of php (Hypertext Preprocessor) program execution. After receiving the data, the receiving end will identify the Opcode and process the corresponding function based on the Opcode. Please refer to Table 1, which is the data format of the Bluetooth Mesh access layer of this application.
[0049] Table 1 Bluetooth Mesh access layer data format for this application
[0050] Field Name Size(octets) Notes Opcode 1,2,or 3 Operation Code Parameters 0to 379 Application Parameters
[0051] Among them, Field Name is the field name, octets is octets or octets or octets, OperationCode is the operation code, and Application Parameters is the application parameters.
[0052] In this implementation, the beacon broadcast of the first device to be connected to the network includes a first field, and the first field is used to indicate that the first device to be connected to the network supports fast network configuration. Specifically, the first field is a command word Opcode defined by the network providing device and the first device to be connected to the network at the application protocol layer. After receiving the beacon broadcast, the network providing device will identify the command based on the Opcode in the beacon broadcast and process the corresponding function based on the command.
[0053] In a specific implementation scenario, the first field (command word Opcode) is defined as PRIVATE_FAST_PROVISION_INFO (private fast configuration information), and the first field indicates that the first network access device supports the fast network configuration function. The first network access device sends a beacon broadcast including the first field, so that the network providing device receives the beacon broadcast and parses the command corresponding to the first field.
[0054] In other implementation scenarios, the defined first field may also be other operation codes, as long as the operation code can be identified as having the meaning of supporting fast network configuration capability, and this application does not limit this.
[0055] In this embodiment, the network provides a device to receive a beacon broadcast sent by at least one first device to be connected to the network within a set time, and parses all beacon broadcasts received within the set time, obtains the device identification information (Mac) corresponding to all first devices to be connected to the network, and adds each device identification information to the device identification information list.
[0056] In a specific implementation scenario, the set time is 2 seconds. In other implementation scenarios, the set time can also be 1 second, 3 seconds or longer, which is not limited in this application.
[0057] In this embodiment, within the set time, the network providing device can also receive beacon broadcasts sent by non-first devices to be connected to the network, where the non-first devices to be connected to the network refer to Mesh devices that do not support fast network configuration. The network providing device also adds the identification information of these devices to the device identification information list, and saves the fast network access judgment results of all devices to be connected to the network in the device identification information list.
[0058] Specifically, please refer to Table 2, which is a list of device identification information of non-networked devices recorded within a set time.
[0059] Table 2 List of device identification information of non-networked devices recorded within a set time
[0060] Mac address of the device to be connected to the network Whether to support fast network configuration 00:01:02:03:04:05 1 00:01:02:03:04:06 1 00:01:02:03:04:07 0 …… ……
[0061] Among them, 1 means that the network providing device has parsed the first field from the beacon broadcast of the device to be connected to the network, that is, the device to be connected to the network is the first device to be connected to the network. 0 means that the network providing device has not parsed the first field from the beacon broadcast of the device to be connected to the network, that is, the device to be connected to the network is not the first device to be connected to the network.
[0062] Among them, when the network providing device determines that the device to be connected to the network is a device without the first field, the network is configured through the SIG (Bluetooth Special Interest Group, Bluetooth Technology Alliance) Mesh standard network access process. The interaction process is relatively cumbersome and does not fall within the scope of protection of this application, so it will not be elaborated here.
[0063] S32: Parse the beacon broadcast, and in response to identifying that the beacon broadcast includes a first field, send the target Mesh network information to the first device to be connected via broadcast, so that after the first device to be connected receives the target Mesh network information, it sends a first configuration request packet to the network providing device based on the target Mesh network information; wherein the first field is used to characterize that the first device to be connected supports fast network configuration, and the first configuration request packet includes a first source Mesh short address of the first device to be connected.
[0064] In this embodiment, the network provides a device to parse the beacon broadcast. In response to identifying that the beacon broadcast includes the first field, it can identify the first device to be networked that has the ability to quickly access the network based on the command corresponding to the Opcode of the protocol, and send the target Mesh network information to the first device to be networked through broadcasting based on the initial network.
[0065] In this implementation manner, the network providing device sends the target Mesh network information to the first network access device through another agreed Opcode.
[0066] The target Mesh network information includes the network key, application key, and interaction index of the target Mesh network.
[0067] In a specific implementation, after the network provider recognizes that the first field is PRIVATE_FAST_PROVISION_INFO, it recognizes all first devices to be connected to the network that have the fast network access function based on the agreed command, and sends the target Mesh network information to the first device to be connected to the network through the defined NETWORK_KEY_INFO (another Opcode), so that the first device to be connected to the network can request the network provider to set new network parameters based on the target Mesh network information. Please refer to Table 3, which is the message format for the network provider to send the target Mesh network information.
[0068] Table 3 Message format of the network providing device sending target Mesh network information
[0069]
[0070] Among them, NETWORK_KEY_INFO is the defined network key command word.
[0071] It can be understood that by defining the first field that supports fast network configuration, the network providing device can identify multiple first network-accessing devices that support fast network configuration based on the first field, thereby avoiding the complicated matching and identification process. Subsequently, by sending a broadcast message, network configuration invitations are sent to multiple first network-accessing devices at the same time, thereby reducing the difficulty of information configuration and further simplifying the network access process.
[0072] In this embodiment, after receiving the network configuration invitation, the first device to be connected to the network will send a first configuration request packet for configuring a new network request to the network providing device based on the target Mesh network information, so as to request the network providing device to access the Mesh short address of the target Mesh network. Specifically, please refer to Table 4, which is the message format of the first device to be connected to the network to send a request for configuring a new network.
[0073] Table 4: Message format of the first device to be connected to the network sending a request to configure a new network
[0074] opcode Parameters CONFIG_NEW_NETWORK_REQUEST XXXXXXXXX
[0075] Among them, CONFIG_NEW_NETWORK_REQUEST is the command word for configuring a new network request.
[0076] In this implementation manner, the first configuration request packet includes a first source Mesh short address of the first device to be networked, and the first source Mesh short address is generated by the first device to be networked based on a preset rule.
[0077] S33: Receive a first configuration request packet, parse the first configuration request packet to obtain a first source Mesh short address, and generate a corresponding second field based on a comparison result between the first source Mesh short address and a pre-recorded Mesh short address list.
[0078] In this embodiment, the Mesh short address list pre-recorded by the network provider includes the Mesh short addresses used by all the Mesh nodes that have joined the network for communication. Specifically, some of these Mesh short addresses are allocated by the network provider, and some are generated by the Mesh nodes according to preset rules, but they do not conflict with each other.
[0079] Since the first source Mesh short address is not allocated by the network providing device, it may conflict with the Mesh address in the Mesh short address list pre-recorded by the network providing device. The network providing device needs to check the first source Mesh short address for duplication.
[0080] In this embodiment, in response to the first source Mesh short address being repeated with a Mesh short address in a pre-recorded Mesh short address list, a second field indicating rejection and a new Mesh short address that can access the target Mesh network are generated.
[0081] Specifically, the network providing device takes the first source Mesh short address for duplicate checking, and after finding an address conflict, generates a result field marked as 0 in a reply message to the first device to be connected to the network, where 0 represents reject. The result field is the second field.
[0082] Furthermore, the network providing device generates a new Mesh short address that can access the target Mesh network, which is used as the communication address of the first device to be networked after being networked, wherein the value range of the new Mesh short address is 0x0001 to 0x7FFFF.
[0083] Based on the previously recorded device ID of the first device to be connected to the network, the network providing device attaches the second field, the new Mesh short address and the device ID to the reply message so as to send it to the first device to be connected to the network. Please refer to Table 5, which shows the message format of the network providing device sending a new network configuration response.
[0084] Table 5: Message format of the network provision device sending a new network configuration response
[0085]
[0086] Furthermore, the network provider adds the generated new Mesh short address into the Mesh short address list for subsequent duplication checking.
[0087] Furthermore, the network providing device deletes the device identification information corresponding to the first device to be networked from the device identification information list.
[0088] In this implementation, in response to the first source Mesh short address not being repeated with any Mesh short address in the pre-recorded Mesh short address list, a second field indicating reception is generated, and the first source Mesh short address is recorded in the Mesh short address list.
[0089] Specifically, the network providing device takes the first source Mesh short address for duplication check, and after finding that there is no address conflict, generates a result field marked as 1 in the reply message to the first device to be connected to the network, where 1 means accept, and directly adds the first source Mesh short address to the Mesh short address list as the communication address of the first device to be connected to the network after connecting to the network.
[0090] Furthermore, the network providing device deletes the device identification information corresponding to the first device to be networked from the device identification information list.
[0091] It can be understood that by checking the first source Mesh short address provided by the first device to be connected to the network for duplication, and when there is a conflict in the Mesh short address, the network providing device provides a new Mesh short address to the first device to be connected to the network in the response packet, the Mesh nodes in the target Mesh network can communicate smoothly using their respective Mesh short addresses.
[0092] S34: Send the first configuration response packet including the second field to the first device to be connected to the network, so that after the first device to be connected to the network receives and parses the first configuration response packet, it obtains a first Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the first Mesh short address.
[0093] In this implementation manner, after receiving the first configuration response packet, the first network access device parses the first configuration response packet.
[0094] Specifically, if the parsing result of the second field (result) is 1, it indicates that the first source Mesh short address does not conflict with any Mesh short address in the Mesh short address list pre-recorded by the network providing device. The first device to be connected to the network can use the first source Mesh short address as the first Mesh short address to access the target Mesh network to communicate through the first source Mesh short address.
[0095] If the parsing result of the second field (result) is 0, it indicates that the first source Mesh short address conflicts with a Mesh short address in the Mesh short address list pre-recorded by the network provider. The first device to be connected to the network obtains the new Mesh short address reallocated by the network provider from the response packet, and uses the new Mesh short address as the first Mesh short address to access the target Mesh network to communicate through the new Mesh short address.
[0096] Furthermore, the network provider determines whether the device identification information list is empty. In response to the device identification information list being empty, the network configuration process is terminated; in response to the device identification information being not empty, it is determined whether the pre-set network configuration time has been exceeded; in response to the pre-configured network configuration time being exceeded, the network configuration process is terminated; in response to the pre-configured network configuration time not being exceeded, the beacon broadcast sent by at least one first device to be networked is continued to be received. In the above manner, the network provider can timely identify all Mesh devices that currently need to be networked, and return to the network configuration process for the devices to be networked in real time.
[0097] Different from the prior art, this embodiment defines a first field that supports fast network configuration, which enables the network provider to identify multiple first devices to be connected to the network that support fast network configuration based on the first field, thereby avoiding a complicated matching and identification process. Furthermore, the network provider sends the target Mesh network information to multiple first devices to be connected to the network through a single broadcast, so that multiple first devices to be connected to the network can receive network configuration invitations at the same time, thereby reducing the difficulty of configuring the target Mesh network information, further simplifying the network access process, and thus achieving fast network access for batch devices. In addition, by checking the first source Mesh short address provided by the first device to be connected to the network for duplicates, and when there is a conflict in the Mesh short address, the network provider provides a new Mesh short address to the first device to be connected to the network in the response packet, so that the Mesh nodes in the target Mesh network can communicate smoothly using their respective Mesh short addresses.
[0098] See further Figure 4 , Figure 4 1 is a flow chart of the second implementation method of the Bluetooth network access method of the present application. Figure 4 As shown, in this embodiment, the execution subject of the method is the first device to be connected to the network, and the method includes:
[0099] S41: At least one first network access device sends a beacon broadcast so that a network providing device receives the beacon broadcast; wherein the beacon broadcast includes a first field, and the first field is used to indicate that the first network access device supports fast network configuration.
[0100] In this implementation manner, in this implementation manner, the first network access device sends an unprovisioned beacon broadcast (unprovision beacon) including a UUID (Universally Unique Identifier) and Mesh access layer data.
[0101] In a specific implementation scenario, the first field (command word Opcode) is defined as PRIVATE_FAST_PROVISION_INFO (private fast configuration information), and the first field indicates that the first network access device supports the fast network configuration function. The first network access device sends a beacon broadcast including the first field, so that the network providing device receives the beacon broadcast and parses the command corresponding to the first field.
[0102] S42: The receiving network provides the device to parse the beacon broadcast and identify the target Mesh network information sent after the first field.
[0103] In this implementation, after the network providing device identifies that the first field is PRIVATE_FAST_PROVISION_INFO, it identifies all first devices to be connected to the network that have the fast network access function based on the agreed command, and sends the target Mesh network information to the first devices to be connected to the network through the defined NETWORK_KEY_INFO, so that the first devices to be connected to the network receive the target Mesh network information sent by the network providing device.
[0104] S43: Send a first configuration request packet to the network providing device based on the target Mesh network information, so that the network providing device receives and parses the first configuration request packet; wherein the first configuration request packet includes a first source Mesh short address of the first device to be connected to the network.
[0105] In this implementation manner, the first device to be networked sends a first configuration request packet to the network providing device based on the target Mesh network information, so as to enable new network parameters according to the feedback result of the network providing device.
[0106] The first source Mesh short address is generated by the first device to be connected to the network based on the preset rules.
[0107] S44: Receive a first configuration response packet fed back by the network providing device based on the first source Mesh short address; wherein the first configuration response packet includes a corresponding second field generated by the network providing device based on a comparison result between the first source Mesh short address and a pre-recorded Mesh short address list.
[0108] In this embodiment, after the network providing device parses the first source Mesh short address from the first configuration request packet, it compares the first source Mesh short address with all Mesh short addresses in a pre-recorded Mesh short address list to determine whether the first source Mesh short address is the same as a Mesh short address in the pre-recorded Mesh short address list.
[0109] In response to the first source Mesh short address being repeated with a Mesh short address in the pre-recorded Mesh short address list, the network provider generates a second field indicating rejection and a new Mesh short address that can access the target Mesh network. Specifically, after the network provider discovers the address conflict, it generates a result field marked as 0 in the reply message to the first device to be connected to the network, where 0 means reject. The result field is the second field. Furthermore, the network provider generates a new Mesh short address that can access the target Mesh network, and attaches the new Mesh short address to the reply message as the communication address of the first device to be connected to the network after it is connected to the network. The value range of the new Mesh short address is 0x0001~0x7FFFF.
[0110] In response to the first source Mesh short address not being repeated with any Mesh short address in the pre-recorded Mesh short address list, the network providing device generates a second field indicating reception, and records the first source Mesh short address in the Mesh short address list. Specifically, after the network providing device finds that the address is not conflicting, it generates a result field marked as 1 in a message replied to the first device to be connected to the network, where 1 indicates accept, and directly adds the first source Mesh short address to the Mesh short address list as the communication address of the first device to be connected to the network after it is connected to the network.
[0111] S45: Parse the first configuration response packet, and acquire a first Mesh short address that can access the target Mesh network based on the parsing result of the second field.
[0112] In this implementation manner, the first network access device obtains the new Mesh short address generated by the network provider device from the first configuration response packet as the first Mesh short address based on the first parsing result of the second field. Or, based on the second parsing result of the second field, the first source Mesh short address is used as the first Mesh short address.
[0113] Specifically, if the parsing result of the second field (result) is 1, it indicates that the first source Mesh short address does not conflict with any Mesh short address in the Mesh short address list pre-recorded by the network providing device. The first device to be connected to the network can use the first source Mesh short address as the first Mesh short address to access the target Mesh network to communicate through the first source Mesh short address.
[0114] If the parsing result of the second field (result) is 0, it indicates that the first source Mesh short address conflicts with a Mesh short address in the Mesh short address list pre-recorded by the network provider. The first device to be connected to the network obtains the new Mesh short address reallocated by the network provider from the response packet, and uses the new Mesh short address as the first Mesh short address to access the target Mesh network to communicate through the new Mesh short address.
[0115] S46: Accessing the target Mesh network based on the first Mesh short address and the target Mesh network information.
[0116] Different from the prior art, this embodiment defines a first field that supports fast network configuration, which enables the network provider to identify multiple first devices to be connected to the network that support fast network configuration based on the first field, thereby avoiding a complicated matching and identification process. Furthermore, the network provider sends the target Mesh network information to multiple first devices to be connected to the network through a single broadcast, so that multiple first devices to be connected to the network can receive network configuration invitations at the same time, thereby reducing the difficulty of configuring the target Mesh network information, further simplifying the network access process, and thus achieving fast network access for batch devices. In addition, by checking the first source Mesh short address provided by the first device to be connected to the network for duplicates, and when there is a conflict in the Mesh short address, the network provider provides a new Mesh short address to the first device to be connected to the network in the response packet, so that the Mesh nodes in the target Mesh network can communicate smoothly using their respective Mesh short addresses.
[0117] See also Figure 5 , Figure 5 This is a schematic diagram of the structure of the second implementation of the Bluetooth network access system of the present application. Figure 5 As shown, in this embodiment, the Bluetooth network access system 200 includes a network providing device 20 , a plurality of first network access waiting devices 21 , and a plurality of second network access waiting devices 22 .
[0118] In this embodiment, the network providing device 20 includes one of a mobile phone, a tablet, and a computer.
[0119] In this implementation, the first network access device 21 and the second network access device 22 are both Mesh Bluetooth devices, for example, wireless sensors, lighting devices, monitoring devices, etc. with Bluetooth Mesh function, which is not limited in this application.
[0120] In this embodiment, the first device to be connected to the network 21 is a Mesh Bluetooth device within the coverage of the network providing device 20. The network providing device 20 can receive the beacon broadcast sent by the first device to be connected to the network 21, and the first device to be connected to the network 21 can also directly receive the broadcast sent by the network providing device 20.
[0121] In this embodiment, the second device to be connected to the network 22 is a Mesh Bluetooth device outside the coverage of the network providing device 20. The network providing device 20 cannot directly receive the beacon broadcast sent by the second device to be connected to the network 22, and the second device to be connected to the network 22 cannot directly receive the broadcast sent by the network providing device 20. The second device to be connected to the network 22 and the network providing device 20 communicate with each other through a suitable first device to be connected to the network 21 as a relay node.
[0122] See also Figure 6 , Figure 6 yes Figure 5 Signal flow diagram of the second implementation mode of the Bluetooth network access system.
[0123] In this embodiment, the second device to be connected to the network 22 sends a beacon broadcast with a first field based on the initial network, wherein the first field is used to indicate that the second device to be connected to the network 22 supports fast network configuration. After the first device to be connected to the network 21 within the communication range of the second device to be connected to the network 22 receives the beacon broadcast and identifies the first field, it forwards the beacon broadcast of the second device to be connected to the network 22. After the network providing device 20 receives the beacon broadcast forwarded by the first device to be connected to the network 21, it parses the beacon broadcast to identify the first field, and sends the target Mesh network information through broadcast. After the first device to be connected to the network 21 receives the target Mesh network information, it forwards the target Mesh network information so that the second device to be connected to the network 22 receives the target Mesh network information. After the second device to be connected to the network 22 receives the target Mesh network information, it sends a second configuration request packet based on the target Mesh network information, wherein the second configuration request packet includes the second source Mesh short address of the second device to be connected to the network 22. After the first device to be connected to the network 21 receives the second configuration request packet sent by the second device to be connected to the network 22, it forwards the second configuration request packet so that the network providing device 20 receives the second configuration request packet sent by the second device to be connected to the network 22. After the network providing device 20 receives the second configuration request packet, it parses the second source mesh short address from the second configuration request packet, generates a corresponding second field based on the comparison result between the second source mesh short address and the pre-recorded mesh short address list, and sends the second configuration response packet including the second field to the first device to be connected to the network 21. After the first device to be connected to the network 21 receives the second configuration response packet, it forwards the second configuration response packet so that the second device to be connected to the network 22 receives the second configuration response packet. After the second device to be connected to the network 22 receives and parses the second configuration response packet, it obtains the second mesh short address that can access the target mesh network based on the parsing result of the second field, and accesses the target mesh network based on the second mesh short address.
[0124] The second Mesh short address may be allocated by the network providing device 20, or may be generated by the Mesh node according to a preset rule.
[0125] Among them, after multiple second devices to be connected to the network 22 are connected to the target Mesh network, they become Mesh Nodes and can communicate through their respective corresponding second Mesh short addresses.
[0126] See also Figure 7 , Figure 7 1 is a flow chart of the second implementation method of the Bluetooth network access method of the present application. Figure 7 As shown, in this embodiment, the execution subject of the method is the second device to be connected to the network, and the method includes:
[0127] S71: At least one second device to be connected to the network sends a beacon broadcast so that at least one first device to be connected to the network receives the beacon broadcast and then forwards the beacon broadcast to the network providing device; wherein the beacon broadcast sent by the second device to be connected to the network includes a first field, and the first field is used to indicate that the second device to be connected to the network supports fast network configuration.
[0128] In this implementation manner, in this implementation manner, the unprovisioned beacon broadcast (unprovision beacon) sent by the second network access device includes UUID (Universally Unique Identifier) and Mesh access layer data.
[0129] In this implementation, all first devices to be networked within the broadcast range of the second device to be networked can receive the beacon broadcast sent by the second device to be networked. After the first device to be networked recognizes that the beacon broadcast contains the first field, it forwards the beacon broadcast so that the network providing device receives the beacon broadcast of the second device to be networked.
[0130] In a specific implementation scenario, the first field (command word Opcode) is defined as PRIVATE_FAST_PROVISION_INFO (private fast configuration information), and the first field indicates that the second device to be connected to the network supports the fast network configuration function. The second device to be connected to the network sends a beacon broadcast including the first field, so that the network providing device receives the forwarded beacon broadcast and parses the command corresponding to the first field.
[0131] It can be understood that by forwarding the beacon broadcast of the second device to be connected to the network by the first device to be connected to the network, the network providing device can receive the beacon broadcast outside the coverage range, so as to subsequently add the Mesh Bluetooth device outside the coverage range of the network providing device to the target Mesh network.
[0132] S72: receiving the beacon broadcast sent by the second device to be connected to the network and forwarded by the first device to be connected to the network, parsing the beacon broadcast sent by the second device to be connected to the network, and identifying that the beacon broadcast sent by the second device to be connected to the network includes the target Mesh network information sent after the first field.
[0133] In this embodiment, after the network providing device parses out the existence of the first field in the beacon broadcast of the second device to be connected to the network, it sends the target Mesh network information by broadcasting. After the first device to be connected to the network receives the target Mesh network information, it forwards it so that the second device to be connected to the network receives the target Mesh network information.
[0134] Furthermore, the network providing device obtains Macs of multiple second devices to be networked, and adds the Macs to a device identification information list.
[0135] S73: Send a second configuration request packet to the first device to be connected to the network based on the target Mesh network information, so that the first device to be connected to the network forwards the second configuration request packet to the network providing device, so that the network providing device can parse the second configuration request packet; wherein the second configuration request packet includes a second source Mesh short address of the second device to be connected to the network.
[0136] In this implementation, the second device to be connected to the network sends a second configuration request packet based on the target Mesh network information. After receiving the second configuration request packet, the first device to be connected to the network forwards the second configuration request packet so that the network providing device receives the second configuration request packet and generates a second configuration response packet based on the second configuration request packet.
[0137] The second source Mesh short address is generated by the second device to be connected to the network based on the preset rules.
[0138] S74: Receive a second configuration response packet forwarded by the first device to be connected to the network, which is fed back by the network providing device based on the second source Mesh short address; wherein the second configuration response packet includes a corresponding second field generated by the network providing device based on the comparison result of the second source Mesh short address and the pre-recorded Mesh short address list.
[0139] In this embodiment, after the network providing device parses the second source Mesh short address from the second configuration request packet, it compares the second source Mesh short address with all Mesh short addresses in the pre-recorded Mesh short address list to determine whether the second source Mesh short address is the same as a Mesh short address in the pre-recorded Mesh short address list.
[0140] In response to the second source Mesh short address being repeated with a Mesh short address in the pre-recorded Mesh short address list, the network provider generates a second field indicating rejection and a new Mesh short address that can access the target Mesh network. Specifically, after the network provider discovers the address conflict, it generates a result field marked as 0 in the reply message to the second device to be connected to the network, where 0 means reject. The result field is the second field. Furthermore, the network provider generates a new Mesh short address that can access the target Mesh network, and attaches the new Mesh short address to the reply message as the communication address of the second device to be connected to the network after it is connected to the network. The value range of the new Mesh short address is 0x0001~0x7FFFF.
[0141] In response to the second source Mesh short address not being repeated with any Mesh short address in the pre-recorded Mesh short address list, the network provider generates a second field indicating reception, and records the second source Mesh short address in the Mesh short address list. Specifically, after the network provider finds that the address does not conflict, it generates a result field marked as 1 in a message replied to the second device to be connected to the network, where 1 indicates accept, and directly adds the second source Mesh short address to the Mesh short address list as the communication address of the second device to be connected to the network after it is connected to the network.
[0142] S75: Parse the second configuration response packet, and acquire a second Mesh short address that can access the target Mesh network based on the parsing result of the second field.
[0143] In this implementation manner, the second network access device obtains the new Mesh short address generated by the network provider device from the second configuration response packet as the second Mesh short address based on the first parsing result of the second field. Or, based on the second parsing result of the second field, the second source Mesh short address is used as the second Mesh short address.
[0144] Specifically, if the parsing result of the second field (result) is 1, it indicates that the second source Mesh short address does not conflict with any Mesh short address in the Mesh short address list pre-recorded by the network providing device. The second device to be connected to the network can use the second source Mesh short address as the second Mesh short address to access the target Mesh network to communicate through the second source Mesh short address.
[0145] If the parsing result of the second field (result) is 0, it indicates that the second source Mesh short address conflicts with a Mesh short address in the Mesh short address list pre-recorded by the network provider. The second device to be connected to the network obtains the new Mesh short address reallocated by the network provider from the response packet, and uses the new Mesh short address as the second Mesh short address to access the target Mesh network to communicate through the new Mesh short address.
[0146] S76: Accessing the target Mesh network based on the second Mesh short address and the target Mesh network information.
[0147] Different from the prior art, this implementation method enables the first device to be connected to the network to act as a relay node by defining a first field that supports fast network configuration, so that the second device to be connected to the network outside the coverage of the network providing device can handshake with the network providing device through the relay node and successfully access the target Mesh network, thereby improving the networking range of the Mesh network.
[0148] Correspondingly, the present application provides a related device of the Bluetooth network access method.
[0149] See also Figure 8 , Figure 8 This is a schematic diagram of the structure of an implementation method of the network providing device of the present application. Figure 8 As shown, in this implementation, the network providing device 80 includes a receiving module 81 , a parsing module 82 , a first configuration request packet receiving module 83 and a first configuration response packet sending module 84 .
[0150] The receiving module 81 is used to receive a beacon broadcast sent by at least one first network access device.
[0151] The parsing module 82 is used to parse the beacon broadcast, and in response to identifying that the beacon broadcast includes a first field, sends the target Mesh network information to the first device to be connected via broadcast, so that after the first device to be connected receives the target Mesh network information, it sends a first configuration request packet to the network providing device based on the target Mesh network information; wherein the first field is used to characterize that the first device to be connected supports fast network configuration, and the first configuration request packet includes the first source Mesh short address of the first device to be connected.
[0152] The first configuration request packet receiving module 83 is used to receive the first configuration request packet, parse the first source Mesh short address from the first configuration request packet, and generate a corresponding second field based on the comparison result between the first source Mesh short address and a pre-recorded Mesh short address list.
[0153] The first configuration response packet sending module 84 is used to send the first configuration response packet including the second field to the first device to be connected to the network, so that after the first device to be connected to the network receives and parses the first configuration response packet, it obtains the first Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the first Mesh short address.
[0154] For the process of receiving the beacon broadcast, parsing the first field, receiving the first configuration request packet, and sending the first configuration response packet, please refer to the relevant text description in S31 to S34, which will not be repeated here.
[0155] See also Fig. 9 , Fig. 9 This is a schematic diagram of the structure of an implementation method of the first device to be connected to the network in this application. Fig. 9 As shown, in this embodiment, the first network access device 90 includes a first sending module 91, a first receiving module 92, a first configuration request packet sending module 93, a first configuration response packet receiving module 94, a first parsing module 95 and a first access module 96.
[0156] The first sending module 91 is used to send a beacon broadcast so that the network providing device receives the beacon broadcast; wherein the beacon broadcast includes a first field, and the first field is used to indicate that the first device to be connected to the network supports fast network configuration.
[0157] The first receiving module 92 is used to receive the target Mesh network information sent by the network providing device after parsing the beacon broadcast and identifying the first field.
[0158] The first configuration request packet sending module 93 is used to send a first configuration request packet to the network providing device based on the target Mesh network information, so that the network providing device receives and parses the first configuration request packet; wherein the first configuration request packet includes the first source Mesh short address of the first device to be connected to the network.
[0159] The first configuration response packet receiving module 94 is used to receive the first configuration response packet fed back by the network providing device based on the first source Mesh short address; wherein the first configuration response packet includes the corresponding second field generated by the network providing device based on the comparison result of the first source Mesh short address and the pre-recorded Mesh short address list.
[0160] The first parsing module 95 is used to parse the first configuration response packet, and obtain a first Mesh short address that can access the target Mesh network based on the parsing result of the second field.
[0161] The first access module 96 is used to access the target Mesh network based on the first Mesh short address and the target Mesh network information.
[0162] Among them, the process of sending beacon broadcast, receiving target Mesh network information, sending a first configuration request packet, receiving a first configuration response packet, obtaining a first Mesh short address, and accessing the target Mesh network can be found in the relevant text descriptions in S41 to S46, which will not be repeated here.
[0163] See also Fig.10 , Fig.10 This is a schematic diagram of the structure of an implementation method of the second device to be connected to the network in this application. Fig.10 As shown, in this implementation, the second network access device 1000 includes a broadcast sending module 1001, an information receiving module 1002, a second configuration request packet sending module 1003, a second configuration response packet receiving module 1004, an address resolution module 1005 and a network access module 1006.
[0164] The broadcast sending module 1001 is used to send a beacon broadcast so that at least one first device to be connected to the network receives the beacon broadcast and then forwards the beacon broadcast to the network providing device; wherein, the beacon broadcast sent by the second device to be connected to the network includes a first field, and the first field is used to indicate that the second device to be connected to the network supports fast network configuration.
[0165] The information receiving module 1002 receives the beacon broadcast sent by the second device to be connected and forwarded by the first device to be connected, analyzes the beacon broadcast sent by the second device to be connected, and identifies that the beacon broadcast sent by the second device to be connected includes the target Mesh network information sent after the first field.
[0166] The second configuration request packet sending module 1003 is used to send a second configuration request packet to the first device to be connected to the network based on the target Mesh network information, so that the first device to be connected to the network forwards the second configuration request packet to the network providing device, so that the network providing device can parse the second configuration request packet; wherein the second configuration request packet includes the second source Mesh short address of the second device to be connected to the network.
[0167] The second configuration response packet receiving module 1004 is used to receive the second configuration response packet forwarded by the first device to be connected to the network, which is fed back by the network providing device based on the second source Mesh short address; wherein the second configuration response packet includes the corresponding second field generated by the network providing device based on the comparison result of the second source Mesh short address and the pre-recorded Mesh short address list.
[0168] The address parsing module 1005 is used to parse the second configuration response packet, and obtain a second Mesh short address that can access the target Mesh network based on the parsing result of the second field.
[0169] The network access module 1006 is used to access the target Mesh network based on the second Mesh short address and the target Mesh network information.
[0170] Among them, the process of sending beacon broadcast, receiving target Mesh network information, sending a second configuration request packet, receiving a second configuration response packet, obtaining a second Mesh short address, and accessing the target Mesh network can be found in the relevant text descriptions in S71 to S76, which will not be repeated here.
[0171] Different from the prior art, the present application defines a first field that supports fast network configuration, so that the network provider can identify multiple first network devices that support fast network configuration based on the first field, avoiding the complex matching and identification process. Furthermore, the network provider sends the target Mesh network information to multiple first network devices through a broadcast, so that multiple first network devices can receive network configuration invitations at the same time, thereby reducing the difficulty of configuring the target Mesh network information, further simplifying the network access process, and thus realizing the rapid network access of batch devices. In addition, by checking the first source Mesh short address provided by the first network device, and when there is a conflict in the Mesh short address, the network provider provides a new Mesh short address to the first network device in the response packet, so that the Mesh nodes in the target Mesh network can communicate smoothly using their respective Mesh short addresses. Furthermore, by making the first network device as a relay node, the second network device outside the coverage of the network provider can interact with the network provider through the relay node and successfully access the target Mesh network, thereby improving the networking range of the Mesh network.
[0172] See also Fig.11 , Fig.11 Schematic diagram of the structure of an electronic device of the present application. Fig.11 As shown, in this embodiment, the electronic device 1100 includes a memory 1101 and a processor 1102 .
[0173] In this implementation manner, the memory 1101 is used to store program data, and when the stored program data is executed, the steps in the Bluetooth network access method corresponding to the network providing device or the first device to be connected to the network or the second device to be connected to the network in any of the above method implementation manners are implemented. The processor 1102 is used to execute the program instructions stored in the memory to implement the steps in the Bluetooth network access method corresponding to the network providing device or the first device to be connected to the network or the second device to be connected to the network in any of the above method implementation manners.
[0174] Specifically, the processor 1102 is used to control itself and the memory 1101 to implement the steps in any of the above-mentioned Bluetooth network access method embodiments. The processor 1102 can also be called a CPU (Central Processing Unit). The processor 1102 may be an integrated circuit chip with signal processing capabilities. The processor 1102 can also be a general-purpose processor, a digital signal processor (Digital Signal Processor, DSP), an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field-programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. In addition, the processor 1102 can be implemented by multiple integrated circuit chips.
[0175] Correspondingly, the present application provides a computer-readable storage medium.
[0176] See also Fig.12 , Fig.12 It is a structural schematic diagram of an implementation method of a computer-readable storage medium of the present application.
[0177] The computer-readable storage medium 1200 includes a computer program 1201 stored on the computer-readable storage medium 1200. When the computer program 1201 is executed by the above-mentioned processor, it implements the steps in any of the above-mentioned method embodiments or the steps correspondingly executed by the relevant devices in the above-mentioned method embodiments.
[0178] Specifically, if the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium 12000. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a computer-readable storage medium 1200, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) or a processor (processor) to perform all or part of the steps of each implementation method of the present application. The aforementioned computer-readable storage medium 1200 includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.
[0179] In the several embodiments provided in the present application, it should be understood that the disclosed methods and devices can be implemented in other ways. For example, the device implementation described above is only schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.
[0180] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0181] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0182] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) or a processor (processor) to perform all or part of the steps of each implementation method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code.
[0183] The above description is only an implementation method of the present application, and does not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly used in other related technical fields, are also included in the patent protection scope of the present application.
Claims
1. A Bluetooth network access method, characterized in that: include: The network providing device receives a beacon broadcast sent by at least one first device to be connected to the network; Parse the beacon broadcast, and in response to identifying that the beacon broadcast includes a first field, send target Mesh network information to the first device to be connected through broadcasting, so that after the first device to be connected receives the target Mesh network information, send a first configuration request packet to the network providing device based on the target Mesh network information; wherein the first field is used to indicate that the first device to be connected supports fast network configuration, and the first configuration request packet includes a first source Mesh short address of the first device to be connected; Receive the first configuration request packet, parse the first source Mesh short address from the first configuration request packet, and generate a corresponding second field based on the comparison result of the first source Mesh short address and the pre-recorded Mesh short address list; specifically including: in response to the first source Mesh short address being repeated with a Mesh short address in the pre-recorded Mesh short address list, generate a second field indicating rejection and a new Mesh short address that can access the target Mesh network; in response to the first source Mesh short address not being repeated with any Mesh short address in the pre-recorded Mesh short address list, generate a second field indicating reception, and record the first source Mesh short address in the Mesh short address list; A first configuration response packet including the second field is sent to the first device to be connected to the network, so that after the first device to be connected to the network receives and parses the first configuration response packet, it obtains a first Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the first Mesh short address.
2. The Bluetooth network access method according to claim 1, characterized in that: The step of the network providing device receiving a beacon broadcast sent by at least one first network access device further includes: Receiving a beacon broadcast sent by at least one of the first network access devices within a set time; After the step of the network providing device receiving the beacon broadcast sent by at least one first network access device, the step further includes: Parsing all the beacon broadcasts received within the set time to obtain device identification information corresponding to all the first devices to be connected to the network; Adding each of the device identification information to the device identification information list; After the step of sending the first configuration response packet including the second field to the first network access device, so that the first network access device receives and parses the first configuration response packet, obtains a first Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the first Mesh short address, the method further includes: The device identification information corresponding to the networked device is deleted from the device identification information list.
3. The Bluetooth network access method according to claim 2, characterized in that: After the step of deleting the device identification information corresponding to the networked device from the device identification information list, the method further comprises: In response to the device identification information list being empty, ending the network configuration process; In response to the device identification information being not empty, determining whether a preset network configuration time has been exceeded; In response to exceeding the pre-configured network configuration time, ending the network configuration process; In response to the pre-configured network configuration time not being exceeded, continue to receive the beacon broadcast sent by at least one of the first network access devices.
4. The Bluetooth network access method according to claim 1, characterized in that: The step of the network providing device receiving a beacon broadcast sent by at least one first network access device further includes: The network providing device receives at least one beacon broadcast sent by a second device to be connected to the network and forwarded by the first device to be connected to the network; wherein the second device to be connected to the network is a device outside the coverage range of the network providing device, and the beacon broadcast sent by the second device to be connected to the network includes the first field; The Bluetooth network access method further includes: Parse the beacon broadcast sent by the second device to be connected to the network, and in response to identifying that the beacon broadcast sent by the second device to be connected to the network includes a first field, send target Mesh network information to the first device to be connected to the network by broadcasting, so that after the first device to be connected to the network receives the target Mesh network information, the target Mesh network information is forwarded to the second device to be connected to the network, so that the second device to be connected to the network sends a second configuration request packet based on the target Mesh network information; wherein the second configuration request packet includes a second source Mesh short address of the second device to be connected to the network; Receiving the second configuration request packet sent by the second device to be connected to the network and forwarded by the first device to be connected to the network, parsing the second source Mesh short address from the second configuration request packet, and generating the corresponding second field based on the comparison result of the second source Mesh short address and the pre-recorded Mesh short address list; A second configuration response packet including the second field is sent to the first device to be networked, so that after the first device to be networked receives the second configuration response packet, the second configuration response packet is forwarded to the second device to be networked, so that the second device to be networked obtains a second Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the second Mesh short address.
5. The Bluetooth network access method according to claim 1, characterized in that: The target Mesh network information includes a network key, an application key, and an interaction index of the target Mesh network.
6. A Bluetooth network access method, characterized in that: include: At least one first device to be connected to the network sends a beacon broadcast so that a network providing device receives the beacon broadcast; wherein the beacon broadcast includes a first field, and the first field is used to indicate that the first device to be connected to the network supports fast network configuration; Receiving target Mesh network information sent by the network providing device after parsing the beacon broadcast and identifying the first field; Sending a first configuration request packet to the network providing device based on the target Mesh network information, so that the network providing device receives and parses the first configuration request packet; wherein the first configuration request packet includes a first source Mesh short address of the first device to be networked; Receive a first configuration response packet fed back by the network providing device based on the first source Mesh short address; wherein the first configuration response packet includes a corresponding second field generated by the network providing device based on a comparison result between the first source Mesh short address and a pre-recorded Mesh short address list; Parsing the first configuration response packet, and acquiring a first Mesh short address that can access the target Mesh network based on the parsing result of the second field; specifically comprising: based on the first parsing result of the second field, acquiring a new Mesh short address generated by the network providing device from the first configuration response packet as the first Mesh short address; or, based on the second parsing result of the second field, using the first source Mesh short address as the first Mesh short address; Access the target Mesh network based on the first Mesh short address and the target Mesh network information.
7. The Bluetooth network access method according to claim 6, characterized in that: The step of at least one first network access device sending a beacon broadcast so that the network providing device receives the beacon broadcast further includes: Receive a beacon broadcast sent by at least one second device to be connected to the network, and forward the beacon broadcast sent by the second device to be connected to the network to the network providing device; wherein the second device to be connected to the network is a device outside the coverage of the network providing device, and the beacon broadcast sent by the second device to be connected to the network includes the first field; The Bluetooth network access method further includes: The network providing device parses the beacon broadcast sent by the second device to be connected to the network and identifies that the beacon broadcast sent by the second device to be connected to the network includes the target Mesh network information sent after the first field, so that the second device to be connected to the network receives the target Mesh network information and sends a second configuration request packet based on the target Mesh network information; Receive and forward the second configuration request packet, so that the network providing device parses the second source Mesh short address from the second configuration request packet, generates the corresponding second field based on the comparison result of the second source Mesh short address and the pre-recorded Mesh short address list, and sends the second configuration response packet including the second field to the first device to be networked; Receive and forward the second configuration response packet so that after the second network-accessing device receives the second configuration response packet, it obtains a second Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the second Mesh short address.
8. A Bluetooth network access method, characterized in that: include: At least one second device to be connected to the network sends a beacon broadcast, so that at least one first device to be connected to the network receives the beacon broadcast and then forwards the beacon broadcast to the network providing device; wherein the beacon broadcast sent by the second device to be connected to the network includes a first field, and the first field is used to indicate that the second device to be connected to the network supports fast network configuration; Receiving the beacon broadcast sent by the second device to be connected to the network and forwarded by the first device to be connected to the network, parsing the beacon broadcast sent by the second device to be connected to the network, and identifying that the beacon broadcast sent by the second device to be connected to the network includes the target Mesh network information sent after the first field; Sending a second configuration request packet to the first device to be networked based on the target Mesh network information, so that the first device to be networked forwards the second configuration request packet to the network providing device, so that the network providing device can parse the second configuration request packet; wherein the second configuration request packet includes a second source Mesh short address of the second device to be networked; Receive a second configuration response packet forwarded by the first device to be networked and fed back by the network providing device based on the second source Mesh short address; wherein the second configuration response packet includes a corresponding second field generated by the network providing device based on a comparison result of the second source Mesh short address with a pre-recorded Mesh short address list; Parsing the second configuration response packet, and acquiring a second Mesh short address that can access the target Mesh network based on the parsing result of the second field; specifically comprising: based on the first parsing result of the second field, acquiring a new Mesh short address generated by the network providing device from the second configuration response packet as the second Mesh short address; or, based on the second parsing result of the second field, using the second source Mesh short address as the second Mesh short address; Access the target Mesh network based on the second Mesh short address and the target Mesh network information.
9. A network providing device, characterized in that: include: A receiving module, used for receiving a beacon broadcast sent by at least one first device to be connected to the network; A parsing module, configured to parse the beacon broadcast, and in response to identifying that the beacon broadcast includes a first field, send target Mesh network information to the first device to be connected to the network by broadcasting, so that after the first device to be connected to the network receives the target Mesh network information, the first configuration request packet is sent to the network providing device based on the target Mesh network information; wherein the first field is used to indicate that the first device to be connected to the network supports fast network configuration, and the first configuration request packet includes a first source Mesh short address of the first device to be connected to the network; A first configuration request packet receiving module is used to receive the first configuration request packet, parse the first source Mesh short address from the first configuration request packet, and generate a corresponding second field based on the comparison result of the first source Mesh short address and a pre-recorded Mesh short address list; specifically comprising: in response to the first source Mesh short address being repeated with a Mesh short address in the pre-recorded Mesh short address list, generating a second field indicating rejection and a new Mesh short address that can access the target Mesh network; in response to the first source Mesh short address not being repeated with any Mesh short address in the pre-recorded Mesh short address list, generating a second field indicating reception, and recording the first source Mesh short address in the Mesh short address list; The first configuration response packet sending module is used to send the first configuration response packet including the second field to the first device to be connected to the network, so that after the first device to be connected to the network receives and parses the first configuration response packet, it obtains a first Mesh short address that can access the target Mesh network based on the parsing result of the second field, and accesses the target Mesh network based on the first Mesh short address.
10. A first device to be connected to the network, characterized in that: include: A first sending module is used to send a beacon broadcast so that a network providing device receives the beacon broadcast; wherein the beacon broadcast includes a first field, and the first field is used to indicate that the first device to be connected to the network supports fast network configuration; A first receiving module, configured to receive target Mesh network information sent by the network providing device after parsing the beacon broadcast and identifying the first field; A first configuration request packet sending module is used to send a first configuration request packet to the network providing device based on the target Mesh network information, so that the network providing device receives and parses the first configuration request packet; wherein the first configuration request packet includes a first source Mesh short address of the first device to be networked; A first configuration response packet receiving module, configured to receive a first configuration response packet fed back by the network providing device based on the first source Mesh short address; wherein the first configuration response packet includes a corresponding second field generated by the network providing device based on a comparison result between the first source Mesh short address and a pre-recorded Mesh short address list; A first parsing module is used to parse the first configuration response packet, and obtain a first Mesh short address that can access the target Mesh network based on the parsing result of the second field; specifically comprising: based on the first parsing result of the second field, obtaining a new Mesh short address generated by the network providing device from the first configuration response packet as the first Mesh short address; or, based on the second parsing result of the second field, using the first source Mesh short address as the first Mesh short address; The first access module is used to access the target Mesh network based on the first Mesh short address and the target Mesh network information.
11. A second device to be connected to the network, characterized in that: include: A broadcast sending module, used for sending a beacon broadcast, so that at least one first device to be connected to the network receives the beacon broadcast and then forwards the beacon broadcast to the network providing device; wherein the beacon broadcast sent by the second device to be connected to the network includes a first field, and the first field is used to indicate that the second device to be connected to the network supports fast network configuration; An information receiving module, configured to receive the beacon broadcast sent by the second device to be connected to the network and forwarded by the first device to be connected to the network, and to parse the beacon broadcast sent by the second device to be connected to the network and identify that the beacon broadcast sent by the second device to be connected to the network includes target Mesh network information sent after the first field; A second configuration request packet sending module, configured to send a second configuration request packet to the first device to be networked based on the target Mesh network information, so that the first device to be networked forwards the second configuration request packet to the network providing device, so that the network providing device can parse the second configuration request packet; wherein the second configuration request packet includes a second source Mesh short address of the second device to be networked; A second configuration response packet receiving module is used to receive a second configuration response packet forwarded by the first device to be connected to the network and fed back by the network providing device based on the second source Mesh short address; wherein the second configuration response packet includes a corresponding second field generated by the network providing device based on a comparison result of the second source Mesh short address with a pre-recorded Mesh short address list; The address parsing module is used to parse the second configuration response packet, and obtain a second Mesh short address that can access the target Mesh network based on the parsing result of the second field; specifically comprising: based on the first parsing result of the second field, obtaining a new Mesh short address generated by the network providing device from the second configuration response packet as the second Mesh short address; or, based on the second parsing result of the second field, using the second source Mesh short address as the second Mesh short address; A network access module is used to access the target Mesh network based on the second Mesh short address and the target Mesh network information.
12. An electronic device, characterized in that: include: A memory, used to store program data, wherein when the stored program data is executed, the steps of the Bluetooth network access method according to any one of claims 1 to 5, the Bluetooth network access method according to any one of claims 6 to 7, or the Bluetooth network access method according to claim 8 are implemented; A processor, configured to execute program instructions stored in the memory to implement the steps in the Bluetooth network access method according to any one of claims 1 to 5, the Bluetooth network access method according to any one of claims 6 to 7, or the Bluetooth network access method according to claim 8.
13. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by the processor, the steps in the Bluetooth network access method according to any one of claims 1 to 5, the Bluetooth network access method according to any one of claims 6 to 7, or the Bluetooth network access method according to claim 8 are implemented.
