An improved BLE Mesh routing method based on neighbor information

By using an improved routing method based on neighbor information in the BLE Mesh network to control message forwarding, the problem of redundant data and energy consumption caused by the flooding routing mechanism is solved, and the communication quality and system stability are improved.

CN116546447BActive Publication Date: 2024-08-30CHONGQING UNIV OF POSTS & TELECOMM
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202310753477.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-25
Publication Date
2024-08-30
Estimated Expiration
2043-06-25

AI Technical Summary

Technical Problem

The flooding routing mechanism in the BLE Mesh network leads to redundant data overload and channel conflicts, which increases the system bit error rate and energy consumption, and node failure may cause the entire system to paralyze.

Method used

An improved routing method based on neighbor information is used to control message forwarding by calculating the delayed forwarding time, priority and remaining energy through the node's cache table and duplicate message counter to avoid redundant data transmission and excessive consumption of nodes.

Benefits of technology

It effectively reduces redundant message transmission, reduces network load and bit error rate, improves communication success rate, and avoids excessive node consumption and system paralysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116546447B
    Figure CN116546447B
Patent Text Reader

Abstract

This invention relates to the field of Bluetooth technology, and particularly to an improved BLE Mesh routing method based on neighbor information. The method includes: a node broadcasting a message; when a neighboring node receives the message, it determines whether the message is in its cache table; if not in the node's cache table, a portion of the message is cached in the node's cache table, and the value of the node's duplicate message counter is set to 1; calculating the delay forwarding time for the message for all nodes that have received the message and whose duplicate message counter is 1; each node waits for the delay forwarding time before forwarding the message, listens to the channel, and if it receives the message again within the delay forwarding time, increments the value of its duplicate message counter by 1; if the value of the duplicate message counter is still 1 after the delay forwarding time ends, the message is forwarded; if the value of the duplicate message counter is greater than 1, the message is deleted from the cache table and the node loses its eligibility to forward messages. This invention enables rapid message coverage across the entire network.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of Bluetooth technology, and in particular to an improved BLE Mesh routing method based on neighbor information. Background Art

[0002] Since the release of low-power Bluetooth technology, the frequency of Bluetooth use in the Internet of Things has been greatly increased. However, as the number of nodes added to the Internet of Things continues to increase, Bluetooth's star topology network structure has limited its development in the Internet of Things. A many-to-many Bluetooth network topology is urgently needed to solve this problem, so the Bluetooth SIG released the first version of the Mesh protocol in 2017. The SIG uses a managed flooding routing mechanism, and Bluetooth mesh only uses three broadcast channels to transmit messages. As the number of nodes in the network increases, the blind forwarding of the flooding mechanism makes the network full of a large amount of redundant data, which is easy to cause an increase in the system bit error rate. In severe cases, it will also cause channel conflicts, which will seriously affect the communication quality. In the managed flooding routing, the node will enter the relay mode by default. The relay mode means that the node will always be in the scanning and broadcasting states, which will increase the energy consumption of the system and is not friendly to many low-power IoT scenarios. At present, the research on BLE Mesh network routing mechanism mainly falls into two categories. One is based on the improvement of managed flood routing, which is divided into using the basic information of nodes, such as the location, distance, and remaining energy of nodes to influence the forwarding strategy of nodes, thereby suppressing redundant information packets. The other category is to introduce the concept of routing in the BLE Mesh network, add parameters such as routing tables to the system, and the nodes are routed according to the routing tables, avoiding the large number of redundant messages brought by the flood routing mechanism. However, the introduced routing will lead to system resource tension, and once a node fails, the entire system will be paralyzed. Summary of the invention

[0003] In order to quickly cover the entire network with messages and reduce message redundancy, the present invention proposes an improved BLE Mesh routing method based on neighbor information, which specifically includes the following steps:

[0004] 101. A node broadcasts message A. When its neighboring node receives message A, it determines whether the message is in its cache table.

[0005] 102. If the received message is not in the cache table of the node, cache part A of the message into the cache table of the node, and set the value of the duplicate message counter dn of the node to 1;

[0006] 103. Calculate the delayed forwarding time of the message for all nodes that receive the message A and whose duplicate message counter dn has a value of 1;

