Project Report

advertisement
Scheduling in Bluetooth Networks
Alex Garcia
CS 537
California State Polytechnic University, Pomona
Cuban217@gmail.com
1) Introduction
Bluetooth is a short-range wireless communication technology for ad-hoc communication
between Bluetooth enabled devices. It operates in the industrial-scientific-medical (ISM) band at
2.45 GHz. Since the bandy can be very noisy, Bluetooth employs a frequency hopping scheme
for modulation. Bluetooth devices within range can set up an ad-hoc network called a piconet
with one master that controls the piconet and a maximum of seven slaves. A scatternet is a link
of several piconets together to yield a global wireless ad hoc network. There are interfaces
known as bridges that give the ability for messages to be delivered between two neighboring
piconets. In this paper, I will be discussing several different schemes used in order to provide
optimal scheduling for Bluetooth networks.
2) Piconet Scheduling Schemes
There are several practical polling schemes that can be used to schedule Bluetooth networks.
These schemes are used because they can successfully fulfill the fairness constraint which makes
it so each queue must be visited once per cycle but the visiting order can be dynamically
changed. First I will describe what each of these piconet scheduling schemes are, then I will
discuss the comparisons between them.
Pure round robin (PRR) is a scheme in which a fixed cyclic order is defined, and a single
chance to transmit is given to each master-slave queue pair according to the cyclic order. This
particular scheme is not exhaustive like the next polling scheme that was tested which is the
exhaustive round robin (ERR). The main difference between these two schemes is that the ERR
does not let a master switch to the next pair until the master and slave queues are empty. The
next practical polling scheme is the exhaustive pseudocyclic master queue length (EPM) which
creates a different cyclic order in the beginning of each cycle when comparing master-to-slave
queue lengths. The limited round robin (LRR) is similar to ERR except that the number of
transmission per cycle allows to get a limit on the cycle length and to avoid the unbounded cycle
length because of the traffic characteristics. Limited and weighted round robin (LWRR) has a
system that gives each slave an assigned weight and maximum priority at the beginning. Each
time a slave is polled without data being exchanged between master and slave, the weight of the
slave is lowered by 1. Otherwise, it is increased by 1 up to maximum priority. Depending on
how much weight each individual slave has is how many cycles that it has to weight before it is
polled again.
After several simulation scenarios were done with IP datagram traffic and TCP
connection oriented traffic, each scheduling scheme showed their strengths and weaknesses. The
pure round robin showed the worst performance when the traffic was up to 0.85. The delay
difference between exhaustive round robin and EPM is negligible during the same amount of
traffic. However, under higher traffic load, PRR ended up having the lower delay than ERR.
Limited round robin came close to the low delays of ERR in low traffic and close to the lower
delay of PRR during high traffic load. LWRR performed better than all of them in both high and
low traffic loads because it is an improved version of limited round robin. The authors proposed
another scheme called fair exhaustive polling that works like pure round robin at low traffic
loads and ERR in high traffic loads. This scheme tries to poll slaves that have nothing to send as
seldom as possible. Each slave belongs in either an active state or an inactive state. In the
beginning of the polling cycle, all slaves are considered active. As long as a slave is in an active
state, it will continue to get polled. The two things that can cause a slave to get into an inactive
state are: the slave has no information to send, and the master has no information to send to the
specific slave. The slave remains in the inactive state until either the master has something new
to send to it, or all slaves become inactive which restarts the polling cycle again. This scheme
makes sure that only the most active master-slaves connections get the attention when it comes
to queuing which makes the FEP scheme act as an exhaustive scheduler at low loads and as a
round robin scheduler at high loads. This makes the fair exhaustive polling the best out of all
these schemes since it provides lower delays than the exhaustive and round robin schedulers at
all traffic loads.
3) Soft Coordinated Scheduling Scheme for Scatternet
There are two important phenomena that can reduce the efficiency of the polling-based
communication in Bluetooth scatternets. The first one is that slaves that have no data to transmit
may be polled, while other salves with data to transmit may still be waiting to be polled. This
problem applies to polling-based schemas in general, like the previous schemes mentioned in the
previous section. The second one involves master-slave pairs which may not be present in the
piconet when they are being polled. The master or slave might be focusing on a connection in
another piconet through the use of a bridge which would cause these phenomena. This one is
specific to the Bluetooth environment and not in other polling-based communication scenarios.
A soft coordination scheme can be used in order to deal with these two phenomena.
In soft coordination schemes, nodes are able to decide their locations in piconets based on
local information. While these schemes have significantly reduced complexities, they cannot
guarantee that bridging nodes will participate with each other without conflict. The soft
coordination scheme that is presented in chapter 18 is called the pseudorandom coordinated
scatternet scheduling (PCSS) algorithm. Coordination is achieved through the sharing of
implicit rules while leaving out the explicit control information. This algorithm has a very low
complexity which allows easy implementation and deployment with the current Bluetooth
specifications. There are two key components to PCSS algorithm. The first one is the
checkpoint mechanism. A checkpoint is a designed Bluetooth frame. At each checkpoint, a
master node actively checks its salve by sending a packet to the slave and waiting for a response.
While the master is checking for the slave, the slave also passively checks for its master by
listening to the master at each checkpoint. If the master sends information, the slave responds
with a response packet. A node remains active on the checkpoint until there is user data in the
master-to-slave or slave-to-master directions or until it has to leave for the next checkpoint one
of its other links. The other key component to the PCSS algorithm is the dynamic adjustment.
With this component, the positions of checkpoints are assigned on a given link following a
pseudorandom sequence that is generated based on the Bluetooth clock of the master and the
MAC address of the slave. This guarantees the same sequence will be generated by both nodes
in a master-slave pair, while sequences belonging to the other node pairs will guarantee to be
different. This makes sure that different links of a node will collide only occasionally. Figure 1
below shows an example of how the checkpoints work in regards to keeping each checkpoint
separate from the others.
Figure 1: Checkpoints example
The ideal coordinated scatternet scheduler (ICSS) is used to evaluate the PCSS scheme to
see if it is optimal. In this algorithm, nodes have new information available to them. They are
able to be aware of the already prescheduled transmissions of its neighbors and they are also
aware of the content of the transmission buffers of its neighbors. After each package exchange
on a given link the two nodes schedule the next package exchange as long as there is user data to
be transmitted. With the traffic dependent meeting point intensity adjustments, the throughput of
PCSS quite closely matches the results of the ideal ICSS algorithm.
The PCSS algorithm can also be tested with the uncoordinated greedy scatternet scheduler
(UGSS) algorithm. In this algorithm, Bluetooth nodes do no attempt to coordinate their meeting
points. Instead, each node visits its neighbors in a random order. These nodes switch
continuously among their Bluetooth links in a greedy mater. With the greedy nature of the
UGSS algorithm, the results show that it has a high power consumption of the Bluetooth
components. Therefore, PCSS achieves higher throughput than the uncoordinated UGSS
algorithm. The conclusion that can be drawn from this is that PCSS is an optimal soft
coordinated scheduling scheme since it excels passed the ICSS algorithm as well as the UGSS
algorithm. Now that I have talked about soft coordinated scheduling schemes, I will discuss the
hard coordinated schemes presented in the book.
4) Hard Coordinated Central Scheduling Scheme
There are three design goals that hard coordinated central scheduling schemes strive for.
The first design goal involves computation time. The complexity must be in polynomial time
in the amount of nodes and links that the scatternet contains. The solution must be perfect to
assign any feasible traffic load request successfully. And the third design goal is that each
individual link load is evenly distributed along the frame interval so that the Quality of
Service (QoS) delay and jitter are minimized. Here is a bipartite graph below in Figure 2
with eight masters and nine slaves.
Figure 2: Bipartite Graph
Here is the perfect scheduling problem for scatternet that will be used for the bipartite graph
above.
Input: A feasible load matrix L
Output: A feasible F assigning load L perfectly, i.e.
∑𝑘 𝑆(𝑥, 𝑘) = 𝑇(𝐿, 𝑥)
∀𝑥 ∈ 𝑀 ∪ 𝑆
The graph is then created and the load matrix L and total load T(L,x) is shown below.
Figure 3: Load Matrix L
The algorithm continues to simplify the graph by using a procedure known as
Load_Partition. This procedure uses the divide and conquer technique. First, each nonzero
entry in the matrix is given a color black or white as long as no two directly linked entries
has the same color as shown in figure 4 below.
Figure 4
Two matrices 𝐿1 and 𝐿2 are generated from the load matrix L dividing each number by 2 and
if the number is initially odd, subtracting one first then dividing by 2. If it is odd and the
label is black (b) then 𝐿1 (i, j) is incremented by 1, otherwise 𝐿2 (𝑖, 𝑗) is incremented by 1 as
shown in figure 5 below.
Figure 5a: Load Matrix L1
Figure 5b: Load Matrix L2
Since the algorithm is reservation-based, it is suitable for multimedia and real-time traffic
to obain the guaranteed bandwidths along the communication routes. Once the algorithm
generates a feasible schedule from the set of link load requests, the assigned bandwidths are
exlusively used for the requesting applications. With bipartite scatternets that have no master
bridge, this algorithm yields a perfect, feasible schedule which guarantees the exact amounts
of bandwidth to the requesting applications.
5) Scheduling Algorithm for General Scatternet
When a scatternet has a master bridge as an integral part, the perfect scheduling problem
is no longer a solution. This happens when a master bridge is allowed in the general
scatternet so that a master may be enrolled in a number of piconets. The part of the
load_partition procedure for the perfect scheduling algorithm can’t quite work correctly with
a general scatternet with this type of non-bipartite graph because of the existence of a master
bridge that creates some odd cycle in the scatternet while even partitioning of link and nodal
load is necessary for the perfect schedule. Introduction of inclined links are necessary in
order to solve this which pairs one unpaired entry on the row with another unpaired entry on
the column of the bridge. Here is an example of a general scatternet that requires subperfect
scheduling algorithm.
Figure 6: General scatternet with 9 masters and 6 slaves
Figure 7: Black and White matrix
Figure 8: Load matrix L and total load T(L, x)
Regarding the figures above, the main difference to this Load_Partition procedure
compared to its original is that entries that are unpaired with any other node must be paired
with a nonzero entry. Also, for each master bridge whose load is presented by one row as a
piconet master and another column as bridging slave interconnected by two piconets, an
unpaired nonzero row entry is grouped with another unpaired nonzero column entry as
shown in figure 7. Other than these two differences, the rest of the subperfect scheduling
algorithm is similar to the perfect scheduling algorithm.
6) Conclusion
Depending on the amount of masters, slaves, master bridges, and slave bridges being
used, each scheme described above should be used with the scenario that fits best for them.
For simplified piconets that are not scatternets, the fair exhaustive polling (FEP) scheme is
best. When it comes to scatternets that have no master bridges, the perfect scheduling
algorithm is optimal. The subperfect scheduling algorithm handles scheduling the best for
the more complex problems involving odd amounts of masters and slaves with master
bridges used throughout. As long as the right scheme is used, each Bluetooth scheduling
problem can successfully be solved.
Download