2 The 80.11 Basics
2.4 The IEEE 802.11 Power Saving Mechanism
In WLANs, battery power is an unavoidable issue that must be dealt with. In
order to save power, 802.11 defines a MAC-layer Power Saving Mechanism (802.11 PSM) that allows a wireless STA to go from the active state to doze or power saving state when the STA is not involved in any data transmissions [7]. In the infrastructure configuration of a WLAN, the AP will keep track of all STAs that are in power-saving state and buffer frames addressed to these STAs. These frames are kept until the STAs request them to be sent or discarded if they are not requested for a certain period of time. While in the case of ad hoc configuration, time is divided into Beacon Intervals and each Beacon Interval contains an ATIM (Ad Hoc Traffic Indication Message) Window followed by the Data Transmission Phase. The ATIM Window is used as the common awake period for all participating STAs to announce their traffic through ATIM frame transmissions. After the ATIM Window finishes, STAs that successfully send or receive ATIM frames must remain in the active state, and STAs can switch to power-saving state if they are not involved in any traffic announcements till the beginning of next ATIM Window. Actual data transfers occur in the Data Transmission Phase, and the normal DCF (Distributed Coordination Function) access procedure is used while sharing the transmission medium among the active STAs. Any STA that completes the ATIM frame transmission in the ATIM Window but fails to send data packet in the Data Transmission Phase will try to initiate another traffic announcement in the next ATIM Window. This Power Saving Mechanism can be exemplified by the diagram in Fig. 1.2.
In Fig. 1.2, STA A announces a buffered packet for B using an ATIM frame.
STA B replies by sending an ATIM-ACK, and both A and B stay awake during the entire Beacon Interval. The actual data transmission from A to B is completed during the Beacon Interval. Since C does not have any packet to send or receive, it dozes after the ATIM window. In addition to the 802.11 PSM, a number of power saving methods [14, 15] covering all protocol layers from Physical to the Application layer
have also been proposed in the literature, and a system-level power-saving methodology for heterogeneous wireless networks is in [16].
Chapter 3
The Shortest Time First Scheduling Mechanism
3.1 The Problem of the IEEE 802.11 PSM
As we said in Sec. 1.2, wireless STAs need to use different rates for different channel qualities. But when the 802.11 PSM is enabled in such a multiple rate ad hoc environment, we observe a problem of power management inefficiency which can be exemplified in Fig. 2.1. In this example, we assume there are 16 STAs in the network, 8 of which are transmitters3, and 8 of which are receivers. Each transmitter has only one packet to send to its receiver and all data packets are equal in length. In those transmitters, 4 of them are fast STAs, and the other 4 are slow STAs. Since fast (slow) STAs will use less (more) time in sending packets, the packets transmitted by fast (slow) STAs are represented by narrow (wide) rectangles in Fig. 2.1. According to the operations of 802.11 PSM, these transmitters must first announce their traffic in the ATIM Window and then use DCF to contend for the channel in the Data Transmission Phase. In the worst case, it may happen that all slow transmitters win the channel contentions before any fast transmitter has a chance to send data packet.
Therefore as shown in the upper half of Fig. 2.1, the numbers of STAs that must stay in the active/power-saving state in the first, second, and third Data Transmission
3 In this dissertation, a transmitter is a wireless STA that only transmit, not receive data packets.
Figure 3.1: The worst-case and best-case scenarios of power management in an 802.11 multiple rate ad hoc network.
Phases are 16/0, 12/4, and 8/8, respectively. That is, 4 of the 16 STAs must stay in the active state for 2 Beacon Intervals, and 8 STAs must remain active for all of the 3 Beacon Intervals. In order to save power, we will propose a scheduling mechanism called STFS (Shortest Time First Scheduling) in this dissertation so that the packets transmitted on the channel can be as shown in the lower half of Fig. 2.1. This scheduling mechanism has the characteristic that it will schedule all fast transmissions or transmissions using less channel time to transmit before any of the slow STAs are allowed to send packet in every Data Transmission Phase. By scheduling in this way, more STAs can complete their data transmissions earlier and then go to power-saving state to conserve energy. Now the numbers of active/power-saving STAs are only 16/0, 8/8, and 4/12 in Data Transmission Phases 1, 2, and 3, respectively, the total power consumptions of these STAs are thus minimized.
3.2 The Problem of Unfair Channel Time Allocations
In addition to the problem of power management inefficiency stated in Sec. 2.1, there is a performance anomaly for ad hoc networks with STAs using different
Figure 3.2: The numbers of packets that are actually transmitted in each Data Transmission Phase for 802.11 PSM (the upper half) and STFS (the lower half) in an 802.11 multiple rate ad hoc network.
transmission rates [17]. This anomaly is due to the fact that 802.11 is fair only on station or packet level but not on the temporal level so that all STAs in the network have the same saturation throughput. That is, this packet level fairness makes fast STAs be allocated much less channel time than that allocated to the slow STAs. The authors in [9] proposed a model to investigate this anomaly and mitigated the unfair channel time allocations between different-rate STAs by using larger minimum contention window sizes or smaller packet sizes for slow STAs. The problem with these methods is that the saturation throughput of the slow STAs will be degraded.
Since the Data Transmission Phase in a Beacon Interval has a fixed time interval, this time interval may be too short for all active transmitters to complete their data transmissions. This may happen when there are too many active transmitters contending for the channel in the same Data Transmission Phase or when the total amount of time needed for all active transmissions is longer than the time interval of the Data Transmission Phase. When either of these situations occurs, our scheduling mechanism can provide higher network throughput and allocate more channel time to fast STAs, as illustrated with the example in Fig. 3.2. We assume in this example that:
1. The number of transmitters that can complete the traffic announcement in
each ATIM Window is 10, of which 4 are fast and 6 are slow.
2. Each transmitter always has a packet ready to transmit to its receiver.
3. The link rate used by fast/slow transmitters is 2r/r Mbps.
4. The packet size at the physical layer is m bits.
5. The length of the Data Transmission Phase is too short to accommodate all 10 data transmissions.
Fig. 3.2 shows a possible data transmission by 802.11 PSM and the transmissions scheduled by our STFS in 2 Beacon Intervals. As shown in this figure, the numbers of packets that actually transmitted by fast/slow transmitters in Data Transmission Phase 1 (2) are 0/3 (2/2) for 802.11 PSM and 4/1 (4/1) for STFS. By scheduling fast transmissions to proceed first, STFS can accommodate more packets in every Data Transmission Phase. The total number of packets transmitted by STFS in these 2 Beacon Intervals is greater than that transmitted by 802.11 PSM, thus STFS can deliver higher network throughput than 802.11 PSM can provide. The total amount of channel time, inμs, used by all fast (slow) STAs to transmit data packets (not including the time used by ACK transmissions) is defined as Σi ni× m/2r (Σi
ni× m/2r), where ni is the number of data packets actually transmitted in the ith Beacon Interval. Therefore, in Fig. 2.2, the channel time allocated to all fast (slow) transmitters is 0× m/2r + 2× m/2r = m/r (3× m/r + 2× m/r = 5m/r) for 802.11 PSM and 4× m/2r + 4× m/2r = 4m/r (1 × m/r + 1 × m/r = 2m/r) for STFS. The total time allocated to all fast transmitters is thus increased from m/r to 4m/r, while that allocated to slow transmitters is slightly decreased from 5m/r to 2m/r, therefore STFS can offer fast transmitters more opportunities to send packets than 802.11 PSM. In the example of Fig. 2.1, we assume each transmitter only has a specified number of data packets to send, therefore after a transmitter completes all its data transmissions, it will go to the doze mode; that is, the number of active transmitters in each Beacon
Interval may decrease over time. By scheduling fast transmissions to proceed first, STFS can make this decrease more significant, so more power can be saved, but neither network throughput nor the fairness problem are improved in this case. While in the example of Fig. 2.2, each transmitter in the network always has a packet ready to be sent, so the number of active transmitters will remain almost the same in every Beacon Interval (because the ATIM Window has a fixed time interval). If the Data Transmission Phase is too short to accommodate all active transmissions, not all active transmitters have chances to send their packets. By scheduling fast transmissions first, more data transmissions and more fast transmissions are allowed in every Beacon Interval, the network throughput and the fairness problem, not the total power consumptions, are thus improved.
3.3 Proposed Scheduling Mechanism
In STFS, we assume:
1. The WLAN is configured in its ad hoc mode.
2. An ideal channel condition without packet losses is considered.
3. The Beacon Intervals begin and end approximately at the same time at all STAs, so the problem of time synchronization is not considered.
4. Each STA in the network can support k data rates, r1 > r2 >˙˙˙> rk, and has implemented an automatic rate selection protocol such as the RBAR in [13], which enables a receiver to select the most appropriate rate for its sender to use in the Data Transmission Phase.
5. The data packets transmitted by all STAs are equal in length so the time required to transmit a packet is determined by its transmission rate.
s0 e0 s1 e1 s2 e2 sk ek
0 |q0|-1 |q0| |q0|+|q1|-1 |q0|+|q1| |q0|+|q1|+|q2|-1 |q0|+ +|qk-1| |q0|+ +|qk|-1 q-1 array
index
q0 q1 q2 qk
Figure 3.3: The configuration of k+1 queues in the scheduling array.
6. The promiscuous mode of the wireless interface is enabled so that the interface can intercept and read each network packet that arrives in its entirety.
As we mentioned earlier, STFS will schedule all fast transmissions before any of the slow transmissions in every Beacon Interval. A major problem with this scheduling mechanism is starvation; that is, some of the slow STAs may have no chances to send packets when Data Transmission Phase can not accommodate all active transmissions. In order to achieve the goals of shortest time first and starvation prevention, we modify the packet formats of 2 control frames as follows:
1. The ATIM frame is extended with a 1-byte aging field.
2. The ATIM-ACK is modified to include 2 additional 1-byte fields, aging and rate.
The uses of these fields will be described in the following paragraph.
In addition to the above modifications, each STA in the network needs to maintain a local counter, fc. This counter has an initial value of 0. Whenever an STA has made a traffic announcement in an ATIM Window but fails to initiate
transmission in the following Data Transmission Phase, fc is incremented by 1, otherwise fc is reset to 0. Before an ATIM frame is sent, the transmitter will copy the value of fc to the aging field of the frame. After an ATIM frame is received, the rate selected by the receiver is sent back to it’s transmitter through the rate field of the ATIM-ACK. The contents of the field aging in ATIM-ACK are coming from the same field of the received ATIM frame.
For the purpose of deciding packet transmission order in every Data Transmission Phase, a scheduling array of size q and a number of 2× (k + 1)4 indexes, s0, e0, s1, e1,
˙˙˙, sk, ek, also need to be maintained by each STA in the network. The size of this array is such that it can accommodate at least k + 1 non-overlapping queues, q0, q1,˙˙˙, and qk; that is: |q0| + |q1| + ˙˙˙ + |qk| ≦ q. The two ends, front and rear, of each qi are pointed to by si and ei, 0 ≦ i ≦ k, respectively. The configuration of these queues in the array is shown in Fig. 2.3. Whenever an STA receives an
ATIM-ACK, the STA will use the DA5, rate, and aging fields of the frame to update its scheduling array as follows:
1. If aging > 0, the contents of DA will be put into q0.
2. If aging = 0 and rate = ri, the contents of DA will be put into qi, 1 ≦ i ≦ k, that is, the addresses of all STAs with the local counter fc = 0 and using the same data rate will be put into the same queue in the scheduling array.
The order of the station addresses in queue qi, 1 ≦ i ≦ k, is decided by the order of ATIM-ACK receptions, while the order in q0 is determined as follows: The address in DA of ATIM-ACK1 will have a smaller index value in q0 than that in DA of
4 Recall that k is the number of different rates supported by STAs in the network.
5 The Destination Address field, which now contains the address of the STA that transmitted the ATIM frame.
• •
Since the promiscuous mode of the wireless interface has been enabled, this frame will also be received by C.
Step2: Based on the signal strengthof the ATIM frame , B then selects the most appropriate rate, e.g. r1, for A to use.
Step3: B sends the ATIM-ACK with DA = ‘A’, rate = r1, and aging = 0 back to A. This ATIM-ACK will also be heard by C.
In ATIM Window:
Step4: A and C extract the contents fromDA, aging, and rate fields of the ATIM-ACK and use these information to update their respective scheduling arrays.
After the updates, the arrays at A and C may be like the following:
A
0 6
s1
In Data Transmission Phase :
Step5: After 6 idle time slots, A sends a data packet to B.
Data 5
Step6: B responds with an ACK.
3 ATIM-ACK
ACK 6
Step7: A resets its backoff counter to ek + 1 = 25 + 1 = 26.
Station A will set its backoff counter to 6 in the following 5 Data Transmission Phase.
SA DA a
Figure 3.4: A simple STFS scheduling example.
ATIM-ACK2 if (1) aging of ATIM-ACK1 is larger than that of ATIM-ACK2 or (2) aging of ATIM-ACK1 is equal to that of ATIM-ACK2 and rate of ATIM-ACK1 is higher than that of ATIM-ACK2 or (3) Both aging and rate of ATIM-ACK1 are equal to those of ATIM-ACK2, and ATIM-ACK1 is received earlier than ATIM-ACK2. For example, suppose an STA X receives 4 ATIM-ACKs with DA =’ A’, aging = 0, and rate = r2 at time t, DA =’ B’, aging = 0, and rate = r2 at time t + 1, DA =’ C’, aging = 1, and rate = r1 at time t + 2, and DA =’ D’, aging = 2, and rate = r2 at time t + 3.
Then, in the scheduling array of STA X, the address of STA A will have a smaller index value in q2 than that of STA B, and the address of STA D will have a smaller index value in q0 than that of STA C. When ATIM Window finishes, the array index values will be used by those STAs whose addresses are recorded in the scheduling array to setup the backoff counters to be used in data transmissions. Therefore all
STAs whose addresses are in q0 are permitted to send packets first, followed by the transmitters in q1, and so on. Since the STAs whose addresses are in qi will use a higher transmission rate than those whose addresses are in qj , 1 ≦ i < j ≦ k, the goal of shortest time first is achieved. Any STAs that had completed traffic announcements but failed to transmit data in the previous Beacon Interval(s) are recorded in q0, so the starvation problem mentioned above is also solved. After a transmitter completes its data transmission, it will reset its backoff counter value to ek + 1. This will give that transmitter chances to send multiple packets in the same Data Transmission Phase.
After the current Beacon Interval terminates, the contents of the scheduling arrays maintained at all STAs are flushed to ensure the correct scheduling in the next Beacon Interval. A simple scheduling example of the STFS is shown in Fig. 2.4.
3.4 Performance of the STFS
We have developed a C++ based simulator to investigate the power consumption, channel usage, and throughput performance of the STFS and, for the purposes of comparison, the 802.11 PSM. Since the ATIM Window size will significantly affect the performance of 802.11 PSM [18, 19], we will vary that size to be 30%, 40%, and 50% of the Beacon Interval in each set of the simulations to see its effect on the performance of STFS. In this dissertation, we assume an STA will never be both a transmitter and a receiver at the same time. An 802.11b-based ad hoc network is particularly considered in our simulations, so the STAs in the network can support k = 4 different data rates, with r1 = 11.0 Mbps, r2 = 5.5 Mbps, r3 = 2.0 Mbps, and r4 = 1.0 Mbps. The rate used to send all control frames is 1 Mbps. In all simulations, we assume the numbers of transmitters that will use rate ri, 1 ≦ i ≦ 4, for data transmissions are equally distributed among all transmitters in the network. The size
0 Number of STAs
Total Power Consumptions
802.11 PSM STFS
(a) ATIM Window size = 0.3 Beacon Interval× Number of STAs
Total Power Consumptions
802.11 PSM STFS
(b) ATIM Window size = 0.4 Beacon Interval× Number of STAs
Total Power Consumptions
802.11 PSM STFS
(c) ATIM Window size = 0.5 Beacon Interval× Number of STAs
Power Consumption Improvemet
ATIM Window Size=30% of the Beacon Interval ATIM Window Size=40% of the Beacon Interval ATIM Window Size=50% of the Beacon Interval
(d) Percentage improvement on total power consumptions
Number of STAs Difference in Total Power Consumptions
ATIM Window Size=30% of the Beacon Interval ATIM Window Size=40% of the Beacon Interval ATIM Window Size=50% of the Beacon Interval
(e) The difference in total power consumptions between STFS and 802.11 PSM for ATIM Window of different sizes
×109W
Figure 3.5: Power consumption performances of STFS and 802.11 PSM with each transmitter having 1000 data packets to send.
of the scheduling queue maintained at each STA is set to q = 63. The packet size at the MAC layer is fixed at 1024 bytes, and the lengths of the Beacon, ATIM, and
×
0%
10%
20%
30%
40%
50%
60%
4 8 12 16 20 24 28 32 36 40 44 48
Number of Transmitters
Percentage of Time Allocations
STFS: 11 M STFS: 5.5 M STFS: 2 M
STFS: 1 M 802.11 PSM: 11 M 802.11: 5.5 M
802.11 PSM: 2 M 802.11: 1 M
0%
10%
20%
30%
40%
50%
60%
4 8 12 16 20 24 28 32 36 40 44 48
Number of Transmitters
Percentage of Time Allocations
STFS: 11 M STFS: 5.5 M STFS: 2 M
STFS: 1 M 802.11 PSM: 11 M 802.11 PSM: 5.5 M
802.11 PSM: 2 M 802.11 PSM: 1 M
×
0%
10%
20%
30%
40%
50%
60%
4 8 12 16 20 24 28 32 36 40 44 48
Number of Transmitters
Percentage of Time Allocations
STFS: 11 M STFS: 5.5 M STFS: 2 M
STFS: 1 M 802.11 PSM: 11 M 802.11 PSM: 5.5 M
802.11 PSM: 2 M 802.11 PSM: 1 M
×
Figure 3.6: Percentage of total channel time allocated to STAs with different rates by STFS and 802.11 PSM in 1000 Beacon Intervals.
0 1 2 3 4 5 6 7 8
4 8 12 16 20 24 28 32 36 40 44 48 Number of Transmitters
Throughput, Mbps
802.11 PSM STFS
(a) ATIM Window size = 0.3 Beacon Interval×
0 1 2 3 4 5 6 7 8
4 8 12 16 20 24 28 32 36 40 44 48 Number of Transmitters
Throughput, Mbps
802.11 PSM STFS
(b) ATIM Window size = 0.4 Beacon Interval×
0 1 2 3 4 5 6 7 8
4 8 12 16 20 24 28 32 36 40 44 48
Number of Transmitters
Throughput, Mbps
802.11 PSM STFS
(c) ATIM Window size = 0.5 Beacon Interval×
Figure 3.7: The network throughput delivered by STFS and 802.11 PSM in 1000 Beacon Intervals.
ATIM-ACK frames for 802.11 PSM are 50, 28, and 14 bytes, respectively. The Beacon Interval is set to be 100 ms. For the energy model, a wireless STA will consume 1.65W, 1.4W, 1.15W, and 0.045Win the transmit, receive, idle, and the power-saving states, respectively [20, 21]. As in [22], the energy consumption for switching between awake and power-saving states is not considered in this dissertation. All simulation results are averages over 30 runs.
In the first set of simulations, the total power consumptions of all STAs are measured for the case in which one half of the STAs are transmitters and each transmitter has 1000 data packets to send to its receiver. The results are shown in Fig.
In the first set of simulations, the total power consumptions of all STAs are measured for the case in which one half of the STAs are transmitters and each transmitter has 1000 data packets to send to its receiver. The results are shown in Fig.