author | Ghada Badawy <gbadawy@gmail.com> |
Tue, 13 Aug 2013 22:05:25 -0700 | |
changeset 10139 | 17a71cd49da3 |
parent 9136 | 96b16f69f91b |
child 10408 | 5c604e8ec2e1 |
permissions | -rw-r--r-- |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
1 |
.. include:: replace.txt |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
2 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
3 |
Wifi |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
4 |
---- |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
5 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
6 |
|ns3| nodes can contain a collection of NetDevice objects, much like an actual |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
7 |
computer contains separate interface cards for Ethernet, Wifi, Bluetooth, etc. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
8 |
This chapter describes the |ns3| WifiNetDevice and related models. By adding |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
9 |
WifiNetDevice objects to |ns3| nodes, one can create models of 802.11-based |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
10 |
infrastructure and ad hoc networks. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
11 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
12 |
Overview of the model |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
13 |
********************* |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
14 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
15 |
The WifiNetDevice models a wireless network interface controller based |
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
16 |
on the IEEE 802.11 standard [ieee80211]_. We will go into more detail below but in brief, |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
17 |
|ns3| provides models for these aspects of 802.11: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
18 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
19 |
* basic 802.11 DCF with **infrastructure** and **adhoc** modes |
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
20 |
* **802.11a**, **802.11b** and **802.11g** physical layers |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
21 |
* QoS-based EDCA and queueing extensions of **802.11e** |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
22 |
* various propagation loss models including **Nakagami, Rayleigh, Friis, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
23 |
LogDistance, FixedRss, Random** |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
24 |
* two propagation delay models, a distance-based and random model |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
25 |
* various rate control algorithms including **Aarf, Arf, Cara, Onoe, Rraa, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
26 |
ConstantRate, and Minstrel** |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
27 |
* 802.11s (mesh), described in another chapter |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
28 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
29 |
The set of 802.11 models provided in |ns3| attempts to provide an accurate |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
30 |
MAC-level implementation of the 802.11 specification and to provide a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
31 |
not-so-slow PHY-level model of the 802.11a specification. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
32 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
33 |
The implementation is modular and provides roughly four levels of models: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
34 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
35 |
* the **PHY layer models** |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
36 |
* the so-called **MAC low models**: they implement DCF and EDCAF |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
37 |
* the so-called **MAC high models**: they implement the MAC-level beacon |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
38 |
generation, probing, and association state machines, and |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
39 |
* a set of **Rate control algorithms** used by the MAC low models |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
40 |
|
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
41 |
There are presently three **MAC high models** that provide for the three |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
42 |
(non-mesh; the mesh equivalent, which is a sibling of these with common |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
43 |
parent ``ns3::RegularWifiMac``, is not discussed here) Wi-Fi topological |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
44 |
elements - Access Point (AP) (implemented in class ``ns3::ApWifiMac``, |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
45 |
non-AP Station (STA) (``ns3::StaWifiMac``), and STA in an Independent |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
46 |
Basic Service Set (IBSS - also commonly referred to as an ad hoc |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
47 |
network (``ns3::AdhocWifiMac``). |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
48 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
49 |
The simplest of these is ``ns3::AdhocWifiMac``, which implements a |
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
50 |
Wi-Fi MAC that does not perform any kind of beacon generation, |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
51 |
probing, or association. The ``ns3::StaWifiMac`` class implements |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
52 |
an active probing and association state machine that handles automatic |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
53 |
re-association whenever too many beacons are missed. Finally, |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
54 |
``ns3::ApWifiMac`` implements an AP that generates periodic |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
55 |
beacons, and that accepts every attempt to associate. |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
56 |
|
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
57 |
These three MAC high models share a common parent in |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
58 |
``ns3::RegularWifiMac``, which exposes, among other MAC |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
59 |
configuration, an attribute ``QosSupported`` that allows |
10139 | 60 |
configuration of 802.11e/WMM-style QoS support and an attribute "HtSupported" that allows configuration og 802.11n High Throughput style support. With QoS-enabled MAC |
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
61 |
models it is possible to work with traffic belonging to four different |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
62 |
Access Categories (ACs): **AC_VO** for voice traffic, |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
63 |
**AC_VI** for video traffic, **AC_BE** for best-effort |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
64 |
traffic and **AC_BK** for background traffic. In order for the |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
65 |
MAC to determine the appropriate AC for an MSDU, packets forwarded |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
66 |
down to these MAC layers should be marked using **ns3::QosTag** in |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
67 |
order to set a TID (traffic id) for that packet otherwise it will be |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
68 |
considered belonging to **AC_BE**. |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
69 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
70 |
The **MAC low layer** is split into three components: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
71 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
72 |
#. ``ns3::MacLow`` which takes care of RTS/CTS/DATA/ACK transactions. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
73 |
#. ``ns3::DcfManager`` and ``ns3::DcfState`` which implements the DCF and EDCAF |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
74 |
functions. |
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
75 |
#. ``ns3::DcaTxop`` and ``ns3::EdcaTxopN`` which handle the packet queue, |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
76 |
packet fragmentation, and packet retransmissions if they are needed. |
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
77 |
The ``ns3::DcaTxop`` object is used high MACs that are not QoS-enabled, |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
78 |
and for transmission of frames (e.g., of type Management) |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
79 |
that the standard says should access the medium using the DCF. |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
80 |
``ns3::EdcaTxopN`` is is used by QoS-enabled high MACs and also |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
81 |
performs QoS operations like 802.11n-style MSDU aggregation. |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
82 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
83 |
There are also several **rate control algorithms** that can be used by the Mac low layer: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
84 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
85 |
* ``OnoeWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
86 |
* ``IdealWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
87 |
* ``AarfcdWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
88 |
* ``AarfWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
89 |
* ``ArfWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
90 |
* ``AmrrWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
91 |
* ``ConstantRateWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
92 |
* ``MinstrelWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
93 |
* ``CaraWifiManager`` |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
94 |
* ``RraaWifiManager`` |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
95 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
96 |
The PHY layer implements a single model in the ``ns3::WifiPhy class``: the |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
97 |
physical layer model implemented there is described fully in a paper entitled |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
98 |
`Yet Another Network Simulator <http://cutebugs.net/files/wns2-yans.pdf>`_ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
99 |
Validation results for 802.11b are available in this |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
100 |
`technical report <http://www.nsnam.org/~pei/80211b.pdf>`_ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
101 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
102 |
In |ns3|, nodes can have multiple WifiNetDevices on separate channels, and the |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
103 |
WifiNetDevice can coexist with other device types; this removes an architectural |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
104 |
limitation found in ns-2. Presently, however, there is no model for |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
105 |
cross-channel interference or coupling. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
106 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
107 |
The source code for the Wifi NetDevice lives in the directory |
7145
a925e518220b
Rescan wifi's bindings and fix some paths in the documentation
Mitch Watrous <watrous@u.washington.edu>
parents:
7138
diff
changeset
|
108 |
``src/wifi``. |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
109 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
110 |
.. _wifi-architecture: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
111 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
112 |
.. figure:: figures/WifiArchitecture.* |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
113 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
114 |
Wifi NetDevice architecture. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
115 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
116 |
Using the WifiNetDevice |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
117 |
*********************** |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
118 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
119 |
The modularity provided by the implementation makes low-level configuration of |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
120 |
the WifiNetDevice powerful but complex. For this reason, we provide some helper |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
121 |
classes to perform common operations in a simple matter, and leverage the |ns3| |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
122 |
attribute system to allow users to control the parametrization of the underlying |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
123 |
models. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
124 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
125 |
Users who use the low-level |ns3| API and who wish to add a WifiNetDevice to |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
126 |
their node must create an instance of a WifiNetDevice, plus a number of |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
127 |
constituent objects, and bind them together appropriately (the WifiNetDevice is |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
128 |
very modular in this regard, for future extensibility). At the low-level API, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
129 |
this can be done with about 20 lines of code (see ``ns3::WifiHelper::Install``, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
130 |
and ``ns3::YansWifiPhyHelper::Create``). They also must create, at some point, a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
131 |
WifiChannel, which also contains a number of constituent objects (see |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
132 |
``ns3::YansWifiChannelHelper::Create``). |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
133 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
134 |
However, a few helpers are available for users to add these devices and channels |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
135 |
with only a few lines of code, if they are willing to use defaults, and the |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
136 |
helpers provide additional API to allow the passing of attribute values to |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
137 |
change default values. The scripts in ``src/examples`` can be browsed to see how |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
138 |
this is done. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
139 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
140 |
YansWifiChannelHelper |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
141 |
+++++++++++++++++++++ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
142 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
143 |
The YansWifiChannelHelper has an unusual name. Readers may wonder why it is |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
144 |
named this way. The reference is to the `yans simulator |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
145 |
<http://cutebugs.net/files/wns2-yans.pdf>`_ from which this model is taken. The |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
146 |
helper can be used to create a WifiChannel with a default PropagationLoss and |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
147 |
PropagationDelay model. Specifically, the default is a channel model with a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
148 |
propagation delay equal to a constant, the speed of light, and a propagation |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
149 |
loss based on a log distance model with a reference loss of 46.6777 dB at |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
150 |
reference distance of 1m. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
151 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
152 |
Users will typically type code such as::: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
153 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
154 |
YansWifiChannelHelper wifiChannelHelper = YansWifiChannelHelper::Default (); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
155 |
Ptr<WifiChannel> wifiChannel = wifiChannelHelper.Create (); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
156 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
157 |
to get the defaults. Note the distinction above in creating a helper object vs. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
158 |
an actual simulation object. In |ns3|, helper objects (used at the helper API |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
159 |
only) are created on the stack (they could also be created with operator new and |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
160 |
later deleted). However, the actual |ns3| objects typically inherit from |
7665
a9d19a94df20
clear warnings in model library build process
Tom Henderson <tomh@tomh.org>
parents:
7332
diff
changeset
|
161 |
``class ns3::Object`` and are assigned to a smart pointer. See the chapter in |
a9d19a94df20
clear warnings in model library build process
Tom Henderson <tomh@tomh.org>
parents:
7332
diff
changeset
|
162 |
the |ns3| manual for a discussion of the |ns3| object model, if you are not |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
163 |
familiar with it. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
164 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
165 |
*Todo: Add notes about how to configure attributes with this helper API* |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
166 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
167 |
YansWifiPhyHelper |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
168 |
+++++++++++++++++ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
169 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
170 |
Physical devices (base class ``ns3::Phy``) connect to ``ns3::Channel`` models in |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
171 |
|ns3|. We need to create Phy objects appropriate for the YansWifiChannel; here |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
172 |
the ``YansWifiPhyHelper`` will do the work. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
173 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
174 |
The YansWifiPhyHelper class configures an object factory to create instances of |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
175 |
a ``YansWifiPhy`` and adds some other objects to it, including possibly a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
176 |
supplemental ErrorRateModel and a pointer to a MobilityModel. The user code is |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
177 |
typically::: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
178 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
179 |
YansWifiPhyHelper wifiPhyHelper = YansWifiPhyHelper::Default (); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
180 |
wifiPhyHelper.SetChannel (wifiChannel); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
181 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
182 |
Note that we haven't actually created any WifiPhy objects yet; we've just |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
183 |
prepared the YansWifiPhyHelper by telling it which channel it is connected to. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
184 |
The phy objects are created in the next step. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
185 |
|
10139 | 186 |
To enable 802.11n High Throughput style parameters the following line of code could be used |
187 |
wifiPhyHelper.Set ("ShortGuardEnabled",BooleanValue(true)); |
|
188 |
wifiPhyHelper.Set ("GreenfieldEnabled",BooleanValue(true)); |
|
189 |
||
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
190 |
NqosWifiMacHelper and QosWifiMacHelper |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
191 |
++++++++++++++++++++++++++++++++++++++ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
192 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
193 |
The ``ns3::NqosWifiMacHelper`` and ``ns3::QosWifiMacHelper`` configure an |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
194 |
object factory to create instances of a ``ns3::WifiMac``. They are used to |
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
195 |
configure MAC parameters like type of MAC. |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
196 |
|
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
197 |
The former, ``ns3::NqosWifiMacHelper``, supports creation of MAC |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
198 |
instances that do not have 802.11e/WMM-style QoS support enabled. |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
199 |
|
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
200 |
For example the following user code configures a non-QoS MAC that |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
201 |
will be a non-AP STA in an infrastructure network where the AP has |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
202 |
SSID ``ns-3-ssid``::: |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
203 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
204 |
NqosWifiMacHelper wifiMacHelper = NqosWifiMacHelper::Default (); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
205 |
Ssid ssid = Ssid ("ns-3-ssid"); |
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
206 |
wifiMacHelper.SetType ("ns3::StaWifiMac", |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
207 |
"Ssid", SsidValue (ssid), |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
208 |
"ActiveProbing", BooleanValue (false)); |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
209 |
|
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
210 |
To create MAC instances with QoS support enabled, |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
211 |
``ns3::QosWifiMacHelper`` is used in place of |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
212 |
``ns3::NqosWifiMacHelper``. This object can be also used to set: |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
213 |
|
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
214 |
* a MSDU aggregator for a particular Access Category (AC) in order to use |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
215 |
802.11n MSDU aggregation feature; |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
216 |
* block ack parameters like threshold (number of packets for which block ack |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
217 |
mechanism should be used) and inactivity timeout. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
218 |
|
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
219 |
The following code shows an example use of ``ns3::QosWifiMacHelper`` to |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
220 |
create an AP with QoS enabled, aggregation on AC_VO, and Block Ack on AC_BE::: |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
221 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
222 |
QosWifiMacHelper wifiMacHelper = QosWifiMacHelper::Default (); |
6751
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
223 |
wifiMacHelper.SetType ("ns3::ApWifiMac", |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
224 |
"Ssid", SsidValue (ssid), |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
225 |
"BeaconGeneration", BooleanValue (true), |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
226 |
"BeaconInterval", TimeValue (Seconds (2.5))); |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
227 |
wifiMacHelper.SetMsduAggregatorForAc (AC_VO, "ns3::MsduStandardAggregator", |
700a92acb8ec
add back manual changes made since ns-3.9
Tom Henderson <tomh@tomh.org>
parents:
6742
diff
changeset
|
228 |
"MaxAmsduSize", UintegerValue (3839)); |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
229 |
wifiMacHelper.SetBlockAckThresholdForAc (AC_BE, 10); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
230 |
wifiMacHelper.SetBlockAckInactivityTimeoutForAc (AC_BE, 5); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
231 |
|
10139 | 232 |
HtWifiMacHelper |
233 |
+++++++++++++++ |
|
234 |
||
235 |
The ``ns3::HtWifiMacHelper``configures an |
|
236 |
object factory to create instances of a ``ns3::WifiMac``. It is used to |
|
237 |
supports creation of MAC instances that have 802.11n-style High throughput (Ht) and QoS support enabled. |
|
238 |
||
239 |
For example the following user code configures a HT MAC that |
|
240 |
will be a non-AP STA in an infrastructure network where the AP has |
|
241 |
SSID ``ns-3-ssid``::: |
|
242 |
||
243 |
HtWifiMacHelper wifiMacHelper = HtWifiMacHelper::Default (); |
|
244 |
Ssid ssid = Ssid ("ns-3-ssid"); |
|
245 |
wifiMacHelper.SetType ("ns3::StaWifiMac", |
|
246 |
"Ssid", SsidValue (ssid), |
|
247 |
"ActiveProbing", BooleanValue (false)); |
|
248 |
||
249 |
This object can be also used to set in the same way as ``ns3::QosWifiMacHelper`` |
|
250 |
||
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
251 |
WifiHelper |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
252 |
++++++++++ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
253 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
254 |
We're now ready to create WifiNetDevices. First, let's create |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
255 |
a WifiHelper with default settings::: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
256 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
257 |
WifiHelper wifiHelper = WifiHelper::Default (); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
258 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
259 |
What does this do? It sets the RemoteStationManager to |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
260 |
``ns3::ArfWifiManager``. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
261 |
Now, let's use the wifiPhyHelper and wifiMacHelper created above to install WifiNetDevices |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
262 |
on a set of nodes in a NodeContainer "c"::: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
263 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
264 |
NetDeviceContainer wifiContainer = WifiHelper::Install (wifiPhyHelper, wifiMacHelper, c); |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
265 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
266 |
This creates the WifiNetDevice which includes also a WifiRemoteStationManager, a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
267 |
WifiMac, and a WifiPhy (connected to the matching WifiChannel). |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
268 |
|
7665
a9d19a94df20
clear warnings in model library build process
Tom Henderson <tomh@tomh.org>
parents:
7332
diff
changeset
|
269 |
There are many |ns3| attributes that can be set on the above helpers to |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
270 |
deviate from the default behavior; the example scripts show how to do some of |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
271 |
this reconfiguration. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
272 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
273 |
AdHoc WifiNetDevice configuration |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
274 |
+++++++++++++++++++++++++++++++++ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
275 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
276 |
This is a typical example of how a user might configure an adhoc network. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
277 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
278 |
*To be completed* |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
279 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
280 |
Infrastructure (Access Point and clients) WifiNetDevice configuration |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
281 |
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
282 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
283 |
This is a typical example of how a user might configure an access point and a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
284 |
set of clients. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
285 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
286 |
*To be completed* |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
287 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
288 |
The WifiChannel and WifiPhy models |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
289 |
********************************** |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
290 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
291 |
The WifiChannel subclass can be used to connect together a set of |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
292 |
``ns3::WifiNetDevice`` network interfaces. The class ``ns3::WifiPhy`` is the |
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
293 |
object within the WifiNetDevice that receives bits from the channel. |
7665
a9d19a94df20
clear warnings in model library build process
Tom Henderson <tomh@tomh.org>
parents:
7332
diff
changeset
|
294 |
For the channel propagation modeling, the propagation module is used; see section :ref:`Propagation` for details. |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
295 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
296 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
297 |
This section summarizes the description of the BER calculations found in the |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
298 |
yans paper taking into account the Forward Error Correction present in 802.11a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
299 |
and describes the algorithm we implemented to decide whether or not a packet can |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
300 |
be successfully received. See `"Yet Another Network Simulator" |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
301 |
<http://cutebugs.net/files/wns2-yans.pdf>`_ for more details. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
302 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
303 |
The PHY layer can be in one of three states: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
304 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
305 |
#. TX: the PHY is currently transmitting a signal on behalf of its associated |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
306 |
MAC |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
307 |
#. RX: the PHY is synchronized on a signal and is waiting until it has received |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
308 |
its last bit to forward it to the MAC. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
309 |
#. IDLE: the PHY is not in the TX or RX states. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
310 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
311 |
When the first bit of a new packet is received while the PHY is not IDLE (that |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
312 |
is, it is already synchronized on the reception of another earlier packet or it |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
313 |
is sending data itself), the received packet is dropped. Otherwise, if the PHY |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
314 |
is IDLE, we calculate the received energy of the first bit of this new signal |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
315 |
and compare it against our Energy Detection threshold (as defined by the Clear |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
316 |
Channel Assessment function mode 1). If the energy of the packet k is higher, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
317 |
then the PHY moves to RX state and schedules an event when the last bit of the |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
318 |
packet is expected to be received. Otherwise, the PHY stays in IDLE state and |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
319 |
drops the packet. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
320 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
321 |
The energy of the received signal is assumed to be zero outside of the reception |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
322 |
interval of packet k and is calculated from the transmission power with a |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
323 |
path-loss propagation model in the reception interval. where the path loss |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
324 |
exponent, :math:`n`, is chosen equal to :math:`3`, the reference distance, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
325 |
:math:`d_0` is choosen equal to :math:`1.0m` and the reference energy is based |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
326 |
based on a Friis propagation model. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
327 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
328 |
When the last bit of the packet upon which the PHY is synchronized is received, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
329 |
we need to calculate the probability that the packet is received with any error |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
330 |
to decide whether or not the packet on which we were synchronized could be |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
331 |
successfully received or not: a random number is drawn from a uniform |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
332 |
distribution and is compared against the probability of error. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
333 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
334 |
To evaluate the probability of error, we start from the piecewise linear |
6766 | 335 |
functions shown in Figure :ref:`snir` and calculate the |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
336 |
SNIR function. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
337 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
338 |
.. _snir: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
339 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
340 |
.. figure:: figures/snir.* |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
341 |
|
6766 | 342 |
*SNIR function over time.* |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
343 |
|
7332
5ff75a2fe637
added ref to [pei80211ofdm] in wifi doc
Nicola Baldo <nbaldo@cttc.es>
parents:
7204
diff
changeset
|
344 |
From the SNIR function we can derive the Bit Error Rate (BER) and Packet Error Rate (PER) for the modulation and coding scheme being used for the transmission. Please refer to [pei80211ofdm]_, [pei80211b]_ and [lacage2006yans]_ for a detailed description of the available BER/PER models. |
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
345 |
|
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
346 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
347 |
WifiChannel configuration |
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
348 |
++++++++++++++++++++++++++ |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
349 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
350 |
The WifiChannel implementation uses the propagation loss and delay models provided within the ns-3 *propagation* module. |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
351 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
352 |
The MAC model |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
353 |
************* |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
354 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
355 |
The 802.11 Distributed Coordination Function is used to calculate when to grant |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
356 |
access to the transmission medium. While implementing the DCF would have been |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
357 |
particularly easy if we had used a recurring timer that expired every slot, we |
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
358 |
chose to use the method described in [ji2004sslswn]_ |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
359 |
where the backoff timer duration is lazily calculated whenever needed since it |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
360 |
is claimed to have much better performance than the simpler recurring timer |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
361 |
solution. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
362 |
|
9136
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
363 |
The backoff procedure of DCF is described in section 9.2.5.2 of [ieee80211]_. |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
364 |
|
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
365 |
* “The backoff procedure shall be invoked for a STA to transfer a frame |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
366 |
when finding the medium busy as indicated by either the physical or |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
367 |
virtual CS mechanism.” |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
368 |
* “A backoff procedure shall be performed immediately after the end of |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
369 |
every transmission with the More Fragments bit set to 0 of an MPDU of |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
370 |
type Data, Management, or Control with subtype PS-Poll, even if no |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
371 |
additional transmissions are currently queued.” |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
372 |
|
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
373 |
Thus, if the queue is empty, a newly arrived packet should be transmitted |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
374 |
immediately after channel is sensed idle for DIFS. If queue is not empty |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
375 |
and after a successful MPDU that has no more fragments, a node should |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
376 |
also start the backoff timer. |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
377 |
|
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
378 |
Some users have observed that the 802.11 MAC with an empty queue on an |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
379 |
idle channel will transmit the first frame arriving to the model |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
380 |
immediately without waiting for DIFS or backoff, and wonder whether this |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
381 |
is compliant. According to the standard, “The backoff procedure shall |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
382 |
be invoked for a STA to transfer a frame when finding the medium busy |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
383 |
as indicated by either the physical or virtual CS mechanism.” So in |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
384 |
this case, the medium is not found to be busy in recent past and the |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
385 |
station can transmit immediately. |
96b16f69f91b
add some more documentation on DCF operation
Gary Pei <guangyu.pei@boeing.com>
parents:
7665
diff
changeset
|
386 |
|
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
387 |
The higher-level MAC functions are implemented in a set of other C++ classes and |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
388 |
deal with: |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
389 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
390 |
* packet fragmentation and defragmentation, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
391 |
* use of the rts/cts protocol, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
392 |
* rate control algorithm, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
393 |
* connection and disconnection to and from an Access Point, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
394 |
* the MAC transmission queue, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
395 |
* beacon generation, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
396 |
* msdu aggregation, |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
397 |
* etc. |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
398 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
399 |
Wifi Attributes |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
400 |
*************** |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
401 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
402 |
Should link to the list of attributes exported by Doxygen |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
403 |
|
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
404 |
Wifi Tracing |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
405 |
************ |
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
406 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
407 |
Should link to the list of traces exported by Doxygen |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
408 |
|
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
409 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
410 |
References |
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
411 |
********** |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
412 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
413 |
.. [ieee80211] IEEE Std 802.11-2007 *Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specifications* |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
414 |
|
7332
5ff75a2fe637
added ref to [pei80211ofdm] in wifi doc
Nicola Baldo <nbaldo@cttc.es>
parents:
7204
diff
changeset
|
415 |
.. [pei80211b] \G. Pei and Tom Henderson, `Validation of ns-3 802.11b PHY model <http://www.nsnam.org/~pei/80211b.pdf>`__ |
5ff75a2fe637
added ref to [pei80211ofdm] in wifi doc
Nicola Baldo <nbaldo@cttc.es>
parents:
7204
diff
changeset
|
416 |
|
5ff75a2fe637
added ref to [pei80211ofdm] in wifi doc
Nicola Baldo <nbaldo@cttc.es>
parents:
7204
diff
changeset
|
417 |
.. [pei80211ofdm] \G. Pei and Tom Henderson, `Validation of OFDM error rate model in ns-3 <http://www.nsnam.org/~pei/80211ofdm.pdf>`__ |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
418 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
419 |
.. [lacage2006yans] \M. Lacage and T. Henderson, `Yet another Network Simulator <http://cutebugs.net/files/wns2-yans.pdf>`__ |
6742
a1759a95842c
convert manual to sphinx format
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
420 |
|
7138
90f585e0fcea
generic wifi doc only in manual
Nicola Baldo <nbaldo@cttc.es>
parents:
6766
diff
changeset
|
421 |
.. [ji2004sslswn] \Z. Ji, J. Zhou, M. Takai and R. Bagrodia, *Scalable simulation of large-scale wireless networks with bounded inaccuracies*, in Proc. of the Seventh ACM Symposium on Modeling, Analysis and Simulation of Wireless and Mobile Systems, October 2004. |