[0007] 104. Each node waits for the delayed forwarding time before forwarding message A and monitoring the channel. If the message is received again within the delayed forwarding time, the value of the duplicate message counter dn is incremented by 1.

[0008] 105. If the value of the duplicate message counter dn is still 1 after the delayed forwarding time ends, message A is forwarded; if the value of the duplicate message counter dn is greater than 1, the cache of message A is deleted from the cache table, and the qualification for forwarding message A is lost.

[0009] Furthermore, the message forwarding delay time is expressed as:

[0010]

[0011] Among them, T(P i ) is the message forwarding delay time function; T delay is the delay parameter; tanh(·) represents the hyperbolic tangent function; P i represents the priority of node i; P i max Represents the maximum priority of node i.

[0012] Furthermore, the node priority P i The calculation process includes:

[0013]

[0014] Among them, E imax represents the maximum battery capacity of node i; E i Represents the battery capacity of node i at the current moment.

[0015] Furthermore, when a node caches part of the information of a message, the SRC field and the SEQ field in the received message are added to the cache table.

[0016] Furthermore, the neighbor nodes of a node are nodes whose distance from the current node does not exceed a set distance.

[0017] The present invention also proposes an improved BLE Mesh routing system based on neighbor information, which includes multiple device nodes. Each device node is provided with a cache table. If a device node broadcasts a data packet to its neighbor node, after receiving the data packet, the device node checks whether there is information about the data packet in the cache table. If not, the value of the duplicate message counter dn in the device node is set to 1. If the current node is not the destination node of the data packet, the current node starts to compete for the qualification of being a relay node. The current node calculates the delayed forwarding time of the corresponding data packet and waits according to the calculated time. If the same data packet is not received again during the waiting process, the node competes successfully and forwards the data packet. Otherwise, the node fails in the competition and discards the data packet.

[0018] The present invention allocates corresponding priorities based on the residual energy of neighbor nodes according to the residual energy value. Nodes with higher priorities will forward messages before nodes with lower priorities, thereby realizing rapid coverage of messages in the entire network. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 A flowchart of an improved BLE Mesh routing method based on neighbor information of the present invention;

[0020] Figure 2 It is a schematic diagram of the message forwarding delay time function in the present invention;

[0021] Figure 3 It is a preferred embodiment of the message transmission process in the BLE Mesh network of the present invention;

[0022] Figure 4 A flowchart of a routing algorithm in a preferred embodiment of the present invention;

[0023] Figure 5 A schematic diagram of a process of sending a data packet by a node in the present invention;

[0024] Figure 6 It is a schematic diagram of the process of receiving and forwarding messages by a node in the present invention. DETAILED DESCRIPTION

[0025] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0026] The present invention proposes an improved BLE Mesh routing method based on neighbor information, such as Figure 1 , specifically including the following steps:

[0027] 101. A node broadcasts message A. When its neighboring node receives message A, it determines whether the message is in its cache table.

[0028] 102. If the received message is not in the cache table of the node, cache part A of the message into the cache table of the node, and set the value of the duplicate message counter dn of the node to 1;

[0029] 103. Calculate the delayed forwarding time of the message for all nodes that receive the message A and whose duplicate message counter dn has a value of 1;

[0030] 104. Each node waits for the delayed forwarding time before forwarding message A and monitoring the channel. If the message is received again within the delayed forwarding time, the value of the duplicate message counter dn is incremented by 1.

[0031] 105. If the value of the duplicate message counter dn is still 1 after the delayed forwarding time ends, message A is forwarded; if the value of the duplicate message counter dn is greater than 1, the cache of message A is deleted from the cache table, and the qualification for forwarding message A is lost.

[0032] In order to avoid broadcast storms, that is, the channel receives multiple messages at the same time, the Mesh protocol recommends that nodes add a random delay after sending messages. In this embodiment, each node will set a delayed forwarding time according to the priority of the node. The node with the highest priority will forward the message first. During the delay time, the low-priority node continues to listen to the message in the channel. If a duplicate message is heard, it indicates that a node with a higher priority has forwarded the message. Then the node that receives the duplicate message will lose the forwarding right, thereby suppressing the forwarding function of this node. In addition, the delay time of the present invention is closely related to the node forwarding priority. The higher the node forwarding priority, the lower the random delay time should be, and the lower the node forwarding priority, the higher the random delay time should be. The delayed forwarding function and the node suppression function can effectively reduce the number of redundant messages in the system, reduce network load, and improve the communication success rate.

[0033] In order to meet the condition that the higher the node forwarding priority, the lower the random delay time should be, and the lower the node forwarding priority, the higher the random delay time should be, those skilled in the art can select any function that meets the condition. This embodiment provides a preferred implementation. In this embodiment, the function It is also a function that meets this condition. When n = 0.5, the function graph is as follows Figure 2 As shown, in this embodiment, the node with higher priority has a smaller delay forwarding time requirement, so the priority P of node i is defined as i The smaller the value, the lower the priority of the node, and the longer the corresponding dynamic delay forwarding time. Then we have:

[0034]

[0035] Among them, T(P i ) is the message forwarding delay time function; T delay is the delay parameter, i.e., the longest delayed forwarding time of a node. It can be set to different values ​​according to the actual situation of the system. In order to avoid causing a large system delay, it is generally set to 10ms-30ms; tanh(·) represents the hyperbolic tangent function; P irepresents the priority of node i; P i max Indicates the maximum priority of node i (ie, the priority when the power is 100%, and its value is set to 1 in this embodiment).

[0036] In this embodiment is a number less than 1, P i The larger the value, the more battery power there is, which means the higher the priority. The higher the priority, the smaller the corresponding value of tanh. i ) will be smaller, so the delayed forwarding time is very small, which satisfies the requirement that the delayed forwarding time of high-priority nodes should be as small as possible.

[0037] In the above formula, when x is 1, T(P i )=0, indicating that this node has the highest forwarding priority among its neighboring nodes, so it should be forwarded immediately and the delay time is set to 0.

[0038] In order to prevent some nodes in the system from acting as relay nodes for a long time, aggravating the power consumption of some nodes, causing one of the nodes to be unable to work due to excessive power consumption, thereby affecting the message transmission of the system, this embodiment proposes a priority selection algorithm based on residual energy, that is, when the node selects the next forwarding node, the remaining power of the node at this time is used as a factor to measure the priority algorithm. This selection method avoids the situation where a certain node always acts as a relay node.

[0039] Specifically, the priority of the node P i The calculation process includes:

[0040]

[0041] Among them, E imax represents the maximum battery capacity of node i; E i Represents the battery capacity of node i at the current moment, expressed as: E i =E imax -E ic , E ic Indicates the battery power consumed by the node when receiving, sending, and forwarding messages. In this embodiment, the node's initial power is assumed to be its maximum battery capacity by default. You can also use a multimeter to measure its initial power. After confirming the node's initial power, calculate its subsequent power based on the number of times the node receives, sends, and forwards data packets during the subsequent process.

[0042] The power consumed by nodes in actual work is mainly concentrated in the following three aspects: the power consumed by sending data packets, the power consumed by receiving data packets, and the power consumed by forwarding data packets. The above three power consumptions are defined as:

[0043] Etx =P tx ·T i ;

[0044] E rx =P rx ·T i ;

[0045] E relay =(P tx +P rx )·T i ;

[0046] Among them, E tx Indicates the power consumed when sending a data packet; P tx represents the transmission power of the node; T i It represents the time required for a node to send and receive a set of data packets, that is, the cycle of Bluetooth receiving broadcast; E rx Indicates the power consumed when receiving a data packet; P rx Represents the received power of the node; E relay It indicates the amount of power consumed by a node when performing one forwarding (one forwarding includes two processes: receiving a data packet and sending a data packet).

[0047] Figure 3 A specific message transmission process in BLE Mesh network is given. Figure 3 In the example, if node 1 sends a broadcast data packet to neighboring nodes within its communication range, the neighboring nodes of node 1 include node 2, node 3, node 4, node 5, node 6, and node 7;

[0048] After receiving the message, each neighbor node first performs a duplication check. After the duplication check conditions are met, the neighbor nodes begin to compete for the right to retransmit. The system calculates the delayed forwarding time based on the remaining energy of each node.

