OFDM PPDU (11a) More...
#include "ofdm-ppdu.h"
Classes | |
class | LSigHeader |
OFDM and ERP OFDM L-SIG PHY header. More... | |
Public Member Functions | |
OfdmPpdu (Ptr< const WifiPsdu > psdu, const WifiTxVector &txVector, const WifiPhyOperatingChannel &channel, uint64_t uid, bool instantiateLSig=true) | |
Create an OFDM PPDU. More... | |
Ptr< WifiPpdu > | Copy () const override |
Copy this instance. More... | |
Time | GetTxDuration () const override |
Get the total transmission duration of the PPDU. More... | |
Public Member Functions inherited from ns3::WifiPpdu | |
WifiPpdu (const WifiConstPsduMap &psdus, const WifiTxVector &txVector, const WifiPhyOperatingChannel &channel, uint64_t uid) | |
Create a PPDU storing a map of PSDUs. More... | |
WifiPpdu (Ptr< const WifiPsdu > psdu, const WifiTxVector &txVector, const WifiPhyOperatingChannel &channel, uint64_t uid=UINT64_MAX) | |
Create a PPDU storing a PSDU. More... | |
virtual | ~WifiPpdu () |
Destructor for WifiPpdu. More... | |
bool | DoesOverlapChannel (uint16_t minFreq, uint16_t maxFreq) const |
Check whether the given PPDU overlaps a given channel. More... | |
WifiModulationClass | GetModulation () const |
Get the modulation used for the PPDU. More... | |
WifiPreamble | GetPreamble () const |
Get the preamble of the PPDU. More... | |
Ptr< const WifiPsdu > | GetPsdu () const |
Get the payload of the PPDU. More... | |
virtual uint16_t | GetStaId () const |
Get the ID of the STA that transmitted the PPDU for UL MU, SU_STA_ID otherwise. More... | |
uint16_t | GetTxCenterFreq () const |
virtual uint16_t | GetTxChannelWidth () const |
Get the channel width over which the PPDU will effectively be transmitted. More... | |
const WifiTxVector & | GetTxVector () const |
Get the TXVECTOR used to send the PPDU. More... | |
virtual WifiPpduType | GetType () const |
Return the PPDU type (. More... | |
uint64_t | GetUid () const |
Get the UID of the PPDU. More... | |
bool | IsTruncatedTx () const |
void | Print (std::ostream &os) const |
Print the PPDU contents. More... | |
void | ResetTxVector () const |
Reset the TXVECTOR. More... | |
void | SetTruncatedTx () |
Indicate that the PPDU's transmission was aborted due to transmitter switch off. More... | |
void | UpdateTxVector (const WifiTxVector &updatedTxVector) const |
Update the TXVECTOR based on some information known at the receiver. More... | |
Public Member Functions inherited from ns3::SimpleRefCount< WifiPpdu > | |
SimpleRefCount () | |
Default constructor. More... | |
SimpleRefCount (const SimpleRefCount &o[[maybe_unused]]) | |
Copy constructor. More... | |
uint32_t | GetReferenceCount () const |
Get the reference count of the object. More... | |
SimpleRefCount & | operator= (const SimpleRefCount &o[[maybe_unused]]) |
Assignment operator. More... | |
void | Ref () const |
Increment the reference count. More... | |
void | Unref () const |
Decrement the reference count. More... | |
Protected Attributes | |
LSigHeader | m_lSig |
the L-SIG PHY header More... | |
Protected Attributes inherited from ns3::WifiPpdu | |
WifiModulationClass | m_modulation |
the modulation used for the transmission of this PPDU More... | |
const WifiPhyOperatingChannel & | m_operatingChannel |
the operating channel of the PHY More... | |
WifiPreamble | m_preamble |
the PHY preamble More... | |
WifiConstPsduMap | m_psdus |
the PSDUs contained in this PPDU More... | |
uint16_t | m_txCenterFreq |
the center frequency (MHz) used for the transmission of this PPDU More... | |
std::optional< WifiTxVector > | m_txVector |
the TXVECTOR at TX PHY or the reconstructed TXVECTOR at RX PHY (or std::nullopt if TXVECTOR has not been reconstructed yet) More... | |
uint64_t | m_uid |
the unique ID of this PPDU More... | |
Private Member Functions | |
WifiTxVector | DoGetTxVector () const override |
Get the TXVECTOR used to send the PPDU. More... | |
void | SetLSigHeader (LSigHeader &lSig, const WifiTxVector &txVector, std::size_t psduSize) const |
Fill in the L-SIG header. More... | |
void | SetPhyHeaders (const WifiTxVector &txVector, std::size_t psduSize) |
Fill in the PHY headers. More... | |
virtual void | SetTxVectorFromLSigHeader (WifiTxVector &txVector, const LSigHeader &lSig) const |
Fill in the TXVECTOR from L-SIG header. More... | |
Private Attributes | |
uint16_t | m_channelWidth |
the channel width used to transmit that PPDU in MHz (needed to distinguish 5 MHz, 10 MHz or 20 MHz PPDUs) More... | |
Additional Inherited Members | |
Protected Member Functions inherited from ns3::WifiPpdu | |
virtual std::string | PrintPayload () const |
Print the payload of the PPDU. More... | |
OFDM PPDU (11a)
OfdmPpdu stores a preamble, PHY headers and a PSDU of a PPDU with non-HT header, i.e., PPDU that uses OFDM modulation.
Definition at line 46 of file ofdm-ppdu.h.
ns3::OfdmPpdu::OfdmPpdu | ( | Ptr< const WifiPsdu > | psdu, |
const WifiTxVector & | txVector, | ||
const WifiPhyOperatingChannel & | channel, | ||
uint64_t | uid, | ||
bool | instantiateLSig = true |
||
) |
Create an OFDM PPDU.
psdu | the PHY payload (PSDU) |
txVector | the TXVECTOR that was used for this PPDU |
channel | the operating channel of the PHY used to transmit this PPDU |
uid | the unique ID of this PPDU |
instantiateLSig | flag used to instantiate LSigHeader (set LSigHeader's rate and length), should be disabled by child classes |
Definition at line 36 of file ofdm-ppdu.cc.
References third::channel, ns3::WifiPsdu::GetSize(), NS_LOG_FUNCTION, and SetPhyHeaders().
Referenced by Copy().
Copy this instance.
Reimplemented from ns3::WifiPpdu.
Reimplemented in ns3::VhtPpdu.
Definition at line 93 of file ofdm-ppdu.cc.
References OfdmPpdu().
|
overrideprivatevirtual |
Get the TXVECTOR used to send the PPDU.
Reimplemented from ns3::WifiPpdu.
Reimplemented in ns3::VhtPpdu.
Definition at line 66 of file ofdm-ppdu.cc.
References m_lSig, ns3::WifiPpdu::m_preamble, ns3::WifiTxVector::SetPreambleType(), and SetTxVectorFromLSigHeader().
|
overridevirtual |
Get the total transmission duration of the PPDU.
Reimplemented from ns3::WifiPpdu.
Reimplemented in ns3::VhtPpdu.
Definition at line 84 of file ofdm-ppdu.cc.
References ns3::WifiPhy::CalculateTxDuration(), ns3::OfdmPpdu::LSigHeader::GetLength(), ns3::WifiPhyOperatingChannel::GetPhyBand(), ns3::WifiPpdu::GetTxVector(), ns3::WifiPhyOperatingChannel::IsSet(), m_lSig, ns3::WifiPpdu::m_operatingChannel, and NS_ASSERT.
|
private |
Fill in the L-SIG header.
lSig | the L-SIG header to fill in |
txVector | the TXVECTOR that was used for this PPDU |
psduSize | the size duration of the PHY payload (PSDU) |
Definition at line 59 of file ofdm-ppdu.cc.
References ns3::WifiMode::GetDataRate(), ns3::WifiTxVector::GetMode(), m_channelWidth, ns3::OfdmPpdu::LSigHeader::SetLength(), and ns3::OfdmPpdu::LSigHeader::SetRate().
Referenced by SetPhyHeaders().
|
private |
Fill in the PHY headers.
txVector | the TXVECTOR that was used for this PPDU |
psduSize | the size duration of the PHY payload (PSDU) |
Definition at line 52 of file ofdm-ppdu.cc.
References m_lSig, NS_LOG_FUNCTION, and SetLSigHeader().
Referenced by OfdmPpdu().
|
privatevirtual |
Fill in the TXVECTOR from L-SIG header.
txVector | the TXVECTOR to fill in |
lSig | the L-SIG header |
Reimplemented in ns3::ErpOfdmPpdu.
Definition at line 75 of file ofdm-ppdu.cc.
References ns3::OfdmPhy::GetOfdmRate(), ns3::OfdmPpdu::LSigHeader::GetRate(), m_channelWidth, NS_ASSERT, ns3::WifiTxVector::SetChannelWidth(), and ns3::WifiTxVector::SetMode().
Referenced by DoGetTxVector().
|
private |
the channel width used to transmit that PPDU in MHz (needed to distinguish 5 MHz, 10 MHz or 20 MHz PPDUs)
Definition at line 140 of file ofdm-ppdu.h.
Referenced by SetLSigHeader(), and SetTxVectorFromLSigHeader().
|
protected |
the L-SIG PHY header
Definition at line 110 of file ofdm-ppdu.h.
Referenced by ns3::HtPpdu::DoGetTxVector(), DoGetTxVector(), ns3::VhtPpdu::DoGetTxVector(), GetTxDuration(), ns3::VhtPpdu::GetTxDuration(), ns3::HePpdu::SetLSigHeader(), SetPhyHeaders(), ns3::VhtPpdu::SetPhyHeaders(), ns3::HtPpdu::SetPhyHeaders(), ns3::HePpdu::SetTxVectorFromPhyHeaders(), and ns3::EhtPpdu::SetTxVectorFromPhyHeaders().