55 beacons, and that accepts every attempt to associate. |
55 beacons, and that accepts every attempt to associate. |
56 |
56 |
57 These three MAC high models share a common parent in |
57 These three MAC high models share a common parent in |
58 ``ns3::RegularWifiMac``, which exposes, among other MAC |
58 ``ns3::RegularWifiMac``, which exposes, among other MAC |
59 configuration, an attribute ``QosSupported`` that allows |
59 configuration, an attribute ``QosSupported`` that allows |
60 configuration of 802.11e/WMM-style QoS support. With QoS-enabled MAC |
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 |
61 models it is possible to work with traffic belonging to four different |
61 models it is possible to work with traffic belonging to four different |
62 Access Categories (ACs): **AC_VO** for voice traffic, |
62 Access Categories (ACs): **AC_VO** for voice traffic, |
63 **AC_VI** for video traffic, **AC_BE** for best-effort |
63 **AC_VI** for video traffic, **AC_BE** for best-effort |
64 traffic and **AC_BK** for background traffic. In order for the |
64 traffic and **AC_BK** for background traffic. In order for the |
65 MAC to determine the appropriate AC for an MSDU, packets forwarded |
65 MAC to determine the appropriate AC for an MSDU, packets forwarded |
181 |
181 |
182 Note that we haven't actually created any WifiPhy objects yet; we've just |
182 Note that we haven't actually created any WifiPhy objects yet; we've just |
183 prepared the YansWifiPhyHelper by telling it which channel it is connected to. |
183 prepared the YansWifiPhyHelper by telling it which channel it is connected to. |
184 The phy objects are created in the next step. |
184 The phy objects are created in the next step. |
185 |
185 |
|
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 |
186 NqosWifiMacHelper and QosWifiMacHelper |
190 NqosWifiMacHelper and QosWifiMacHelper |
187 ++++++++++++++++++++++++++++++++++++++ |
191 ++++++++++++++++++++++++++++++++++++++ |
188 |
192 |
189 The ``ns3::NqosWifiMacHelper`` and ``ns3::QosWifiMacHelper`` configure an |
193 The ``ns3::NqosWifiMacHelper`` and ``ns3::QosWifiMacHelper`` configure an |
190 object factory to create instances of a ``ns3::WifiMac``. They are used to |
194 object factory to create instances of a ``ns3::WifiMac``. They are used to |
223 wifiMacHelper.SetMsduAggregatorForAc (AC_VO, "ns3::MsduStandardAggregator", |
227 wifiMacHelper.SetMsduAggregatorForAc (AC_VO, "ns3::MsduStandardAggregator", |
224 "MaxAmsduSize", UintegerValue (3839)); |
228 "MaxAmsduSize", UintegerValue (3839)); |
225 wifiMacHelper.SetBlockAckThresholdForAc (AC_BE, 10); |
229 wifiMacHelper.SetBlockAckThresholdForAc (AC_BE, 10); |
226 wifiMacHelper.SetBlockAckInactivityTimeoutForAc (AC_BE, 5); |
230 wifiMacHelper.SetBlockAckInactivityTimeoutForAc (AC_BE, 5); |
227 |
231 |
|
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 |
228 WifiHelper |
251 WifiHelper |
229 ++++++++++ |
252 ++++++++++ |
230 |
253 |
231 We're now ready to create WifiNetDevices. First, let's create |
254 We're now ready to create WifiNetDevices. First, let's create |
232 a WifiHelper with default settings::: |
255 a WifiHelper with default settings::: |