• No results found

Real-Time Wireless: Delay Analysis for Reliable Graph Routing

4.6 A Probabilistic End-to-End Delay Analysis

4.7.1 Testbed Experiment

Implementation

We evaluate our delay analysis on an indoor wireless testbed deployed in two buildings at Washington University [2]. The testbed consists of 69 TelosB motes, each equipped with Chipcon CC2420 radios compliant with the IEEE 802.15.4 standard. Note that the physical layer of WirelessHART is also based on IEEE 802.15.4. We implement a network protocol stack on the testbed which consists of a multi-channel TDMA MAC protocol with channel hopping based on Equation 4.3 and a routing protocol. The uplink and downlink graphs are generated using the graph routing algorithms presented in [93]. Time is divided into 10 ms slots and clocks are synchronized across the entire network using the Flooding Time Synchronization Protocol (FTSP) [131].

Experimental Setup

To avoid channels occupied by the campus Wi-Fi, we use IEEE 802.15.4 channels 11 to 14 in our experiments. For each link in the testbed, we measured its packet reception ratio (PRR) by counting the number of received packets among 250 packets transmitted on the link.

Following the practice of industrial deployment, we only consider links with PRR higher than 90% on every channel to determine the testbed topology. Figure 4.2 is a topology of the testbed showing the node positions on the two buildings’ floor plan. We use two nodes (colored in blue in the figure) as access points, which are physically connected to a root server (Gateway). The Network Manager runs on this root server. The rest of motes work as field devices.

We experiment by generating 10 flows on our testbed. The period of each flow is picked up from the range of [10 ∗ 28, 10 ∗ 211]ms. The relative deadline of each flow equals to its period. All flows are schedulable based on our delay analyses. Priorities of the flows are assigned based on Deadline Monotonic (DM) policy, a widely used scheduling policy in CPU

scheduling and in control area networks. DM assigns priorities to flows according to their relative deadlines; the flow with the shortest deadline being assigned the highest priority.

Results

We run our experiments long enough so that each superframe is run for at least 20 cycles.

Based on our experimental results, we evaluate our proposed approaches in terms of reliability and delay. We use delivery ratio to measure reliability. The delivery ratio of a flow is defined as percentage of packets that are successfully delivered to destination. Then, we compare the worst case end-to-end delay observed in experiments with our analytical delay bounds.

Figure 4.3 shows our results. Figure 4.3(a) shows the delivery ratios of all 10 flows. As the figure shows, one flow has a delivery ratio of 95% while all other flows have 100% delivery ratio. This is reasonable as graph routing is designed for such a high degree of reliability through route, channel, and time diversity. This high delivery ratio demonstrates the effec-tiveness of graph routing. Figure 4.3(b) plots the maximum end-to-end delay observed in our experiments and the end-to-end delay bounds derived through our delay analysis. As the figure shows, our analytical delay bounds are no less than the experimental worst case delays, demonstrating that our delay analysis provides safe upper bounds of the actual delays. For this particular experiments, the bounds are at most 2.68 times that observed in experiments.

Note that our analytical delays are the worst case delays while the longest delays observed in the experiments are not the worst-case delays as our testbed is not deployed in industrial environments. Hence, this ratio of 2.68 is expected to be smaller should the experiments be performed in an industrial environment.

4.7.2 Simulation

For more extensive evaluation, we now use the same testbed topology and evaluate the results in simulations. We generate flows by randomly selecting sources and destinations, and simulate their schedules in these topologies. Two nodes in the topology are selected as access points. The uplink and downlink graphs are generated using the same graph routing algorithms as the one we used in testbed experiment. The periods of the flows are considered

20 25 30 35 40 45 50

Figure 4.4: Worst case delay analysis performance in simulation

harmonic and are randomly generated in the range [10 ∗ 25, 10 ∗ 213]ms. In default settings, the deadlines are considered equal to periods. Later we decrease the deadlines. Priorities of the flows are assigned based on DM policy. In all cases, we use 12 channels for scheduling.

We evaluate our analysis in terms of the following metrics. (a) Acceptance ratio defined as the proportion of the number of test cases deemed to be schedulable to the total number of test cases. (b) Pessimism ratio defined, for a flow, as the proportion of the analyzed theoretical upper bound to its maximum end-to-end delay observed in simulations.

Performance Analysis of the Worst Case Delay Analysis

Since there exists no prior work on delay analysis under reliable graph routing of Wire-lessHART, we analyze the effectiveness of our analysis by simulating the complete schedule of transmissions of all flows released within the hyper-period. In the figure, “Simulation”

indicates the fraction of test cases that have no deadline misses in the simulations, and

“Analytical” indicates the acceptance ratio of our delay analysis.

Figure 4.4(a) shows the acceptance ratios for 1000 test cases under varying number of flows.

As the figure shows, for 20 flows, 986 test cases among 1000 are schedulable through sim-ulations while our analysis has determined 818 cases as schedulable as its acceptance ratio is 0.818. For 30 flows 862 cases are schedulable through simulations among which 419 cases are deemed schedulable by our analysis, which is almost 50% of the total schedulable cases.

The acceptance ratios decrease sharply with the increase in the number of flows as the net-work becomes congested. However, in most cases, at least 50% of all schedulable cases are accepted.

Figure 4.4(b) plots the pessimism ratios of the flows under our analysis for randomly selected 8 test cases each consisting of 30 flows. The figure plots pessimism ratios w.r.t. the worst case possible delay (i.e. the ratio of analytical delay to worst case possible delay in simulation).

It indicates that the 75th percentile of the pessimism ratios is less than 2.5 in all but one test case where it is below 2.7 and the median is below 2.6. These results indicate that our delay bounds are not overly pessimistic for the particular cases we have tested.

In every setup, we have observed that the acceptance ratios of our analysis are close to those of simulation. In addition, all test cases accepted by our analysis meet their deadlines in the simulations which demonstrates that the bounds are safe. Our analysis hence can be used as an effective schedulability test for real-time flows under reliable graph routing.

Performance Analysis of the Probabilistic Delay Analysis

Now we analyze the performance of our probabilistic analysis (Section 4.6). We show the acceptance ratios under the probabilistic delay bound in Figure 4.5. Figure 4.5(a) shows that the acceptance ratio is always close to that of simulation under various number of flows. For 30 flows, Figure 4.5(b) shows acceptance ratios under varying deadlines, where a flow’s deadline is varied as period ∗(deadline factor). Restoring the base deadlines (equal to period), Figure 4.5(c) shows acceptance rates under varying sampling rates, where a flow’s rate is varied as (old rate) ∗ (rate f actor). The results show that probabilistic delay bounds allow to accept more test cases, since these bounds are tighter than the worst case bounds.

Figure 4.6 plots the distribution of pessimism ratios for 30-flows in 8 test cases by restoring the original rates of the flows. Compared to the ratios under the worst-case delay analysis (of Figure 4.4), these ratios are higher because here pessimism ratios are the ratio of analytical delay bound to the actual observed delay in simulation. Since most of the times a packet is delivered through dedicated routes, the actual delay is lot shorter than the worst case possible delay.

20 25 30 35 40 45 50

(a) Under varying number of flows (n)

0.6 0.7 0.8 0.9 1.0

(b) Under varying deadlines when n = 30

0.250 0.5 1.0 2.0 4.0

(c) Under varying rates when n = 30

Figure 4.5: Acceptance rate under probabilistic delay bound

1 2 3 6 7 8

Figure 4.6: Pessimism ratio for 30 flows under probabilistic bound

Based on PRR, for each flow, the probability of delivering through the dedicated route was at least 0.90 (based on Equation 4.7). Therefore, the results suggest that the probabilistic delay bounds represent safe upper bounds with probability ≥ 0.90. Since graph routing in a WSAN is a conservative way of scheduling transmissions to ensure reliability at the cost of a high degree of redundancy, the worst case delay bound can be naturally pessimistic in many set ups. Hence, the probabilistic delay bound can be used as an alternative with the bounds being upper bound with high probability for soft real-time flows for which probabilistic bounds are sufficient.

4.8 Summary

Industrial wireless sensor-actuator networks must support reliable and real-time communi-cation in hash environments. Industrial wireless standards such as WirelessHART adopt a reliable graph routing approach to handle transmission failures through retransmissions and route diversity. These mechanisms introduce substantial challenges in analyzing the schedulability of real-time flows. We have presented the first worst-case delay analysis under reliable graph routing. We have also proposed a probabilistic delay analysis that provides delay bounds with high probability. Experiments based on a wireless testbed of 69 nodes and simulations show that our analytical delay bounds are safe, and can be used as an effective schedulabity test for real-time flows under reliable graph routing.

Chapter 5

Real-Time Wireless: Priority