A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ns3::EhtCapabilities Class Reference

The IEEE 802.11be EHT Capabilities. More...

#include "eht-capabilities.h"

+ Inheritance diagram for ns3::EhtCapabilities:
+ Collaboration diagram for ns3::EhtCapabilities:

Public Member Functions

 EhtCapabilities ()
 Constructor.
 
 EhtCapabilities (bool is2_4Ghz, const std::optional< HeCapabilities > &heCapabilities)
 Constructor.
 
WifiInformationElementId ElementId () const override
 Get the wifi information element ID.
 
WifiInformationElementId ElementIdExt () const override
 Get the wifi information element ID extension.
 
uint8_t GetHighestSupportedRxMcs (EhtMcsAndNssSet::EhtMcsMapType mapType)
 Get the highest supported RX MCS for a given EHT-MCS map type.
 
uint8_t GetHighestSupportedTxMcs (EhtMcsAndNssSet::EhtMcsMapType mapType)
 Get the highest supported TX MCS for a given EHT-MCS map type.
 
uint32_t GetMaxAmpduLength () const
 Return the maximum A-MPDU length.
 
uint16_t GetMaxMpduLength () const
 Get the maximum MPDU length.
 
void Print (std::ostream &os) const override
 Generate human-readable form of IE.
 
void SetMaxAmpduLength (uint32_t maxAmpduLength)
 Set the maximum A-MPDU length.
 
void SetMaxMpduLength (uint16_t length)
 Set the maximum MPDU length.
 
void SetPpeThresholds (uint8_t nssPe, uint8_t ruIndexBitmask, const std::vector< std::pair< uint8_t, uint8_t > > &ppeThresholds)
 Set the EHT PPE threshold info subfield.
 
void SetSupportedRxEhtMcsAndNss (EhtMcsAndNssSet::EhtMcsMapType mapType, uint8_t upperMcs, uint8_t maxNss)
 Set a subfield of the Supported EHT-MCS And NSS Set.
 
void SetSupportedTxEhtMcsAndNss (EhtMcsAndNssSet::EhtMcsMapType mapType, uint8_t upperMcs, uint8_t maxNss)
 Set a subfield of the Supported EHT-MCS And NSS Set.
 
- Public Member Functions inherited from ns3::WifiInformationElement
virtual ~WifiInformationElement ()
 
Buffer::Iterator Deserialize (Buffer::Iterator i)
 Deserialize entire IE (which may possibly be fragmented into multiple elements), which must be present.
 
Buffer::Iterator DeserializeIfPresent (Buffer::Iterator i)
 Deserialize entire IE (which may possibly be fragmented into multiple elements) if it is present.
 
uint16_t GetSerializedSize () const
 Get the size of the serialized IE including Element ID and length fields (for every element this IE is possibly fragmented into).
 
virtual bool operator== (const WifiInformationElement &a) const
 Compare two IEs for equality by ID & Length, and then through memcmp of serialised version.
 
Buffer::Iterator Serialize (Buffer::Iterator i) const
 Serialize entire IE including Element ID and length fields.
 
- Public Member Functions inherited from ns3::SimpleRefCount< WifiInformationElement >
 SimpleRefCount ()
 Default constructor.
 
 SimpleRefCount (const SimpleRefCount &o)
 Copy constructor.
 
uint32_t GetReferenceCount () const
 Get the reference count of the object.
 
SimpleRefCountoperator= (const SimpleRefCount &o)
 Assignment operator.
 
void Ref () const
 Increment the reference count.
 
void Unref () const
 Decrement the reference count.
 

Public Attributes

EhtMacCapabilities m_macCapabilities
 EHT MAC Capabilities Info subfield.
 
EhtPhyCapabilities m_phyCapabilities
 EHT PHY Capabilities Info subfield.
 
EhtPpeThresholds m_ppeThresholds
 EHT PPE Threshold Info subfield.
 
EhtMcsAndNssSet m_supportedEhtMcsAndNssSet
 Supported EHT-MCS And NSS Set subfield.
 

Private Member Functions

uint16_t DeserializeInformationField (Buffer::Iterator start, uint16_t length) override
 Deserialize information (i.e., the body of the IE, not including the Element ID and length octets)
 