[0049] Assuming that node 3 currently has the largest battery capacity and the calculated delayed forwarding time is the smallest, node 3 forwards first. Since nodes 2 and 4 are within the communication range of node 3, nodes 2 and 4 will receive messages forwarded by node 3 while waiting for the delayed forwarding time. At this time, the duplicate message counter dn in nodes 2 and 4 will increase by 1, that is, the value of the duplicate message counter dn of nodes 2 and 4 will be greater than 1, and nodes 2 and 4 will lose the right to forward;

[0050] Similarly, nodes 5, 6, and 7 are not within the communication range of node 3, so they cannot receive the message forwarded by node 3. If the priority of node 5 is greater than that of node 6, node 6 receives the message forwarded by node 5 with a higher priority, so node 6 also loses the right to forward.

[0051] Since node 7 is neither within the communication range of node 5 nor within the communication range of node 3, node 7 will not receive repeated messages from other nodes, that is, the value of the duplicate message counter dn will not be greater than 1, and node 7 will forward the received message;

[0052] Therefore, within the communication range of node 1, only nodes 3, 5, and 7 will serve as relay nodes in the data packet forwarding process.

[0053] In this embodiment, in order to save resources, the node will perform a repeatability check after receiving the data packet, that is, check whether the message is repeated. The method for detecting whether a message is a duplicate message in the BLE Mesh network is to add the SRC field and SEQ field of the message to the cache array. Each time a message is received, it is compared with the information in the cache array. If the received message already exists in the message cache array, the message is ignored and the value of the duplicate message counter dn is incremented by 1; if the received message is a brand new message, the message is added to the message cache array, and the value of the duplicate message counter dn corresponding to the message is set to 1.

[0054] This embodiment also provides Figure 4 The one minute shown in the figure implements a preferred embodiment of an improved BLE Mesh routing method based on neighbor information of the present invention. In this embodiment, as Figure 4 ,The routing algorithm includes the following steps:

[0055] (1) Node S broadcasts a message to its neighbor node set N(S). After receiving the message, the neighbor node checks its own message cache table to confirm whether the message is a duplicate message. If it is a new message, it jumps to step 2; otherwise, it jumps to step 3.

[0056] (2) Part of the information of this message is recorded in the cache table, and the duplicate message counter dn is set to 1. At this time, the neighboring nodes begin to compete for the forwarding right, calculate the priority corresponding to the node currently serving as the neighboring node, and calculate the delayed forwarding time T based on the priority. At this time, the node waits for T to end, decides whether to forward this message in the end, and jumps to step 4;

[0057] (3) If the message is a duplicate message, delete the message directly, increment the duplicate message counter dn by 1, and jump to step 4;

[0058] (4) Monitor the channel. If a message is received, jump to step 1. If the delay forwarding time is over, jump to step 5.

[0059] (5) Check the value of the duplicate message counter dn. If dn=1, the node should forward the message immediately. If dn>1, it proves that the node has failed in the competition, lost the right to forward the message, and deleted the message from the cache.

[0060] This embodiment describes the process of an improved BLE Mesh routing method based on neighbor information from a message sending end and a receiving end respectively. In the routing process, the process of sending a message by a node as a sending end is as follows: Figure 5 As shown, including:

[0061] (1) Node S, the message sender, starts broadcasting data packet A1;

[0062] (2) Add A1 to the cache of node S;

[0063] (3) Call the BLE broadcast channel to send messages.

[0064] In the routing process, the process of receiving or forwarding messages by the receiving node is as follows: Figure 6 As shown, including:

[0065] (1) Node i receives data packet A1 sent by node s and determines whether node i is the destination node of the message. If so, node i receives the data packet and ends the routing. If node i is not the destination node of the message, proceed to step (2).

[0066] (2) Determine whether the message is cached in the message cache of node i. If so, increment the value of the duplicate message counter dn corresponding to the message by 1. Otherwise, set the value of the duplicate message counter dn corresponding to the message to 1.

[0067] (3) Keep monitoring the channel until the delayed forwarding time ends. If a new message is received during this period, return to step (2) until the delayed forwarding time ends;

[0068] (4) Determine whether the duplicate message counter dn is 1. If it is 1, forward the message; otherwise, discard the data packet and the node loses the right to forward the message.

[0069] The present invention also proposes an improved BLE Mesh routing system based on neighbor information, and the system is used to implement an improved BLE Mesh routing method based on neighbor information. The system includes multiple device nodes (each device node is used for sending and receiving messages), and each device node is provided with a cache table. If a device node broadcasts a data packet to its neighbor node, after the device node receives the data packet, it checks whether there is information about the data packet in the cache table. If not, the value of the duplicate message counter dn in the device node is set to 1. If the current node is not the destination node of the data packet, the current node starts to compete for the qualification of being a relay node. The current node calculates the delayed forwarding time of the corresponding data packet and waits according to the calculated time. If the same data packet is not received again during the waiting process, the node competes successfully and forwards the data packet. Otherwise, the node fails in the competition and discards the data packet.

[0070] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. An improved BLE Mesh routing method based on neighbor information, characterized in that: The specific steps include:

101. A node broadcasts message A. When its neighboring node receives message A, it determines whether the message is in its cache table.

102. If the received message is not in the cache table of the node, cache part A of the message into the cache table of the node, and set the value of the duplicate message counter dn of the node to 1; 103. Calculate the delayed forwarding time of the message for all nodes that receive the message A and whose duplicate message counter dn has a value of 1; 104. Each node waits for the delayed forwarding time before forwarding message A and monitors the channel. If the message is received again within the delayed forwarding time, the value of the duplicate message counter dn is incremented by 1. The message forwarding delay time is expressed as: Among them, T(P i ) is the message forwarding delay time function; T delay is the delay parameter; tanh(·) represents the hyperbolic tangent function; P i Indicates the priority of the node; P imax represents the maximum priority of node i; The priority of the node P i The calculation process includes: Among them, E imax represents the maximum battery capacity of node i; E i represents the battery capacity of node i at the current moment; 105. If the value of the duplicate message counter dn is still 1 after the delayed forwarding time ends, message A is forwarded; if the value of the duplicate message counter dn is greater than 1, the cache of message A is deleted from the cache table, and the qualification for forwarding message A is lost.

2. According to the improved BLE Mesh routing method based on neighbor information in claim 1, it is characterized in that: When a node caches part of the information of a message, it adds the SRC field and the SEQ field in the received message to the cache table.

3. According to the improved BLE Mesh routing method based on neighbor information in claim 1, it is characterized in that: The neighbor nodes of a node are nodes that are within a set distance from the current node.

4. An improved BLE Mesh routing system based on neighbor information, characterized in that: The system includes multiple device nodes, each of which is provided with a cache table. If a device node broadcasts a data packet to its neighboring node, after receiving the data packet, the device node checks whether there is information of the data packet in the cache table. If not, the value of the duplicate message counter dn in the device node is set to 1. If the current node is not the destination node of the data packet, the current node starts to compete for the qualification of being a relay node. The current node calculates the delayed forwarding time of the corresponding data packet and waits according to the calculated time. If the same data packet is not received again during the waiting process, the node competes successfully and forwards the data packet. Otherwise, the node fails in the competition and discards the data packet. The message forwarding delay time is expressed as: Among them, T(P i ) is the message forwarding delay time function; T delay is the delay parameter; tanh(·) represents the hyperbolic tangent function; P i Indicates the priority of the node; P imax Indicates the maximum priority of the node; The priority of the node P i The calculation process includes: Among them, E imax represents the maximum battery capacity of node i; E i Represents the battery capacity of node i at the current moment.

5. The improved BLE Mesh routing system based on neighbor information according to claim 4, characterized in that: When a device node caches a data packet, it adds the SRC field and the SEQ field in the received data packet to the cache table.

6. The improved BLE Mesh routing system based on neighbor information according to claim 4, characterized in that: The neighbor nodes of a node are nodes that are within a set distance from the current node.

Citation Information

Patent Citations

  • Bluetooth Mesh network flooding redundancy optimization method based on neighbor information

    CN113473427A

  • System, device, and method of multi-path wireless communication

    US10673646B1

  • Adaptive message routing for mobile ad hoc networks

    US20100014444A1

  • Inter-domain routing message distribution through wide area broadcast channel

    US8989046B1