• No results found

Adaptive Priority Control (APC)

Adaptive Priority Control

7.2 Adaptive Priority Control (APC)

The imbalance between uplink and downlink delay is caused by the unfair distribution of channel resources in DCF, as mentioned in the introduction. The uplink and downlink delay are dominated by the queuing delay when the channel is very congested, considering that the transmission and propagation delay in IEEE 802.11 wireless networks are very small compared with the queuing delay. Also, the queue size of the AP is much larger than that of wireless clients with a large number of VoIP sources, because the AP receives all packets to all the wireless clients. Thus, the queuing delay at the AP is also much bigger than those of the wireless clients, which causes difference between uplink and downlink delays. Therefore, the AP needs to be given more chances to transmit frames; APC increases the priority of the AP relative to that of the wireless clients adaptively according to wireless channel conditions and the uplink and downlink traffic volume.

90

Figure 7.1: The uplink and downlink delay of VoIP traffic in DCF

7.2.1 Priority mechanisms at the MAC layer

Before we see how to set the optimal priority of the AP to balance the uplink and downlink delay, we will see how to grant the priority to the AP at the MAC layer. In IEEE 802.11, there are three well-known methods to control the priority of wireless nodes, namely, control contention window, control interframe space, and burst frames. All three methods are used in IEEE 802.11e to differentiate the priorities of frames according to the Access Category (AC).

Control contention window (CW)

The first method controls contention window (CW) size. The backoff time of a frame is chosen randomly between 0 and CW measured in slots. When nodes have a smaller window size, the backoff time decreases and the transmission rate increases. However, this method increases the collision rate as the window size decreases [56], and that it is difficult to accurately control the priority since the backoff time is chosen randomly within the CW size. The increased collision rate significantly reduces throughput, as shown in Section 7.4.2.

Control InterFrame Space (IFS)

The second method changes the Inter-Frame Spacing (IFS). The node with the smaller IFS has the higher chance to gain access to the channel when two nodes are trying to transmit frames simultaneously. How-ever, we cannot accurately control the transmission rate using this method because the backoff time is still decided randomly, as in the first method.

Contention Free Transmission (CFT)

The last method transmits multiple frames contention free, i.e., without backoff, when a node gets a chance to transmit a frame. The IEEE 802.11e standard [26] proposes this, calling it Contention Free Burst (CFB).

However, in CFB the frames are sent contention free for a fixed amount of time, called Transmission Opportunity (TXOP). I propose a variant called CFT, where the number of frames to be sent contention free changes in real time according to the dynamically changing priority of the node.

APC uses CFT because it allows us to control the transmission rate precisely according to the priority without collision overhead; every node including the AP has the same chance to transmit frames on average in IEEE 802.11 [23]. Thus, if the AP sendsP frames contention free when it gets a chance to transmit a frame, then the AP has exactlyP times higher priority than other wireless clients.

7.2.2 APC algorithm

To achieve the fairness between the downlink (the AP) and uplink (wireless clients) in a BSS, when uplink and downlink have the same amount of traffic, the AP needs to be able to send the same number of packets as the total number of packets that all wireless clients send within a given interval. Then, intuitively, the AP needs to sendN frames while N wireless clients transmit one frame each. I call this ’semi-adaptive priority control (sAPC)’ because it is adaptive to the change in the number of the active wireless clients only. In VoIP traffic, when the same packetization interval is used for all VoIP traffic in a BSS, the uplink and downlink traffic volumes are symmetric, with large number of VoIP sources, and thus sAPC would balance the uplink and downlink delay in the case. However, when more than one packetization interval or codec is used for VoIP traffic in a BSS, the traffic volume of the uplink and downlink becomes asymmetric:

even when the number of active wireless nodes and wired nodes are the same, the number of packets from the wireless nodes and the wired nodes depends on the packetization intervals of the active nodes.

For example, when 10 wired nodes with 10 ms packetization interval and 10 wireless nodes with 20 ms packetization interval are talking at the same 64 kb/s voice bit rate, the volume of the downlink traffic from wired nodes is larger than the uplink traffic volume because of the overhead to transmit a VoIP packet such as MAC/PHY headers. In such a case, we need to consider the traffic volume of uplink and downlink in deciding the priority of the AP.

In order to consider such traffic volume changes, APC uses the ratio of the number of packets in the queue (queue size) of the AP and an average queue size of all wireless clients as the priority of the AP (P ) when the queue of wireless clients is not empty, and the number of active wireless clients when the queue of clients is empty. That is,P is calculated as follows:

P =

(⌈QQAPC ⌉ ifQC≥ 1

Ne ifQC < 1 (7.1)

where,QAPis the queue size of the AP,QCis the average queue size of the wireless clients, and Neis the number of active wired nodes.

For instance (Fig. 7.2), if four wireless clients, from C1 to C4, have two packets in each queue, and the AP has six packets in its queue, then the average queue size of the wireless clients (QC) is 2, and the priority of the AP (QAP) becomes 3 (=6/2). Thus, in APC, the AP sends three frames contention free when it acquires a chance to transmit a frame. If we assume that every node gets the same chance to transmit frames, then the average number of packets in the queue of the wireless clients and the one of the AP become one and three, respectively, and both of them become zero after the next transmission.

Therefore, transmittingQAP/QCpackets contention free results in the same packet processing time in the AP and wireless clients, which means that the AP and wireless clients have the same queuing delay. This is proved for the general case in the next section.

92

Figure 7.2: Packet transmission in APC

Using this metric, the priority of the AP changes adaptively when the traffic volume of the uplink and downlink changes. When the amount of traffic to the AP increases, the queue size of the AP increases and the priority also increases to balance the downlink delay with the uplink delay. When the queue size of the clients increases, the priority of the AP decreases.

Instead of using the number of packets, we could also use the packet size to compute the ratio between the uplink and downlink traffic volume. However, for our application, the overhead to transmit a voice packet is very large compared to the small voice data size. It was already shown in Chapter 5 that the voice data takes up only 18% of the total VoIP frame size in DCF. It was also confirmed via simulations that using the number of packets queued performs better than using the packet size.