A Discrete-Event Network Simulator
API
he-capabilities.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2016
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2 as
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Author: Sébastien Deronne <sebastien.deronne@gmail.com>
19  */
20 
21 #ifndef HE_CAPABILITIES_H
22 #define HE_CAPABILITIES_H
23 
24 #include "ns3/wifi-information-element.h"
25 
26 namespace ns3 {
27 
34 {
35 public:
36  HeCapabilities ();
37 
38  // Implementations of pure virtual methods of WifiInformationElement
39  WifiInformationElementId ElementId () const override;
40  WifiInformationElementId ElementIdExt () const override;
41  uint8_t GetInformationFieldSize () const override;
42  void SerializeInformationField (Buffer::Iterator start) const override;
43  uint8_t DeserializeInformationField (Buffer::Iterator start, uint8_t length) override;
44  /* This information element is a bit special in that it is only
45  included if the STA is an HE STA. To support this we
46  override the Serialize and GetSerializedSize methods of
47  WifiInformationElement. */
49  uint16_t GetSerializedSize () const override;
50 
55  void SetHeSupported (uint8_t heSupported);
56 
63  void SetHeMacCapabilitiesInfo (uint32_t ctrl1, uint8_t ctrl2);
70  void SetHePhyCapabilitiesInfo (uint64_t ctrl1, uint8_t ctrl2);
76  void SetSupportedMcsAndNss (uint16_t ctrl);
77 
83  uint32_t GetHeMacCapabilitiesInfo1 () const;
89  uint8_t GetHeMacCapabilitiesInfo2 () const;
95  uint64_t GetHePhyCapabilitiesInfo1 () const;
101  uint8_t GetHePhyCapabilitiesInfo2 () const;
107  uint16_t GetSupportedMcsAndNss () const;
108 
109  // PHY Capabilities Info fields
115  void SetChannelWidthSet (uint8_t channelWidthSet);
121  void SetLdpcCodingInPayload (uint8_t ldpcCodingInPayload);
127  void SetHeLtfAndGiForHePpdus (uint8_t heLtfAndGiForHePpdus);
133  uint8_t GetChannelWidthSet (void) const;
139  uint8_t GetLdpcCodingInPayload (void) const;
145  uint8_t GetHeLtfAndGiForHePpdus (void) const;
151  uint8_t GetHighestMcsSupported (void) const;
157  uint8_t GetHighestNssSupported (void) const;
158 
159  // MAC Capabilities Info fields
165  void SetMaxAmpduLength (uint32_t maxAmpduLength);
166 
167  // MCS and NSS field information
173  void SetHighestMcsSupported (uint8_t mcs);
179  void SetHighestNssSupported (uint8_t nss);
180 
187  bool IsSupportedTxMcs (uint8_t mcs) const;
194  bool IsSupportedRxMcs (uint8_t mcs) const;
195 
201  uint32_t GetMaxAmpduLength (void) const;
202 
203 
204 private:
205  //MAC Capabilities Info fields
215  uint8_t m_allAckSupport;
217  uint8_t m_aBsrSupport;
230  uint8_t m_qtpSupport;
231  uint8_t m_aBqrSupport;
232 
233  //PHY Capabilities Info fields
237  uint8_t m_deviceClass;
241  uint8_t m_stbcTxAndRx;
242  uint8_t m_doppler;
243  uint8_t m_ulMu;
244  uint8_t m_dcmEncodingTx;
245  uint8_t m_dcmEncodingRx;
247  uint8_t m_suBeamformer;
248  uint8_t m_suBeamformee;
249  uint8_t m_muBeamformer;
267 
268  //MCS and NSS field information
271  std::vector<uint8_t> m_txBwMap;
272  std::vector<uint8_t> m_rxBwMap;
273 
275  uint8_t m_heSupported;
276 };
277 
284 std::ostream &operator << (std::ostream &os, const HeCapabilities &HeCapabilities);
285 
286 } //namespace ns3
287 
288 #endif /* HE_CAPABILITY_H */
ns3::HeCapabilities::m_aBqrSupport
uint8_t m_aBqrSupport
ABQR support.
Definition: he-capabilities.h:231
ns3::HeCapabilities::m_multiTidAggregationSupport
uint8_t m_multiTidAggregationSupport
multi-TID aggregation support
Definition: he-capabilities.h:213
ns3::HeCapabilities::m_ldpcCodingInPayload
uint8_t m_ldpcCodingInPayload
LDPC coding in payload.
Definition: he-capabilities.h:238
ns3::HeCapabilities::m_plusHtcHeSupport
uint8_t m_plusHtcHeSupport
HTC HE support.
Definition: he-capabilities.h:206
ns3::HeCapabilities::SerializeInformationField
void SerializeInformationField(Buffer::Iterator start) const override
Serialize information (i.e., the body of the IE, not including the Element ID and length octets)
Definition: he-capabilities.cc:141
ns3::HeCapabilities::m_dcmEncodingTx
uint8_t m_dcmEncodingTx
DCM encoding transmit.
Definition: he-capabilities.h:244
ns3::HeCapabilities::ElementId
WifiInformationElementId ElementId() const override
Definition: he-capabilities.cc:95
ns3::HeCapabilities::m_ulMuResponseSchedulingSupport
uint8_t m_ulMuResponseSchedulingSupport
UL MU response scheduling support.
Definition: he-capabilities.h:216
ns3::HeCapabilities::m_aBsrSupport
uint8_t m_aBsrSupport
BSR support.
Definition: he-capabilities.h:217
ns3::HeCapabilities::m_numberOfSoundingDimensionsForLargerThan80Mhz
uint8_t m_numberOfSoundingDimensionsForLargerThan80Mhz
Definition: he-capabilities.h:255
ns3::HeCapabilities::DeserializeInformationField
uint8_t DeserializeInformationField(Buffer::Iterator start, uint8_t length) override
Deserialize information (i.e., the body of the IE, not including the Element ID and length octets)
Definition: he-capabilities.cc:157
ns3::HeCapabilities::m_ngEqual16ForMuFeedbackSupport
uint8_t m_ngEqual16ForMuFeedbackSupport
equal 16 for MU feedback
Definition: he-capabilities.h:257
ns3::HeCapabilities::m_4TimesHeLtfAnd800NsGiSupportForHePpdus
uint8_t m_4TimesHeLtfAnd800NsGiSupportForHePpdus
4 times HE-LFT and 800ns GI support for HE-PPDUs
Definition: he-capabilities.h:266
ns3::HeCapabilities::SetHeSupported
void SetHeSupported(uint8_t heSupported)
Set HE supported.
Definition: he-capabilities.cc:107
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::HeCapabilities::m_doppler
uint8_t m_doppler
Doppler.
Definition: he-capabilities.h:242
ns3::HeCapabilities::ElementIdExt
WifiInformationElementId ElementIdExt() const override
Definition: he-capabilities.cc:101
ns3::HeCapabilities::m_powerBoostFactorAlphaSupport
uint8_t m_powerBoostFactorAlphaSupport
power boost factor alpha support
Definition: he-capabilities.h:265
ns3::HeCapabilities::GetInformationFieldSize
uint8_t GetInformationFieldSize() const override
Length of serialized information (i.e., the length of the body of the IE, not including the Element I...
Definition: he-capabilities.cc:113
ns3::HeCapabilities::SetHeLtfAndGiForHePpdus
void SetHeLtfAndGiForHePpdus(uint8_t heLtfAndGiForHePpdus)
Set HE LTF and GI for HE PDPUs.
Definition: he-capabilities.cc:436
ns3::HeCapabilities::m_ofdmaRaSupport
uint8_t m_ofdmaRaSupport
OFDMA RA support.
Definition: he-capabilities.h:224
ns3::HeCapabilities::GetHeMacCapabilitiesInfo1
uint32_t GetHeMacCapabilitiesInfo1() const
Return the 4 first octets of the HE MAC Capabilities Info field in the HE Capabilities information el...
Definition: he-capabilities.cc:205
ns3::HeCapabilities::SetHighestNssSupported
void SetHighestNssSupported(uint8_t nss)
Set highest NSS supported.
Definition: he-capabilities.cc:464
ns3::HeCapabilities::m_nstsTotalForSmallerOrEqualThan80Mhz
uint8_t m_nstsTotalForSmallerOrEqualThan80Mhz
STS total for < 80 MHz.
Definition: he-capabilities.h:251
ns3::WifiInformationElement
Information element, as defined in 802.11-2007 standard.
Definition: wifi-information-element.h:234
ns3::HeCapabilities::SetHeMacCapabilitiesInfo
void SetHeMacCapabilitiesInfo(uint32_t ctrl1, uint8_t ctrl2)
Set the HE MAC Capabilities Info field in the HE Capabilities information element.
Definition: he-capabilities.cc:174
ns3::HeCapabilities::m_ngEqual16ForSuFeedbackSupport
uint8_t m_ngEqual16ForSuFeedbackSupport
equal 16 for SU feedback
Definition: he-capabilities.h:256
ns3::HeCapabilities::m_broadcastTwtSupport
uint8_t m_broadcastTwtSupport
broadcast TXT support
Definition: he-capabilities.h:218
ns3::HeCapabilities::SetSupportedMcsAndNss
void SetSupportedMcsAndNss(uint16_t ctrl)
Set the MCS and NSS field in the HE Capabilities information element.
Definition: he-capabilities.cc:330
ns3::HeCapabilities
The IEEE 802.11ax HE Capabilities.
Definition: he-capabilities.h:34
ns3::HeCapabilities::m_triggerFrameMacPaddingDuration
uint8_t m_triggerFrameMacPaddingDuration
trigger frame MAC padding duration
Definition: he-capabilities.h:212
ns3::HeCapabilities::IsSupportedTxMcs
bool IsSupportedTxMcs(uint8_t mcs) const
Is RX MCS supported.
Definition: he-capabilities.cc:369
ns3::HeCapabilities::m_allAckSupport
uint8_t m_allAckSupport
all Ack support
Definition: he-capabilities.h:215
ns3::HeCapabilities::m_heLinkAdaptation
uint8_t m_heLinkAdaptation
HE link adaptation.
Definition: he-capabilities.h:214
ns3::WifiInformationElementId
uint8_t WifiInformationElementId
This type is used to represent an Information Element ID.
Definition: wifi-information-element.h:40
ns3::HeCapabilities::m_fragmentationSupport
uint8_t m_fragmentationSupport
fragmentation support
Definition: he-capabilities.h:209
ns3::HeCapabilities::m_ulHeMuPpduPayloadSupport
uint8_t m_ulHeMuPpduPayloadSupport
UL HE-MU-PDPU payload support.
Definition: he-capabilities.h:246
ns3::HeCapabilities::m_highestMcsSupported
uint8_t m_highestMcsSupported
highest MCS support
Definition: he-capabilities.h:270
ns3::HeCapabilities::HeCapabilities
HeCapabilities()
Definition: he-capabilities.cc:26
ns3::HeCapabilities::m_deviceClass
uint8_t m_deviceClass
device class
Definition: he-capabilities.h:237
ns3::HeCapabilities::m_ppeThresholdPresent
uint8_t m_ppeThresholdPresent
PPE threshold present.
Definition: he-capabilities.h:263
ns3::HeCapabilities::m_qtpSupport
uint8_t m_qtpSupport
QTP support.
Definition: he-capabilities.h:230
ns3::HeCapabilities::SetMaxAmpduLength
void SetMaxAmpduLength(uint32_t maxAmpduLength)
Set the maximum AMPDU length.
Definition: he-capabilities.cc:443
ns3::HeCapabilities::GetHePhyCapabilitiesInfo1
uint64_t GetHePhyCapabilitiesInfo1() const
Return the 8 first octets of the HE PHY Capabilities Info field in the HE Capabilities information el...
Definition: he-capabilities.cc:283
visualizer.core.start
def start()
Definition: core.py:1855
ns3::HeCapabilities::m_amsduFragmentationSupport
uint8_t m_amsduFragmentationSupport
A-MSDU fragmentation support.
Definition: he-capabilities.h:226
ns3::HeCapabilities::SetHighestMcsSupported
void SetHighestMcsSupported(uint8_t mcs)
Set highest MCS supported.
Definition: he-capabilities.cc:457
ns3::HeCapabilities::m_groupAddressedMultiStaBlockAckInDlMuSupport
uint8_t m_groupAddressedMultiStaBlockAckInDlMuSupport
group addressed multi-STA BlockAck in DL support
Definition: he-capabilities.h:222
ns3::HeCapabilities::m_suBeamformee
uint8_t m_suBeamformee
SU beamformee.
Definition: he-capabilities.h:248
ns3::HeCapabilities::m_stbcTxAndRx
uint8_t m_stbcTxAndRx
STBC transmit and receive.
Definition: he-capabilities.h:241
ns3::HeCapabilities::GetHeMacCapabilitiesInfo2
uint8_t GetHeMacCapabilitiesInfo2() const
Return the last octet of the HE MAC Capabilities Info field in the HE Capabilities information elemen...
Definition: he-capabilities.cc:235
ns3::HeCapabilities::m_flexibleTwtScheduleSupport
uint8_t m_flexibleTwtScheduleSupport
flexible TWT schedule support
Definition: he-capabilities.h:227
ns3::HeCapabilities::GetHePhyCapabilitiesInfo2
uint8_t GetHePhyCapabilitiesInfo2() const
Return the last octet of the HE PHY Capabilities Info field in the HE Capabilities information elemen...
Definition: he-capabilities.cc:322
ns3::HeCapabilities::GetChannelWidthSet
uint8_t GetChannelWidthSet(void) const
Get channel width set.
Definition: he-capabilities.cc:471
ns3::HeCapabilities::m_muBeamformer
uint8_t m_muBeamformer
MU beamformer.
Definition: he-capabilities.h:249
ns3::HeCapabilities::GetHighestMcsSupported
uint8_t GetHighestMcsSupported(void) const
Get highest MCS supported.
Definition: he-capabilities.cc:489
ns3::HeCapabilities::m_nstsTotalForLargerThan80Mhz
uint8_t m_nstsTotalForLargerThan80Mhz
STS total for > 80 MHz.
Definition: he-capabilities.h:253
ns3::HeCapabilities::m_32bitBaBitmapSupport
uint8_t m_32bitBaBitmapSupport
32-bit BA bitmap support
Definition: he-capabilities.h:219
ns3::HeCapabilities::m_codebookSize75ForSuSupport
uint8_t m_codebookSize75ForSuSupport
codebook size 75 for SU
Definition: he-capabilities.h:259
ns3::HeCapabilities::m_dcmEncodingRx
uint8_t m_dcmEncodingRx
DCM encoding receive.
Definition: he-capabilities.h:245
ns3::HeCapabilities::m_beamformeeStsForLargerThan80Mhz
uint8_t m_beamformeeStsForLargerThan80Mhz
beamformee STS for > 80MHz
Definition: he-capabilities.h:252
ns3::HeCapabilities::m_highestNssSupportedM1
uint8_t m_highestNssSupportedM1
highest NSS support M1
Definition: he-capabilities.h:269
ns3::HeCapabilities::Serialize
Buffer::Iterator Serialize(Buffer::Iterator start) const override
Serialize entire IE including Element ID and length fields.
Definition: he-capabilities.cc:121
ns3::HeCapabilities::m_bsrpAmpduAggregation
uint8_t m_bsrpAmpduAggregation
BSRP A-MPDU aggregation.
Definition: he-capabilities.h:229
ns3::HeCapabilities::m_suBeamformer
uint8_t m_suBeamformer
SU beamformer.
Definition: he-capabilities.h:247
ns3::HeCapabilities::m_numberOfSoundingDimensionsForSmallerOrEqualThan80Mhz
uint8_t m_numberOfSoundingDimensionsForSmallerOrEqualThan80Mhz
Definition: he-capabilities.h:254
ns3::HeCapabilities::m_ulMu
uint8_t m_ulMu
UL MU.
Definition: he-capabilities.h:243
ns3::HeCapabilities::m_dualBandSupport
uint8_t m_dualBandSupport
dual band support
Definition: he-capabilities.h:234
ns3::Buffer::Iterator
iterator in a Buffer instance
Definition: buffer.h:99
ns3::HeCapabilities::GetSupportedMcsAndNss
uint16_t GetSupportedMcsAndNss() const
Return the MCS and NSS field in the HE Capabilities information element.
Definition: he-capabilities.cc:348
ns3::HeCapabilities::m_maximumNumberOfFragmentedMsdus
uint8_t m_maximumNumberOfFragmentedMsdus
maximum number of fragmentation MSDUs
Definition: he-capabilities.h:210
ns3::HeCapabilities::m_beamformeeStsForSmallerOrEqualThan80Mhz
uint8_t m_beamformeeStsForSmallerOrEqualThan80Mhz
beam formee STS for < 80 MHz
Definition: he-capabilities.h:250
ns3::HeCapabilities::m_minimumFragmentSize
uint8_t m_minimumFragmentSize
minimum fragment size
Definition: he-capabilities.h:211
ns3::HeCapabilities::SetHePhyCapabilitiesInfo
void SetHePhyCapabilitiesInfo(uint64_t ctrl1, uint8_t ctrl2)
Set the HE PHY Capabilities Info field in the HE Capabilities information element.
Definition: he-capabilities.cc:245
ns3::HeCapabilities::m_muCascadeSupport
uint8_t m_muCascadeSupport
MU cascade support.
Definition: he-capabilities.h:220
ns3::HeCapabilities::GetHighestNssSupported
uint8_t GetHighestNssSupported(void) const
Get highest NSS supported.
Definition: he-capabilities.cc:495
ns3::HeCapabilities::SetLdpcCodingInPayload
void SetLdpcCodingInPayload(uint8_t ldpcCodingInPayload)
Set indication whether the transmission and reception of LDPC encoded packets is supported.
Definition: he-capabilities.cc:430
ns3::HeCapabilities::m_rxControlFrameToMultiBss
uint8_t m_rxControlFrameToMultiBss
receive control frame to multi-BSS
Definition: he-capabilities.h:228
ns3::HeCapabilities::m_srpBasedSrSupport
uint8_t m_srpBasedSrSupport
SRP based SR support.
Definition: he-capabilities.h:264
ns3::HeCapabilities::m_preamblePuncturingRx
uint8_t m_preamblePuncturingRx
preamble puncturing receive
Definition: he-capabilities.h:236
ns3::HeCapabilities::m_beamformingFeedbackWithTriggerFrame
uint8_t m_beamformingFeedbackWithTriggerFrame
beamforming feedback with trigger frame
Definition: he-capabilities.h:260
ns3::HeCapabilities::m_channelWidthSet
uint8_t m_channelWidthSet
channel width set
Definition: he-capabilities.h:235
ns3::HeCapabilities::m_txBwMap
std::vector< uint8_t > m_txBwMap
transmit BW map
Definition: he-capabilities.h:271
ns3::HeCapabilities::m_ackEnabledMultiTidAggregationSupport
uint8_t m_ackEnabledMultiTidAggregationSupport
ack enabled multi-TID aggregation support
Definition: he-capabilities.h:221
ns3::HeCapabilities::m_maxAmpduLengthExponent
uint8_t m_maxAmpduLengthExponent
maximum A-MPDU length exponent
Definition: he-capabilities.h:225
ns3::HeCapabilities::m_twtRequesterSupport
uint8_t m_twtRequesterSupport
TWT requester support.
Definition: he-capabilities.h:207
ns3::HeCapabilities::GetMaxAmpduLength
uint32_t GetMaxAmpduLength(void) const
Return the maximum A-MPDU length.
Definition: he-capabilities.cc:501
ns3::HeCapabilities::m_heLtfAndGiForHePpdus
uint8_t m_heLtfAndGiForHePpdus
HE-LTF and GI for HE-PPDUs.
Definition: he-capabilities.h:239
ns3::HeCapabilities::GetLdpcCodingInPayload
uint8_t GetLdpcCodingInPayload(void) const
Indicates support for the transmission and reception of LDPC encoded packets.
Definition: he-capabilities.cc:477
ns3::HeCapabilities::m_heSupported
uint8_t m_heSupported
This is used to decide if this element should be added to the frame or not.
Definition: he-capabilities.h:275
ns3::HeCapabilities::m_heErSuPpduPayload
uint8_t m_heErSuPpduPayload
HE-ER-SU-PPDU payload.
Definition: he-capabilities.h:261
ns3::operator<<
std::ostream & operator<<(std::ostream &os, const Angles &a)
Definition: angles.cc:137
ns3::HeCapabilities::GetHeLtfAndGiForHePpdus
uint8_t GetHeLtfAndGiForHePpdus(void) const
Get HE LTF and GI for HE PDPUs.
Definition: he-capabilities.cc:483
ns3::HeCapabilities::m_twtResponderSupport
uint8_t m_twtResponderSupport
TWT responder support.
Definition: he-capabilities.h:208
ns3::HeCapabilities::m_codebookSize42ForSuSupport
uint8_t m_codebookSize42ForSuSupport
codebook size 42 for SU
Definition: he-capabilities.h:258
ns3::HeCapabilities::m_heLtfAndGiForNdp
uint8_t m_heLtfAndGiForNdp
HE-LTF and GI for NDP.
Definition: he-capabilities.h:240
ns3::HeCapabilities::m_rxBwMap
std::vector< uint8_t > m_rxBwMap
receive BW map
Definition: he-capabilities.h:272
ns3::HeCapabilities::IsSupportedRxMcs
bool IsSupportedRxMcs(uint8_t mcs) const
Is RX MCS supported.
Definition: he-capabilities.cc:396
ns3::HeCapabilities::GetSerializedSize
uint16_t GetSerializedSize() const override
Get the size of the serialized IE including Element ID and length fields.
Definition: he-capabilities.cc:131
ns3::HeCapabilities::SetChannelWidthSet
void SetChannelWidthSet(uint8_t channelWidthSet)
Set channel width set.
Definition: he-capabilities.cc:423
ns3::HeCapabilities::m_dlMuMimoOnPartialBandwidth
uint8_t m_dlMuMimoOnPartialBandwidth
DL MU-MIMO on partial bandwidth.
Definition: he-capabilities.h:262
ns3::HeCapabilities::m_omControlSupport
uint8_t m_omControlSupport
operation mode control support
Definition: he-capabilities.h:223