Method and system for link quality evaluation of a wireless communication network, wireless communication system and routing method
Patent Information
- Application Number
- CN202610895253.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-22
- Publication Date
- 2026-10-20
- Estimated Expiration
- 2046-06-22
AI Technical Summary
当滑动窗口长度较长时,链路质量统计值的收敛速度较慢,节点难以及时感知链路质量的快速变化,导致路由更新滞后,数据包可能被转发到已经劣化的链路上,造成传输效率下降和时延增加
本申请实施例通过基于加权移动平均的链路质量评估机制,根据历史统计值与瞬时统计值的差值动态调整加权系数,能够在链路质量发生显著变化时快速收敛统计值,提高路由感知速度,同时在链路质量平稳时抑制瞬时抖动,避免路由震荡;通过自适应多路径传输模式选择,根据链路质量统计值与预设阈值的比较结果,在链路质量较好时采用多径负载均衡传输以提升吞吐量,在链路质量较差时采用多径冗余传输以提高数据递交率,在单条路径可用时采用单径传输以保证基本通信,从而在不同网络环境下实现传输效率与可靠性的平衡。
Smart Images

Figure CN122438116B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of wireless communication technology, specifically to a link quality assessment method and system for wireless communication networks, a wireless communication system, and a routing method. Background Technology
[0002] Wireless communication networks are distributed communication networks that do not rely on fixed infrastructure. Each node in the network acts as both a communication terminal and a relay router, transmitting data through multi-hop relay. Because nodes are typically mobile, the network topology changes frequently with node locations. Therefore, wireless communication networks need to rely on proactive routing protocols to dynamically maintain routing information to adapt to these dynamic topology changes.
[0003] The relevant technologies mainly include optimized link-state routing protocols and advanced routing protocols for bat mobile ad hoc networks. These proactive routing protocols enable nodes in the network to discover each other and establish routes by periodically sending route probe messages.
[0004] In the process of implementing the embodiments of this application, at least the following problems were found in the related technology: First, during route awareness, the sending period of route probe messages and the length of the sliding window directly affect the response speed of link quality assessment. When the sliding window length is long, the convergence speed of link quality statistics is slow, making it difficult for nodes to detect rapid changes in link quality in a timely manner. This leads to delayed route updates, and data packets may be forwarded to already degraded links, resulting in decreased transmission efficiency and increased latency. Second, in wireless communication environments, due to uneven network load or limited node communication capabilities, all data often concentrates on a single path for transmission while other available paths remain idle. This prevents the overall network throughput from fully utilizing the resources of multiple paths, and transmission performance is constrained by the bandwidth and reliability of a single path. Furthermore, when handling link quality fluctuations, related technical protocols are prone to misjudging transient, non-substantial link quality jitter as permanent link degradation, thereby triggering unnecessary route switching, causing route oscillations, and further reducing network stability. Summary of the Invention
[0005] This application provides a link quality assessment method and system for wireless communication networks, a wireless communication system, and a routing method.
[0006] A first aspect of this application provides a link quality assessment method for a wireless communication network, comprising: for each neighboring node, obtaining historical link quality statistics and instantaneous link quality statistics of the neighboring node; and calculating the difference between the historical statistics and the instantaneous statistics. The difference is compared with a preset threshold; the weighting coefficients of historical and instantaneous statistical values are dynamically determined based on the comparison results when calculating the link quality statistics, and the updated link quality statistics are calculated based on the determined weighting coefficients.
[0007] In an optional embodiment of this application, the weighting coefficient is dynamically determined based on the comparison result, including: when the difference is greater than a preset threshold, the weight of the historical statistical value is reduced and the weight of the instantaneous statistical value is increased; when the difference is less than or equal to the preset threshold, the weight of the historical statistical value is increased and the weight of the instantaneous statistical value is reduced.
[0008] In an optional embodiment of this application, the link quality assessment method for a wireless communication network further includes: maintaining a sliding window for each neighbor node, the sliding window including a historical value statistics window and an instantaneous value statistics window, the length of the instantaneous value statistics window being a preset instantaneous window length; and recording the maximum sequence number of the routing probe messages received from the neighbor node.
[0009] In an optional embodiment of this application, the link quality assessment method for a wireless communication network further includes: when a routing probe message is received from a neighboring node and its sequence number is greater than the maximum sequence number, the sliding window is moved forward; in the moved sliding window, the historical link quality average value in the historical value statistical window and the instantaneous link quality average value in the instantaneous value statistical window are calculated respectively, and used as the historical statistical value and the instantaneous statistical value respectively.
[0010] In an optional embodiment of this application, the updated link quality statistics are calculated based on the determined weighting coefficients using the following formula: STQ=λ×TQH+(1-λ)×TQE; where STQ is the updated link quality statistics, TQH is the historical statistics, TQE is the instantaneous statistics, λ is the weighting coefficient of the historical statistics, and (1-λ) is the weighting coefficient of the instantaneous statistics.
[0011] In an optional embodiment of this application, the link quality assessment method for a wireless communication network further includes: configuring an instantaneous window length parameter to determine the length of the instantaneous value statistical window; configuring a link quality state metric threshold parameter to compare with the difference to determine whether to adjust the weighting coefficient; and configuring a link quality threshold parameter to compare with the link quality statistics to select a transmission mode.
[0012] A second aspect of this application provides a link quality assessment apparatus for a wireless communication network, including a processor and a memory storing program instructions. The processor is configured to execute the link quality assessment method for a wireless communication network as provided in the first aspect of this application when running the program instructions.
[0013] A third aspect of the present application provides a wireless communication system, including: a wireless communication system body; and a link quality assessment device for a wireless communication network as provided in the second aspect of the present application, which is installed on the wireless communication system body.
[0014] A fourth aspect of this application provides a routing method for a wireless communication network, applied to the wireless communication system provided in the third aspect. The routing method for the wireless communication network includes: obtaining link quality statistics corresponding to at least one communication path leading to a destination node; comparing the link quality statistics of each communication path with a preset link quality threshold; selecting a transmission mode from a set including a multipath load balancing transmission mode, a multipath redundancy transmission mode, and a single-path transmission mode based on the comparison result; and sending data packets to the next-hop node through the corresponding communication path according to the selected transmission mode.
[0015] A fifth aspect of the present application provides a computer-readable storage medium storing program instructions that, when executed, cause a computer to perform a link quality assessment method for a wireless communication network as provided in the first aspect of the present application.
[0016] The link quality assessment method and system, wireless communication system, and routing method for wireless communication networks provided in the embodiments of this application have the following beneficial effects: This application's embodiments employ a link quality assessment mechanism based on weighted moving averages. This mechanism dynamically adjusts the weighting coefficients according to the difference between historical and instantaneous statistical values, enabling rapid convergence of statistical values when link quality changes significantly, thus improving route awareness speed. Simultaneously, it suppresses instantaneous jitter and avoids route oscillations when link quality is stable. Through adaptive multipath transmission mode selection, based on the comparison between link quality statistics and preset thresholds, multipath load balancing transmission is used to improve throughput when link quality is good, multipath redundancy transmission is used to improve data delivery rate when link quality is poor, and single-path transmission is used to ensure basic communication when a single path is available. This achieves a balance between transmission efficiency and reliability in different network environments. Attached Figure Description
[0017] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings: Figure 1 This is a schematic diagram of a sliding window provided in an embodiment of this application; Figure 2 This is a schematic diagram of multipath transmission provided in an embodiment of this application; Figure 3This is a routing protocol technical framework diagram provided in an embodiment of this application; Figure 4 This is a flowchart of a routing protocol provided in an embodiment of this application. Detailed Implementation
[0018] To make the technical solutions and advantages of the embodiments of this application clearer, the exemplary embodiments of this application will be described in further detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not an exhaustive list of all embodiments. It should be noted that, unless otherwise specified, the embodiments and features in the embodiments of this application can be combined with each other.
[0019] This application provides a wireless communication system, including a wireless communication system body; and a link quality assessment device for a wireless communication network, which is installed on the wireless communication system body.
[0020] The wireless communication system body includes multiple communication nodes, each equipped with at least one wireless network communication interface, and uses these interfaces to send and receive route probing messages and data packets with neighboring nodes. The link quality assessment device for the wireless communication network includes a processor and a memory storing program instructions. The processor is configured to execute any of the link quality assessment methods for wireless communication networks provided below when running the program instructions. The wireless communication system also includes a controller electrically connected to the above components, used to control the actions of the components. The controller can execute a computer program stored in the memory to perform functions such as route probing, link quality calculation, transmission mode decision-making, and data packet forwarding.
[0021] Based on the aforementioned link quality assessment apparatus for wireless communication networks, this application provides a link quality assessment method for wireless communication networks, comprising: for each neighboring node, obtaining historical link quality statistics and instantaneous link quality statistics of the neighboring node; calculating the difference between the historical statistics and the instantaneous statistics; comparing the difference with a preset threshold; dynamically determining a weighting coefficient between the historical statistics and the instantaneous statistics when calculating the link quality statistics based on the comparison result; and calculating an updated link quality statistics based on the determined weighting coefficient.
[0022] The link quality assessment method for wireless communication networks provided in this application can adaptively adjust the contribution ratio of historical and instantaneous statistical values according to the actual degree of change in link quality. It can quickly converge to a new state when the link changes abruptly and suppress noise interference when the link is stable, thereby achieving both rapid sensing and anti-jitter. This solves the technical problem that the fixed-weighted moving average method cannot take into account both response speed and stability.
[0023] Optionally, the link quality assessment method for wireless communication networks further includes: periodically sending information of the local node to the network through route probe messages; receiving route probe messages sent by other nodes, parsing and storing the message information, and calculating the initial statistical value of the link quality between the local node and other nodes based on the message information.
[0024] In this embodiment, the step of periodically sending the node's information to the network via route probe messages includes: each node broadcasts a route probe message at fixed time intervals, the route probe message containing the node's identifier, sequence number, current timestamp, and the link quality statistics of each neighbor maintained by the node. The step of receiving route probe messages from other nodes includes: when the node receives a probe message from a neighbor node, recording the arrival time, signal strength, and sequence number of the probe message. The step of calculating the initial link quality statistics between the node and other nodes based on the message information includes: in the first statistical period after the routing protocol starts, directly using the simple arithmetic mean of the link quality of the most recently received INSTANT_WINDOW_SIZE probe messages as the initial statistical value, or directly using the link quality value of the first received probe message as the initial statistical value. Figure 3 As shown, the route detection module is responsible for the periodic sending and receiving of route detection messages, and, in conjunction with the route fast perception calculation module, maintains a local routing table. Data received from the lower-layer protocol stack first undergoes data parsing to determine whether the destination node is the local node. If so, it is passed uplink to the upper-layer protocol stack; otherwise, a route lookup is performed based on the local routing table, and the transmission mode decision process is initiated. Figure 3The diagram also illustrates the upper-layer protocol stack, multi-path load balancing transmission module, single-path transmission module, multi-path redundant transmission module, and the data flow between these modules. Specifically, the upper-layer protocol stack connects to the route query module via uplink and downlink data channels, and connects to the multi-path load balancing transmission module, single-path transmission module, and multi-path redundant transmission module via the route query module and transmission mode decision module. The route detection module connects to the route fast perception calculation module and the local routing table. The route detection module updates its local routing table after processing the received probe packet information through route fast perception calculation, and simultaneously reads information from the local routing table to generate probe packets. Data received from the lower-layer protocol stack first enters the data parsing module. The output of the data parsing module connects to the destination node determination module: if the destination node is the current node, the data is forwarded to the upper-layer protocol stack; if the destination node is not the current node, the data is sent to the route query module. The route query module reads path information from the local routing table, and its output connects to the transmission mode decision module. The transmission mode decision module connects to the multipath load balancing transmission module, the single-path transmission module, and the multipath redundant transmission module respectively according to the link quality status. The output of these three transmission modules are all connected to the lower-layer protocol stack.
[0025] In this way, through periodic probe message exchange, each node in the network can gradually establish a set of neighboring nodes and the corresponding initial link quality estimate, providing the necessary historical and instantaneous data foundation for subsequent weighted moving average calculation, enabling the routing protocol to automatically complete the construction of the initial routing table without pre-configuring link quality information.
[0026] Optionally, dynamically determining the weighting coefficient based on the comparison results includes: when the difference is greater than a preset threshold, reducing the weight of historical statistical values and increasing the weight of instantaneous statistical values; when the difference is less than or equal to a preset threshold, increasing the weight of historical statistical values and decreasing the weight of instantaneous statistical values.
[0027] In this embodiment, the steps of reducing the weight of historical statistical values and increasing the weight of instantaneous statistical values include: setting the weighting coefficient λ of historical statistical values to a first value, and setting the weighting coefficient (1-λ) of instantaneous statistical values to a second value, wherein the first value is less than the second value, and the sum of the first value and the second value is equal to one. For example, when the difference exceeds a threshold, λ can be set to 0.3, and (1-λ) to 0.7. The steps of increasing the weight of historical statistical values and reducing the weight of instantaneous statistical values include: setting λ to a third value, and setting (1-λ) to a fourth value, wherein the third value is greater than the fourth value, for example, λ = 0.8, and (1-λ) = 0.2. The adjustment of the weighting coefficients can be continuously variable, that is, the λ value is calculated linearly according to the ratio of the difference to the threshold; the larger the difference, the smaller λ is, and the smaller the difference, the larger λ is.
[0028] In this way, by dynamically adjusting the weighting coefficients, the link quality statistics can automatically adapt to the rate of change in network status: when the link quality changes drastically, the statistics mainly rely on instantaneous values to quickly follow the actual link status; when the link quality fluctuates slowly, the statistics mainly rely on historical values to filter out high-frequency noise and avoid frequent oscillations in the routing table caused by brief interference pulses.
[0029] Optionally, the link quality assessment method for wireless communication networks further includes: maintaining a sliding window for each neighbor node, the sliding window including a historical value statistics window and an instantaneous value statistics window, the length of the instantaneous value statistics window being a preset instantaneous window length; and recording the maximum sequence number of the routing probe messages received from the neighbor node.
[0030] In this embodiment, the total length of the sliding window is fixed at W, and the length of the instantaneous value statistics window is fixed at L, where L is less than W, and a typical value of L is 10% to 30% of W. Figure 1 As shown, the sliding window (the original sliding window in the figure) is logically divided into two continuous intervals: the historical value statistics window extends from the start of the window to the (WL)th sample, and the instantaneous value statistics window extends from the (W-L+1)th sample to the end of the window. The average value of the samples within the historical value statistics window is used as the historical statistical value, and the average value of the samples within the instantaneous value statistics window is used as the instantaneous statistical value. The historical statistical value reflects the baseline level of link quality over a longer period, while the instantaneous statistical value reflects the immediate state of link quality over the most recent short period. The steps for recording the maximum sequence number of routing probe packets received from neighboring nodes include: for each neighboring node, the local node maintains a maximum sequence number SEQ_MAX(N), which is initially zero; whenever a probe packet is received from a neighboring node and the sequence number of the probe packet is greater than the currently recorded maximum sequence number SEQ_MAX(N), the maximum sequence number SEQ_MAX(N) is updated to the sequence number of the probe packet.
[0031] In this way, by maintaining an independent sliding window for each neighbor node and dividing the sliding window into historical and instantaneous statistical areas, nodes can obtain both long-term trends and short-term dynamics of link quality with relatively low computational overhead. The maximum sequence number recording mechanism allows nodes to accurately determine whether newly arrived packets are ordered packets, thereby deciding whether to move the sliding window and ensuring the temporal order and continuity of samples within the sliding window.
[0032] Optionally, the link quality assessment method for wireless communication networks further includes: when a routing probe message is received from a neighboring node and the sequence number of the routing probe message is greater than the maximum sequence number, the sliding window is moved forward; in the moved sliding window, the historical link quality average value in the historical value statistical window and the instantaneous link quality average value in the instantaneous value statistical window are calculated respectively, and used as historical statistical values and instantaneous statistical values respectively.
[0033] In this embodiment, the step of moving the sliding window forward includes: removing the oldest packet sample from the window and inserting the newly received packet sample at the end of the window. After the movement, the total number of samples in the window remains unchanged. The steps of calculating the historical link quality average in the historical value statistical window and the instantaneous link quality average in the instantaneous value statistical window include: performing an arithmetic mean of the link quality values carried or calculated by all packets in the historical value statistical window to obtain the historical statistical value TQH; and performing an arithmetic mean of the link quality values corresponding to all packets in the instantaneous value statistical window to obtain the instantaneous statistical value TQE. To improve computational efficiency, an incremental update algorithm can be used: each time the window moves, the contribution value of the removed sample is subtracted and the contribution value of the newly added sample is added, thereby avoiding retracing the entire window each time.
[0034] In this way, through the sliding window mechanism, nodes can continuously update historical and instantaneous statistics of link quality, ensuring that the statistics are always based on valid samples from the most recent period. Fixing the instantaneous value statistics window at the end of the window allows the instantaneous values to most sensitively reflect changes in link quality over a period of L message time backwards from the current moment, while historical values reflect average performance over a longer time scale. Using both together provides reasonable input parameters for the weighted moving average.
[0035] Optionally, the updated link quality statistics are calculated based on the determined weighting coefficients using the following formula: STQ=λ×TQH+(1-λ)×TQE; where STQ is the updated link quality statistics, TQH is the historical statistics, TQE is the instantaneous statistics, λ is the weighting coefficient of the historical statistics, and (1-λ) is the weighting coefficient of the instantaneous statistics.
[0036] In this embodiment, λ and (1-λ) in the formula satisfy λ plus (1-λ) equals one, and the value of λ is greater than or equal to zero and less than or equal to one. When λ is one, STQ is exactly equal to TQH, at which point the instantaneous statistical value is completely ignored, and the statistical value has the strongest anti-jitter capability but the slowest response speed; when λ is zero, STQ is exactly equal to TQE, at which point the statistical value depends entirely on the instantaneous value, and the response speed is the fastest but the most susceptible to noise interference. In practical applications, λ is usually taken between 0.5 and 0.9 to ensure that the statistical value has a certain stability and can respond to real changes. This application achieves adaptive change of λ by dynamically adjusting the specific value of λ according to the difference. For example, when the difference is greater than the threshold, λ is set to 0.3; when the difference is less than or equal to the threshold, λ is set to 0.7. A continuous function can also be used, such as λ = 0.5 - 0.4 * tanh(difference / threshold), so that λ changes smoothly.
[0037] Thus, by employing the aforementioned weighted moving average formula, historical and instantaneous information can be fused in a simple linear combination. By dynamically adjusting λ, the formula can automatically change the fusion ratio under different network conditions, thereby enabling the link quality statistics to achieve both fast tracking and stable estimation, providing accurate and stable input for routing decisions.
[0038] Optionally, the link quality assessment method for wireless communication networks further includes: configuring an instantaneous window length parameter to determine the length of the instantaneous value statistical window; configuring a link quality status metric threshold parameter to compare with the difference to determine whether to adjust the weighting coefficient; and configuring a link quality threshold parameter to compare with the link quality statistics to select a transmission mode.
[0039] In this embodiment, the instantaneous window length parameter is denoted as INSTANT_WINDOW_SIZE. This parameter determines how many recent samples are used in the sliding window to calculate the instantaneous average. The value of the instantaneous window length parameter is directly related to the network's expected response time. For example, when the expected response time is three probe cycles, the instantaneous window length parameter can be set to three. The link quality status metric threshold parameter is denoted as TQ_DIFF. This is a dimensionless threshold used to compare the absolute value of the historical statistic minus the instantaneous statistic. When the absolute value exceeds TQ_DIFF, the link quality is considered to have changed significantly, and the weighting coefficient needs to be adjusted. The link quality threshold parameter is denoted as TQ_THRESHOLD. This parameter is used to determine whether a path is suitable for data transmission. Paths with link quality statistics greater than TQ_THRESHOLD are considered qualified paths; otherwise, they are considered to have poor quality. These three parameters can be loaded through a configuration file during protocol initialization or adjusted online at runtime via management commands.
[0040] By introducing three configurable parameters, this routing method can flexibly adapt to different wireless communication network environments, such as high-mobility scenarios, low-rate sensor network scenarios, or high-throughput video transmission scenarios. Operations personnel can adjust the parameters according to actual needs without modifying the core protocol algorithm, thus improving the protocol's versatility and deployability.
[0041] Optionally, the instantaneous window length parameter and the link quality status metric threshold parameter are dynamically adjusted according to the network environment of the wireless communication network: the link quality status metric threshold parameter is increased in scenarios with drastic network changes, and decreased in scenarios with gradual network changes.
[0042] In this application embodiment, scenarios with drastic network changes include those involving high-speed node movement, rapid channel fading, or frequent occurrences of sudden interference sources. In such scenarios, the instantaneous fluctuations in link quality statistics are large. If a small TQ_DIFF threshold is used, the difference can easily exceed the threshold, leading to frequent changes in the weighting coefficients and consequently causing jitter in routing statistics. Therefore, increasing the TQ_DIFF threshold, for example from the default value of 0.1 times the maximum quality value to 0.2 times the maximum quality value, ensures that only truly continuous changes trigger weighting coefficient adjustments. Scenarios with gradual network changes include those involving stationary or slow-moving nodes and relatively stable channel conditions. In such scenarios, changes in link quality are typically slow drifts. Using a small TQ_DIFF threshold, such as 0.05 times the maximum quality value, allows the system to remain sensitive to subtle changes and track long-term trends in link quality in a timely manner. The aforementioned dynamic adjustments can be automatically executed by nodes based on their own statistical link quality variance or the frequency of neighbor node replacements, or the configuration can be uniformly broadcast by the central node in the network.
[0043] In this way, by adaptively adjusting the TQ_DIFF threshold according to the severity of the network environment, this method can prevent false triggering with a larger dead zone in dynamic networks and maintain sensitivity with a smaller dead zone in static networks, thereby achieving the best link quality assessment performance in different scenarios.
[0044] Optionally, the link quality assessment method for wireless communication networks may further include: when the difference between the updated link quality statistics and the previous link quality statistics exceeds a preset route update threshold, triggering a route update mechanism to recalculate the optimal path to each destination node.
[0045] In this embodiment, the route update threshold is a parameter independent of TQ_DIFF, denoted as ROUTE_UPDATE_DIFF. The route update threshold is used to determine whether the change in link quality statistics is large enough to affect route selection. For example, if the link quality statistics drop from 0.9 to 0.6, a change of 0.3, exceeding ROUTE_UPDATE_DIFF (e.g., 0.1), a route update is triggered. The route update mechanism includes: the node re-running the shortest path first algorithm, mapping the link quality statistics to link costs (e.g., cost = 1 / STQ or cost = maximum quality value minus STQ), and then calculating the optimal next hop to reach each known destination node. After triggering a route update, the node can either immediately update its local routing table or wait for a short timer to collect other update events that may arrive simultaneously, thereby merging the calculations to reduce overhead.
[0046] In this way, by setting a route update threshold, frequent route recalculation is avoided due to minor fluctuations in link quality statistics, saving node computing resources and network control message overhead. At the same time, once a substantial change occurs in link quality that is sufficient to alter route selection, the system can respond promptly, ensuring that data packets are always forwarded along the current optimal path.
[0047] Optionally, the link quality assessment method for a wireless communication network further includes: receiving a data packet to be forwarded; querying a routing table based on the destination node information of the data packet to obtain at least one communication path to the destination node and the link quality statistics corresponding to each communication path; comparing the link quality statistics of each communication path with a preset link quality threshold; selecting a transmission mode from a set including multipath load balancing transmission mode, multipath redundancy transmission mode, and single-path transmission mode based on the comparison result; and sending the data packet to the next-hop node through the corresponding communication path according to the selected transmission mode.
[0048] In this embodiment, the step of receiving the data packet to be forwarded can be received from the upper-layer protocol stack or from the lower-layer network interface. Each route entry in the routing table includes at least the destination node address, the next-hop node address, the outgoing interface identifier, and the current link quality statistics for that path. The step of comparing the link quality statistics for each communication path with a preset link quality threshold includes: for each path, determining whether STQ is greater than TQ_THRESHOLD. Figure 4As shown, this flowchart describes the complete process of a node processing data packets in the form of decision branches. After the process begins, the node determines whether the data source is from the lower layer or the higher layer. For data received from the lower layer, the node first obtains the destination node information of the data packet, and then determines whether the destination node is itself. If it is, the node receives the data locally and ends the process; otherwise, it continues to execute the subsequent routing query steps. For data received from the higher layer, the node directly obtains the destination node information of the data packet, then queries the routing table to obtain all paths that can reach the destination node, and determines whether there are multiple communication paths. If there are multiple communication paths, the node obtains the link quality statistics of each path (link quality values in the figure). Subsequently, the node determines whether the link quality statistics of all paths are less than the preset link quality threshold (threshold TQ in the figure). If so, it selects the multi-path redundancy transmission mode; otherwise, it selects the multi-path load balancing transmission mode. In the case of using the multi-path load balancing transmission mode, it also determines whether there is a suitable communication path. If there is, it selects any suitable communication path for transmission; if there is no suitable path, it falls back to the single-path transmission mode. When sending data packets according to the selected transmission mode, for multipath load balancing transmission mode, data packets are distributed in turn to different suitable paths; for multipath redundancy transmission mode, data packets are copied and sent through multiple paths; for single-path transmission mode, data packets are sent only through the optimal qualified path.
[0049] In this way, our method directly applies the results of link quality assessment to the transmission mode decision during the data forwarding phase, forming a closed-loop adaptive routing framework. Nodes automatically select the most suitable transmission strategy based on the real-time monitored link quality, making full use of multipath bandwidth when network conditions are good, and ensuring reliability through redundancy when network conditions are poor, thereby achieving a dynamic balance between throughput and reliability.
[0050] Optionally, receiving the data packet to be forwarded includes: receiving data packets from the underlying network interface or receiving data packets from the higher-level protocol stack; parsing the destination node information of the data packet and determining whether the destination node is the current node; if the destination node is the current node, then delivering the data packet to the higher-level protocol stack; if the destination node is not the current node, then entering the forwarding process and performing the step of querying the routing table.
[0051] In this embodiment, receiving data packets from the underlying network interface means that the network card driver delivers the received data packets to the network layer protocol processing function. Receiving data packets from the higher-layer protocol stack means that the upper-layer application calls the sending interface through a socket to pass the data packets to the routing protocol module. Parsing the destination node information of the data packet includes reading the destination IP address or destination MAC address field in the data packet header. Determining whether the destination node is this node is achieved by comparing the parsed destination address with the addresses of all network interfaces of this node. If they match, the network layer header is stripped and the payload is delivered to the transport layer or application layer; if they do not match, the routing lookup function is called to find the forwarding interface and the next-hop address. Figure 3 As shown, the data received from the lower-layer protocol stack first undergoes data parsing to determine whether the destination node is the local node. If it is, the data is forwarded to the upper-layer protocol stack; otherwise, a route lookup is performed based on the local routing table, and the transmission mode decision process is initiated.
[0052] In this way, the node acts as both a terminal and a router. When the destination of a data packet is the node itself, the packet is correctly forwarded; when the packet needs to be forwarded, the node initiates a complete routing query and transmission mode selection process. This design makes this method suitable for both pure end-to-end communication and multi-hop relay forwarding, conforming to the fundamental characteristic of every node in a wireless communication network being a router.
[0053] Based on the structure of the wireless communication system described above, this application also provides a routing method for a wireless communication network, comprising: obtaining link quality statistics for at least one communication path leading to a destination node; comparing the link quality statistics for each communication path with a preset link quality threshold; selecting a transmission mode from a set including multipath load balancing transmission mode, multipath redundancy transmission mode, and single-path transmission mode according to the comparison result; and sending data packets to the next-hop node through the corresponding communication path according to the selected transmission mode.
[0054] In this embodiment, the node queries its local routing table to obtain all route entries that can reach the specified destination node. Each route entry contains a next-hop node and an outgoing interface, which together define a communication path. The node reads the currently stored link quality statistic (STQ) for each path from the routing table. The STQ of each path is compared with the TQ_THRESHOLD value, and the number of paths greater than or equal to the threshold is recorded. The rules for selecting the transmission mode based on the comparison results are the same as described above. Figure 2As shown in the diagram, this multipath transmission schematic depicts a wireless communication network topology comprising five nodes N1, N2, N3, N4, and N5. Node N1 has a direct communication link with node N2. Node N2 also has direct communication links with both nodes N3 and N4. Nodes N3 and N4 each have direct communication links with node N5. Two communication paths from node N2 to node N5 are marked in the diagram. The first path, L1, passes through nodes N2 and N3 sequentially to reach node N5, while the second path, L2, passes through nodes N2 and N4 sequentially to reach node N5. When node N2 sends a data packet to node N5, it can adaptively select single-path transmission, multipath load-balanced transmission, or multipath redundancy transmission based on a comparison of the link quality statistics of each of the two paths with a preset threshold. Sending data packets according to the selected transmission mode includes executing the specific transmission logic for that mode.
[0055] The routing method for wireless communication networks provided in this application allows nodes to automatically select the optimal data transmission strategy based on the perceived link quality of each path without manual intervention. This method enables wireless communication networks to simultaneously achieve both high throughput and high reliability, overcoming the limitation of traditional single-path protocols that can only optimize one.
[0056] Optionally, the multipath load balancing transmission mode includes: alternately using different communication paths to send data packets belonging to the same data stream.
[0057] In this embodiment, alternating the use of different communication paths refers to the process where, for a continuous sequence of data packets from a source node to a destination node, the node sends the packets in turn along different qualified paths according to a certain scheduling algorithm, avoiding multiple consecutive data packets from taking the same path. Data packets belonging to the same data stream refer to data packets with the same 5-tuple (source address, destination address, source port, destination port, protocol type). The specific implementation of alternating path use can be based on a round-robin algorithm: maintaining a pointer to the currently used path, moving the pointer to the next qualified path after each transmission, and returning to the first qualified path when the pointer reaches the end. Alternatively, it can be based on weighted round-robin: each path is assigned a different weight based on its link quality statistics, with higher-quality paths being selected more frequently. Figure 2 As shown, node N2 can alternately send multiple data packets of the same data stream to node N5 through the first path L1 and the second path L2. The first packet goes through the first path L1, the second packet goes through the second path L2, the third packet goes through the first path L1 again, and so on.
[0058] In this way, by alternating different paths, the multipath load balancing transmission mode can evenly distribute the data flow across multiple links, thereby aggregating the bandwidth resources of multiple paths, reducing the probability of congestion on a single link, reducing end-to-end transmission latency, and because multiple paths transmit simultaneously, even if a path experiences brief packet loss, the data packets on other paths can still arrive normally, which improves the robustness of transmission to a certain extent.
[0059] Optionally, alternating the use of different communication paths to send data packets belonging to the same data stream includes: obtaining the first sending interface and the corresponding first next-hop node used in the last data packet transmission; when sending the current data packet, querying the routing table for paths that meet the following conditions: the next-hop node is different from the first next-hop node, the sending interface is different from the first sending interface, and the link quality statistics value is greater than a preset link quality threshold; if there is a path that meets the conditions, then select one of the paths to send the current data packet, and record the sending interface and next-hop node used this time.
[0060] In this embodiment, the first sending interface refers to the network interface used when the data stream packet was last sent, such as the wireless network card wlan0 or wlan1. The first next-hop node refers to the network address of the next-hop neighbor node selected during the last forwarding. When querying the routing table for a path that meets the conditions, the conditions require that both the next-hop node and the sending interface be different to ensure that the new path is not only logically different but also as independent as possible in terms of physical link and wireless channel, avoiding resource contention caused by two paths actually sharing the same wireless channel or the same forwarding node. If a path that meets the conditions exists, the one with the highest link quality statistic can be selected, or a path can be randomly selected. After the transmission is completed, the actual sending interface and next-hop node used this time are stored in the context associated with the data stream for use in the next transmission.
[0061] By requiring that the sending interface and the next-hop node be different, this method ensures that load balancing occurs on multiple physically independent paths, minimizing the reduction in load balancing performance caused by interference between paths. Simultaneously, the mechanism of recording the previous transmission information allows the alternation strategy to continue, guaranteeing the uniformity of load distribution during long-term transmission.
[0062] Optionally, if no path meets the conditions, the path with the best link quality statistics is selected for single-path transmission.
[0063] In this embodiment, the absence of a path that meets the conditions may be caused by the following situations: only one path in the routing table has a link quality statistic greater than TQ_THRESHOLD; or although there are multiple qualified paths, the next-hop node of all qualified paths is the same as the first next-hop node, or the sending interface of all qualified paths is the same as the first sending interface. In this case, effective multipath load balancing cannot be achieved because selecting any other path cannot meet the requirements of interface or next-hop differentiation. At this time, the node falls back to single-path transmission mode and selects the path with the highest link quality statistic among all qualified paths for transmission. If there is no qualified path (i.e., the STQ of all paths is less than or equal to TQ_THRESHOLD), then based on the overall network quality judgment, it may switch to multipath redundancy transmission mode or directly adopt single-path transmission of the optimal path.
[0064] In this way, the fallback mechanism ensures that data packets are not dropped or forced to use poor-quality paths when load balancing conditions are not met. Nodes always select the currently optimal and qualified path for transmission, thus maintaining transmission reliability and efficiency even when load balancing cannot be achieved.
[0065] Optionally, the multipath redundancy transmission mode includes: copying the data packet to be sent and sending the original data packet and the copy data packet through different communication paths.
[0066] In this embodiment, copying the data packet to be sent refers to copying the complete content of the data packet into memory one or more copies, each copy having its own independent memory space. Sending the original data packet and the copy data packet through different communication paths means: selecting two or more different paths on the next-hop node or outgoing interface, sending the original data packet through one of these paths, and sending one or more copy data packets through the other paths respectively. Figure 4 As shown, when the link quality statistics (link quality values in the figure) of all paths are less than the preset link quality threshold (threshold TQ in the figure), the node enters multipath redundancy transmission mode. When the receiving node receives multiple identical copies, it can identify duplicate packets based on the sequence number field in the packet header, and only deliver the first arriving copy to the higher layer, discarding subsequent arriving duplicate packets. If the receiving end implements network coding, it can also combine and decode multiple encoded packets.
[0067] In this way, multipath redundancy transmission mode trades spatial redundancy for reliability. When a data packet is lost on one path due to interference, congestion, or node failure, the copy on another path still has a high probability of arriving successfully, thus significantly improving the end-to-end data delivery rate. It is especially suitable for scenarios that are extremely sensitive to packet loss, such as industrial control and emergency communication.
[0068] Optionally, sending the original data packet and the copy data packet through different communication paths includes: obtaining the first next-hop node for sending the original data packet by querying the routing table; finding the communication path corresponding to the second next-hop node that is different from the first next-hop node and has the best link quality statistics, and sending the copy data packet through the communication path.
[0069] In this embodiment, when the first next-hop node for sending the original data packet is obtained by querying the routing table, the path with the highest link quality statistics among all paths can be selected as the path for the original data packet, because this path has the highest single-path success probability. Then, a path with a different next-hop node from the first next-hop node is found among the remaining paths, and the path with the best link quality statistics is selected as the sending path for the replica data packet. If there are multiple paths that satisfy different conditions for the next-hop node, multiple replicas can be generated, and each replica is sent through a different next-hop node, thereby constructing N-fold redundant transmission. For example, when there are three paths and the next-hop nodes of the three paths are all different and their quality is below the threshold, the data packet can be copied into two copies and sent through two or all three paths respectively.
[0070] In this way, by forcing the next-hop node of the replica data packet to be different from that of the original data packet, this method ensures that the original packet and the replica packet enter different forwarding branches at the beginning of the routing stage, and the links they pass through are also likely to be different. This effectively avoids the situation where two replicas are lost at the same time due to a common failure point (such as the failure of an intermediate node), and maximizes the benefits of redundant transmission.
[0071] Optionally, before copying the data packet to be sent, the process further includes: performing network encoding on the data packet to generate multiple encoded data packets; copying the data packet to be sent includes copying multiple encoded data packets; sending the original data packet and the copy data packet through different communication paths includes sending different encoded data packets through different communication paths respectively.
[0072] In this embodiment, the network coding process employs random linear network coding: the original data packet is divided into K equal-length data blocks. A set of coefficients is randomly selected on the Galois field GF(2^8), and the K data blocks are linearly combined to generate an encoded data packet. This process is repeated to generate M encoded data packets, where M is greater than K. Each encoded data packet carries the coefficient vector used in this linear combination. Copying the data packet to be sent, including copying multiple encoded data packets, means that the content of the original data packet is not directly copied, but multiple encoded packets that are different from each other are generated. Sending different encoded data packets through different communication paths means that different encoded packets are assigned to different paths for transmission, with each path sending one or a few encoded packets. After collecting at least K linearly independent encoded packets, the receiving end can decode the original K data blocks by solving a system of linear equations.
[0073] Thus, redundant transmission combined with network coding is more efficient than simple copying. When using copying, if a copy is lost along a path, the receiving end cannot recover it; however, with network coding, as long as the total number of received encoded packets reaches a threshold, the original data can be recovered regardless of which specific encoded packets were lost. Furthermore, network coding avoids the need for the receiving end to identify and discard duplicate copies, reducing the processing complexity at the receiving end.
[0074] Optionally, the single-path transmission mode includes: querying the routing table to obtain the communication path with the best link quality statistics to the destination node, and sending the data packet to the corresponding next-hop node through that path.
[0075] In this embodiment, querying the routing table to obtain the optimal path means: traversing all routing entries in the routing table that lead to the destination node, comparing the Link Quality Statistic (STQ) stored in each entry, and selecting the entry with the highest STQ. The next-hop node and outgoing interface corresponding to this entry are the optimal path. If multiple entries have the same STQ, any one of them can be selected, or the entry with fewer hops can be chosen. After determining the optimal path, the node directly sends the data packet from the corresponding outgoing interface to the selected next-hop node, without duplication or multiplexing. Figure 4 As shown, when a suitable path exists and multipath load balancing or redundancy conditions are not met, the node performs single-path transmission.
[0076] Thus, the single-path transmission mode is simple to implement and has minimal processing overhead. Single-path transmission is suitable for scenarios where there is at least one viable path in the network, while other paths are of poor quality and not worth using. It is also suitable for scenarios where node processing capabilities are limited and cannot support load balancing or redundant transmission. Single-path transmission is the fundamental mode among the three transmission modes in this application, ensuring that data packets have a path to follow under all circumstances.
[0077] Optionally, the routing method for the wireless communication network further includes: detecting the status information of multiple network communication interfaces equipped on this node, including interface bandwidth, current load, and signal strength; and further adjusting the preset link quality threshold or link quality statistics in conjunction with the status information of the network communication interfaces when comparing link quality statistics with preset link quality thresholds.
[0078] In this embodiment, interface bandwidth refers to the maximum data transmission rate theoretically supported by the network interface. Current load can be measured by the current length of the interface's transmit queue, the average queuing delay of the queue, or the channel occupancy rate. Signal strength is measured by received signal strength indication or signal-to-noise ratio. Adjusting the preset link quality threshold or link quality statistics based on the network communication interface's status information includes: if the current load of an interface exceeds a preset load threshold (e.g., the transmit queue exceeds 80% of its total length), temporarily multiplying the link quality statistics of all paths corresponding to that interface by an attenuation factor less than one, or temporarily increasing TQ_THRESHOLD by an offset, thus reducing the priority of these paths during mode selection. Similarly, if the signal strength is too low, adjustments can be made accordingly.
[0079] By introducing interface status information, this method can detect the real-time congestion status of the physical layer and the link layer, avoiding sending data packets to paths where the interface is already congested even though the link quality statistics are high. This achieves cross-layer resource optimization and further improves the effectiveness of load balancing and the overall network throughput.
[0080] Optionally, the routing method of the wireless communication network further includes: when the difference between the updated link quality statistics and the link quality statistics before the update exceeds a preset routing update threshold, a routing update mechanism is triggered to recalculate the optimal path to each destination node.
[0081] In this embodiment, the above steps are functionally identical to the corresponding steps described earlier. They can be used in conjunction with the link quality awareness part of the first routing method or the multipath transmission mode selection part of the second routing method. Specifically, after each update of the link quality statistics, the node calculates the absolute value of the difference between the current STQ and the previous STQ. If this absolute value is greater than ROUTE_UPDATE_DIFF, a route update flag is set. The node can recalculate the routing table uniformly when the next route probe cycle arrives, or perform recalculation immediately. The result of the recalculation will affect the path selection of subsequent data packets.
[0082] By incorporating the route update mechanism into both routing methods, this application ensures that regardless of which method is used as the primary method, the routing table can respond promptly to substantial changes in link quality, thereby maintaining the topological convergence and optimal data forwarding of the entire network.
[0083] The following provides a complete routing protocol operation flow from network initialization to the end of data transmission and reception.
[0084] Step one: Deploy and start the communication equipment to complete the routing protocol initialization. Specifically, after each node in the network powers on, the processor loads the routing protocol program, configuring the instantaneous window length parameter INSTANT_WINDOW_SIZE, the link quality state metric threshold parameter TQ_DIFF, the link quality threshold parameter TQ_THRESHOLD, and the route update threshold ROUTE_UPDATE_DIFF. Each node initializes its local routing table, sets it to empty, and starts a timer for periodically sending route probe packets.
[0085] Step 2, Route Establishment Process. This process includes two sub-steps. Sub-step 2a: Each node periodically sends its own information to the network via route probe messages. These messages include the node's identifier, sequence number, current timestamp, and the link quality statistics maintained by the node for each neighbor. Sub-step 2b: When a node receives a route probe message from another node, it parses the information in the message, stores it in its local neighbor information table, and calculates the link quality statistics between itself and its neighbors using a weighted moving average method, based on the sequence number and received signal strength information in the message. The specific calculation process includes: for each neighbor node, obtaining historical and instantaneous link quality statistics, calculating the difference between them, comparing the difference with a preset threshold (TQ_DIFF), dynamically adjusting the weighting coefficient based on the comparison result, and then calculating the updated link quality statistics based on the weighting coefficient. The node stores the calculated link quality statistics as the metric for that path in its routing table. If the difference between the updated link quality statistics and the previous statistics exceeds the routing update threshold ROUTE_UPDATE_DIFF, the routing update mechanism is triggered to recalculate the optimal path to each destination node.
[0086] Step 3, Data Transmission Process. When a node receives a data packet to be sent from a higher-level protocol stack (e.g., application layer or transport layer), the node parses the destination node information of the data packet and queries its local routing table based on the destination node information. If no path to the destination node exists in the routing table, the data packet is discarded and an error is reported to the upper layer. If at least one path exists, the node obtains the link quality statistics for each path and makes forwarding decisions according to the multi-path adaptive selection method. Specifically, the node compares the link quality statistics of each communication path with a preset link quality threshold TQ_THRESHOLD. If the link quality statistics of at least two paths are greater than TQ_THRESHOLD, the multi-path load balancing transmission mode is selected, and the data packet is alternately sent to different qualified paths according to the aforementioned detailed steps (obtaining the previous transmission information, obtaining the appropriate next hop and sending it, updating the transmission sending interface). If the link quality statistics of all paths are less than TQ_THRESHOLD, the multi-path redundancy transmission mode is selected, and copies of the data packet are sent through multiple paths according to the aforementioned detailed steps (local copying of data packets, sending the original data packet, sending the copy data packet). If only one path has a link quality statistic greater than TQ_THRESHOLD, then single-path transmission mode is selected, and data packets are sent directly through this optimal path. After completing the transmission mode selection and data packet transmission, the node passes the data packets to the underlying network interface, where the underlying protocol stack performs the actual transmission.
[0087] Step four, data reception process. When a node receives a data packet from the underlying network interface, it first parses the destination node information in the packet. If the destination node is this node, the payload of the data packet is delivered to the higher-level protocol stack (such as the transport layer or application layer) to complete data reception. If the destination node is not this node, the forwarding process begins: the node queries its local routing table based on the destination node information and uses the same multi-path adaptive selection method as the data sending process (i.e., comparing the link quality statistics of each path with TQ_THRESHOLD and selecting multi-path load balancing, multi-path redundancy, or single-path transmission mode) to send the data packet to the next-hop node through the selected communication path. If there is no path to the destination node in the routing table, the data packet is discarded.
[0088] Through the above overall operation process, the routing method provided in this application organically combines the link quality fast perception algorithm with the multi-path adaptive transmission mechanism. During the route establishment phase, the node uses the weighted moving average algorithm to monitor the changes in link quality in real time. During the data sending and forwarding phase, the node dynamically selects the optimal transmission mode based on the link quality. Thus, while ensuring the routing convergence speed and stability, the network throughput and reliability are significantly improved.
[0089] This application provides a computer-readable storage medium storing program instructions that, when executed, cause a computer to perform the aforementioned link quality assessment method and / or routing method for a wireless communication network.
[0090] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.
Claims
1. A method for evaluating link quality in a wireless communication network, characterized in that, include: For each neighboring node, obtain the historical and instantaneous link quality statistics. For each neighboring node, maintain a sliding window consisting of a historical statistics window and an instantaneous statistics window. The sliding window is divided into two continuous intervals: the historical statistics window extends from the start of the window to the (WL)th sample, and the instantaneous statistics window extends from the (W-L+1)th sample to the end of the window. The average value of the samples within the historical statistics window is used as the historical statistical value, and the average value of the samples within the instantaneous statistics window is used as the instantaneous statistical value. Calculate the difference between historical statistical values and instantaneous statistical values, where the difference is the absolute value of the difference between the historical statistical values and the instantaneous statistical values; Configure a link quality status metric threshold parameter, which is used to compare with the difference to determine whether to adjust the weighting coefficient; when the difference exceeds the link quality status metric threshold parameter, it is considered that the link quality has changed significantly and the weighting coefficient needs to be adjusted. Calculate the ratio of the difference to the preset weight adjustment threshold; The weighting coefficients for historical and instantaneous statistical values in calculating link quality statistics are determined based on the ratio, wherein the weighting coefficient for historical statistical values is λ, the weighting coefficient for instantaneous statistical values is (1-λ), and λ = 0.5-0.4×tanh(the difference / the preset weight adjustment threshold), so that λ continuously decreases as the ratio of the difference to the preset weight adjustment threshold increases; The updated link quality statistics are calculated based on the determined weighting coefficients. When the absolute value of the difference between the updated link quality statistics and the link quality statistics before the update exceeds the preset route update threshold, the route update mechanism is triggered to recalculate the optimal path to each destination node.
2. The method according to claim 1, characterized in that, Also includes: Record the maximum sequence number of the route probe messages received from neighboring nodes.
3. The method according to claim 2, characterized in that, Also includes: When a route probe message is received from a neighboring node and its sequence number is greater than the maximum sequence number, the sliding window is moved forward; In the moved sliding window, the historical link quality average value in the historical value statistics window and the instantaneous link quality average value in the instantaneous value statistics window are calculated respectively, and used as historical statistical values and instantaneous statistical values respectively.
4. The method according to claim 1, characterized in that, The updated link quality statistics are calculated based on the determined weighting coefficients using the following formula: STQ=λ×TQH+(1-λ)×TQE; Where STQ is the updated link quality statistic, TQH is the historical statistic, TQE is the instantaneous statistic, λ is the weighting coefficient of the historical statistic, and (1-λ) is the weighting coefficient of the instantaneous statistic.
5. The method according to claim 1, characterized in that, Also includes: Configure the instantaneous window length parameter to determine the length of the instantaneous value statistics window; Configure link quality threshold parameters to compare with link quality statistics to select the transmission mode.
6. A link quality assessment device for a wireless communication network, comprising a processor and a memory storing program instructions, characterized in that, The processor is configured to, when running the program instructions, execute the link quality assessment method for a wireless communication network as described in any one of claims 1 to 5.
7. A wireless communication system, characterized in that, include: The wireless communication system itself; and, The link quality assessment device for a wireless communication network as described in claim 6 is installed on the body of the wireless communication system.
8. A routing method for a wireless communication network, characterized in that, Applied to the wireless communication system as described in claim 7; the method includes: Obtain link quality statistics for at least one communication path leading to the destination node; wherein the link quality statistics are determined based on the link quality assessment method for the wireless communication network according to any one of claims 1-5; The link quality statistics for each communication path are compared with the preset link quality threshold. Based on the comparison results, a transmission mode is selected from the set including multipath load balancing transmission mode, multipath redundancy transmission mode and single path transmission mode. According to the selected transmission mode, the data packet is sent to the next hop node through the corresponding communication path.
9. A computer-readable storage medium storing program instructions, characterized in that, When the program instructions are executed, they cause the computer to perform the link quality assessment method for the wireless communication network as described in any one of claims 1 to 5, or to perform the routing method for the wireless communication network as described in claim 8.