uint16_t GetInformationFieldSize () const override
 Length of serialized information (i.e., the length of the body of the IE, not including the Element ID and length octets.
 
void SerializeInformationField (Buffer::Iterator start) const override
 Serialize information (i.e., the body of the IE, not including the Element ID and length octets)
 

Private Attributes

std::optional< HeCapabilitiesm_heCapabilities
 HE capabilities contained in the same management frame if present.
 
bool m_is2_4Ghz
 flag indicating whether PHY is operating in 2.4 GHz based on other IEs contained in the same management frame
 

Detailed Description

The IEEE 802.11be EHT Capabilities.

Definition at line 236 of file eht-capabilities.h.

Constructor & Destructor Documentation

◆ EhtCapabilities() [1/2]

ns3::EhtCapabilities::EhtCapabilities ( )

Constructor.

Definition at line 383 of file eht-capabilities.cc.

◆ EhtCapabilities() [2/2]

ns3::EhtCapabilities::EhtCapabilities ( bool is2_4Ghz,
const std::optional< HeCapabilities > & heCapabilities )

Constructor.

Parameters
is2_4Ghzindicating whether PHY is operating in 2.4 GHz based on previously serialized IEs
heCapabilitiesthe optional HE capabilities contained in the same management frame

Definition at line 393 of file eht-capabilities.cc.

Member Function Documentation

◆ DeserializeInformationField()

uint16_t ns3::EhtCapabilities::DeserializeInformationField ( Buffer::Iterator start,
uint16_t length )
overrideprivatevirtual

Deserialize information (i.e., the body of the IE, not including the Element ID and length octets)

Parameters
startan iterator which points to where the information should be written.
lengththe expected number of bytes to read
Returns
the number of bytes read

Implements ns3::WifiInformationElement.

Definition at line 695 of file eht-capabilities.cc.

References ns3::EhtMacCapabilities::Deserialize(), ns3::EhtMcsAndNssSet::Deserialize(), ns3::EhtPhyCapabilities::Deserialize(), ns3::EhtPpeThresholds::Deserialize(), m_heCapabilities, m_is2_4Ghz, m_macCapabilities, m_phyCapabilities, m_ppeThresholds, m_supportedEhtMcsAndNssSet, ns3::Buffer::Iterator::Next(), NS_ASSERT, ns3::EhtPhyCapabilities::ppeThresholdsPresent, and ns3::EhtPhyCapabilities::support320MhzIn6Ghz.

+ Here is the call graph for this function:

◆ ElementId()

WifiInformationElementId ns3::EhtCapabilities::ElementId ( ) const
overridevirtual

Get the wifi information element ID.

Returns
the wifi information element ID

Implements ns3::WifiInformationElement.

Definition at line 404 of file eht-capabilities.cc.

References IE_EXTENSION.

◆ ElementIdExt()

WifiInformationElementId ns3::EhtCapabilities::ElementIdExt ( ) const
overridevirtual

Get the wifi information element ID extension.

Returns
the wifi information element ID extension

Reimplemented from ns3::WifiInformationElement.

Definition at line 410 of file eht-capabilities.cc.

References IE_EXT_EHT_CAPABILITIES.

◆ GetHighestSupportedRxMcs()

uint8_t ns3::EhtCapabilities::GetHighestSupportedRxMcs ( EhtMcsAndNssSet::EhtMcsMapType mapType)

Get the highest supported RX MCS for a given EHT-MCS map type.

Parameters
mapTypethe EHT-MCS map type
Returns
the highest supported RX MCS for the given EHT-MCS map type

Definition at line 597 of file eht-capabilities.cc.

References ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_20_MHZ_ONLY, m_supportedEhtMcsAndNssSet, NS_ASSERT, NS_ASSERT_MSG, and ns3::EhtMcsAndNssSet::supportedEhtMcsAndNssSet.

Referenced by ns3::WifiRemoteStationManager::AddStationEhtCapabilities(), and WifiEhtCapabilitiesIeTest::DoRun().

+ Here is the caller graph for this function:

◆ GetHighestSupportedTxMcs()

uint8_t ns3::EhtCapabilities::GetHighestSupportedTxMcs ( EhtMcsAndNssSet::EhtMcsMapType mapType)

Get the highest supported TX MCS for a given EHT-MCS map type.

Parameters
mapTypethe EHT-MCS map type
Returns
the highest supported TX MCS for the given EHT-MCS map type

Definition at line 632 of file eht-capabilities.cc.

References ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_20_MHZ_ONLY, m_supportedEhtMcsAndNssSet, NS_ASSERT, NS_ASSERT_MSG, and ns3::EhtMcsAndNssSet::supportedEhtMcsAndNssSet.

Referenced by WifiEhtCapabilitiesIeTest::DoRun().

+ Here is the caller graph for this function:

◆ GetInformationFieldSize()

uint16_t ns3::EhtCapabilities::GetInformationFieldSize ( ) const
overrideprivatevirtual

Length of serialized information (i.e., the length of the body of the IE, not including the Element ID and length octets.

This is the value that will appear in the second octet of the entire IE - the length field - if the IE is not fragmented)

Returns
the length of serialized information

Implements ns3::WifiInformationElement.

Definition at line 422 of file eht-capabilities.cc.

References ns3::EhtMacCapabilities::GetSize(), ns3::EhtMcsAndNssSet::GetSize(), ns3::EhtPhyCapabilities::GetSize(), ns3::EhtPpeThresholds::GetSize(), m_macCapabilities, m_phyCapabilities, m_ppeThresholds, m_supportedEhtMcsAndNssSet, and ns3::EhtPhyCapabilities::ppeThresholdsPresent.

+ Here is the call graph for this function:

◆ GetMaxAmpduLength()

uint32_t ns3::EhtCapabilities::GetMaxAmpduLength ( ) const

Return the maximum A-MPDU length.

Returns
the maximum A-MPDU length

Definition at line 485 of file eht-capabilities.cc.

References m_macCapabilities, and ns3::EhtMacCapabilities::maxAmpduLengthExponentExtension.

◆ GetMaxMpduLength()

uint16_t ns3::EhtCapabilities::GetMaxMpduLength ( ) const

Get the maximum MPDU length.

Returns
the maximum MPDU length in bytes

Definition at line 454 of file eht-capabilities.cc.

References m_macCapabilities, ns3::EhtMacCapabilities::maxMpduLength, and NS_ABORT_MSG.

◆ Print()

void ns3::EhtCapabilities::Print ( std::ostream & os) const
overridevirtual

Generate human-readable form of IE.

Parameters
osoutput stream

Reimplemented from ns3::WifiInformationElement.

Definition at line 416 of file eht-capabilities.cc.

◆ SerializeInformationField()

void ns3::EhtCapabilities::SerializeInformationField ( Buffer::Iterator start) const
overrideprivatevirtual

Serialize information (i.e., the body of the IE, not including the Element ID and length octets)

Parameters
startan iterator which points to where the information should be written.

Implements ns3::WifiInformationElement.

Definition at line 683 of file eht-capabilities.cc.

References m_macCapabilities, m_phyCapabilities, m_ppeThresholds, m_supportedEhtMcsAndNssSet, ns3::EhtPhyCapabilities::ppeThresholdsPresent, ns3::EhtMacCapabilities::Serialize(), ns3::EhtMcsAndNssSet::Serialize(), ns3::EhtPhyCapabilities::Serialize(), and ns3::EhtPpeThresholds::Serialize().

+ Here is the call graph for this function:

◆ SetMaxAmpduLength()

void ns3::EhtCapabilities::SetMaxAmpduLength ( uint32_t maxAmpduLength)

Set the maximum A-MPDU length.

Parameters
maxAmpduLength2^(23 + x) - 1, x in the range 0 to 1

Definition at line 471 of file eht-capabilities.cc.

References m_macCapabilities, ns3::EhtMacCapabilities::maxAmpduLengthExponentExtension, and NS_ABORT_MSG.

Referenced by AmpduAggregationTest::DoSetup(), ns3::WifiMac::GetEhtCapabilities(), and WifiEhtCapabilitiesIeTest::GetEhtCapabilities().

+ Here is the caller graph for this function:

◆ SetMaxMpduLength()

void ns3::EhtCapabilities::SetMaxMpduLength ( uint16_t length)

Set the maximum MPDU length.

Parameters
lengththe maximum MPDU length (3895, 7991 or 11454)

Definition at line 435 of file eht-capabilities.cc.

References m_macCapabilities, ns3::EhtMacCapabilities::maxMpduLength, and NS_ABORT_MSG.

Referenced by AmpduAggregationTest::DoSetup(), ns3::WifiMac::GetEhtCapabilities(), and WifiEhtCapabilitiesIeTest::GetEhtCapabilities().

+ Here is the caller graph for this function:

◆ SetPpeThresholds()

void ns3::EhtCapabilities::SetPpeThresholds ( uint8_t nssPe,
uint8_t ruIndexBitmask,
const std::vector< std::pair< uint8_t, uint8_t > > & ppeThresholds )

Set the EHT PPE threshold info subfield.

Parameters
nssPethe NSS_PE subfield
ruIndexBitmaskthe RU Index Bitmask subfield
ppeThresholdsthe PPE thresholds made of pairs (PPETmax, PPET8)

Definition at line 667 of file eht-capabilities.cc.

References m_phyCapabilities, m_ppeThresholds, NS_ASSERT, ns3::EhtPpeThresholds::nssPe, ns3::EhtPpeThresholds::ppeThresholdsInfo, ns3::EhtPhyCapabilities::ppeThresholdsPresent, and ns3::EhtPpeThresholds::ruIndexBitmask.

Referenced by WifiEhtCapabilitiesIeTest::DoRun().

+ Here is the caller graph for this function:

◆ SetSupportedRxEhtMcsAndNss()

void ns3::EhtCapabilities::SetSupportedRxEhtMcsAndNss ( EhtMcsAndNssSet::EhtMcsMapType mapType,
uint8_t upperMcs,
uint8_t maxNss )

Set a subfield of the Supported EHT-MCS And NSS Set.

Parameters
mapTypethe type of the subfield
upperMcsthe upper MCS of the range
maxNssthe maximum NSS supported for reception in the MCS range

Definition at line 492 of file eht-capabilities.cc.

References ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_160_MHZ, ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_20_MHZ_ONLY, ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_320_MHZ, ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_NOT_LARGER_THAN_80_MHZ, m_supportedEhtMcsAndNssSet, NS_ASSERT, NS_ASSERT_MSG, and ns3::EhtMcsAndNssSet::supportedEhtMcsAndNssSet.

Referenced by BasicMultiLinkElementTest::DoRun(), ns3::WifiMac::GetEhtCapabilities(), and WifiEhtCapabilitiesIeTest::GetEhtCapabilities().

+ Here is the caller graph for this function:

◆ SetSupportedTxEhtMcsAndNss()

void ns3::EhtCapabilities::SetSupportedTxEhtMcsAndNss ( EhtMcsAndNssSet::EhtMcsMapType mapType,
uint8_t upperMcs,
uint8_t maxNss )

Set a subfield of the Supported EHT-MCS And NSS Set.

Parameters
mapTypethe type of the subfield
upperMcsthe upper MCS of the range
maxNssthe maximum NSS supported for transmission in the MCS range

Definition at line 544 of file eht-capabilities.cc.

References ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_160_MHZ, ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_20_MHZ_ONLY, ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_320_MHZ, ns3::EhtMcsAndNssSet::EHT_MCS_MAP_TYPE_NOT_LARGER_THAN_80_MHZ, m_supportedEhtMcsAndNssSet, NS_ASSERT, NS_ASSERT_MSG, and ns3::EhtMcsAndNssSet::supportedEhtMcsAndNssSet.

Referenced by BasicMultiLinkElementTest::DoRun(), ns3::WifiMac::GetEhtCapabilities(), and WifiEhtCapabilitiesIeTest::GetEhtCapabilities().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_heCapabilities

std::optional<HeCapabilities> ns3::EhtCapabilities::m_heCapabilities
private

HE capabilities contained in the same management frame if present.

Definition at line 344 of file eht-capabilities.h.

Referenced by DeserializeInformationField().

◆ m_is2_4Ghz

bool ns3::EhtCapabilities::m_is2_4Ghz
private

flag indicating whether PHY is operating in 2.4 GHz based on other IEs contained in the same management frame

Definition at line 341 of file eht-capabilities.h.

Referenced by DeserializeInformationField().

◆ m_macCapabilities

EhtMacCapabilities ns3::EhtCapabilities::m_macCapabilities

◆ m_phyCapabilities

◆ m_ppeThresholds

EhtPpeThresholds ns3::EhtCapabilities::m_ppeThresholds

EHT PPE Threshold Info subfield.

Definition at line 334 of file eht-capabilities.h.

Referenced by DeserializeInformationField(), GetInformationFieldSize(), SerializeInformationField(), and SetPpeThresholds().

◆ m_supportedEhtMcsAndNssSet

EhtMcsAndNssSet ns3::EhtCapabilities::m_supportedEhtMcsAndNssSet

The documentation for this class was generated from the following files: