27 #include "ns3/callback.h"
28 #include "ns3/event-id.h"
29 #include "ns3/packet.h"
30 #include "ns3/object.h"
31 #include "ns3/nstime.h"
33 #include "ns3/mobility-model.h"
34 #include "ns3/random-variable-stream.h"
38 #include "ns3/traced-callback.h"
42 #include "ns3/net-device.h"
51 class WifiPhyStateHelper;
494 virtual double CalculateSnr (WifiTxVector txVector,
double ber)
const;
541 virtual uint8_t
GetNMcs (
void)
const;
1171 uint16_t channelNumber, uint32_t rate,
WifiPreamble preamble,
1198 uint16_t channelNumber, uint32_t rate,
WifiPreamble preamble,
1217 uint16_t channelNumber, uint32_t rate,
WifiPreamble preamble,
1218 WifiTxVector txVector,
struct mpduInfo aMpdu);
1237 uint16_t channelNumber, uint32_t rate,
WifiPreamble preamble,
1238 WifiTxVector txVector,
struct mpduInfo aMpdu);
1433 virtual void SetLdpc (
bool ldpc);
1439 virtual bool GetLdpc (
void)
const;
1445 virtual void SetStbc (
bool stbc);
1451 virtual bool GetStbc (
void)
const;
1521 double DbmToW (
double dbm)
const;
1537 double WToDbm (
double w)
const;
static WifiMode GetVhtMcs6()
Return MCS 6 from VHT MCS values.
static WifiMode GetOfdmRate9MbpsBW5MHz()
Return a WifiMode for OFDM at 9Mbps with 5MHz channel spacing.
TracedCallback< Ptr< const Packet > > m_phyRxBeginTrace
The trace source fired when a packet begins the reception process from the medium.
Ptr< NetDevice > m_device
Pointer to the device.
static WifiMode GetErpOfdmRate24Mbps()
Return a WifiMode for ERP-OFDM at 24Mbps.
uint32_t m_txMpduReferenceNumber
A-MPDU reference number to identify all transmitted subframes belonging to the same received A-MPDU...
static WifiMode GetDsssRate11Mbps()
Return a WifiMode for DSSS at 11Mbps.
virtual Ptr< WifiChannel > GetChannel(void) const =0
Return the WifiChannel this WifiPhy is connected to.
virtual uint32_t GetNBssMembershipSelectors(void) const
The WifiPhy::NBssMembershipSelectors() method is used (e.g., by a WifiRemoteStationManager) to determ...
Simulation virtual time values and global simulation resolution.
virtual bool DoFrequencySwitch(uint32_t frequency)
The default implementation does nothing and returns true.
void SetDevice(Ptr< NetDevice > device)
Sets the device this PHY is associated with.
void(* MonitorSnifferTxCallback)(const Ptr< const Packet > packet, uint16_t channelFreqMhz, uint16_t channelNumber, uint32_t rate, WifiPreamble preamble, WifiTxVector txVector, struct mpduInfo aMpdu)
TracedCallback signature for monitor mode transmit events.
std::vector< uint32_t > m_supportedChannelWidthSet
Supported channel width.
static WifiMode GetErpOfdmRate36Mbps()
Return a WifiMode for ERP-OFDM at 36Mbps.
virtual void SetNumberOfTransmitAntennas(uint32_t tx)
void NotifyMonitorSniffTx(Ptr< const Packet > packet, uint16_t channelFreqMhz, uint16_t channelNumber, uint32_t rate, WifiPreamble preamble, WifiTxVector txVector, struct mpduInfo aMpdu)
Public method used to fire a MonitorSniffer trace for a wifi packet being transmitted.
virtual bool IsStateBusy(void)
double RatioToDb(double ratio) const
Convert from ratio to dB.
double m_rxGainDb
Reception gain (dB)
static WifiMode GetVhtMcs8()
Return MCS 8 from VHT MCS values.
double GetTxGain(void) const
Return the transmission gain (dB).
double GetRxNoiseFigure(void) const
Return the RX noise figure (dBm).
virtual void SetShortPlcpPreambleSupported(bool preamble)
Enable or disable short PLCP preamble.
virtual bool IsMcsSupported(WifiMode mcs) const
Check if the given WifiMode is supported by the PHY.
uint16_t m_channelNumber
Operating channel number.
static WifiMode GetOfdmRate9Mbps()
Return a WifiMode for OFDM at 9Mbps.
virtual bool GetGuardInterval(void) const
Return whether guard interval is being used.
static WifiMode GetOfdmRate18MbpsBW10MHz()
Return a WifiMode for OFDM at 18Mbps with 10MHz channel spacing.
This class mimics the TXVECTOR which is to be passed to the PHY in order to define the parameters whi...
static WifiMode GetOfdmRate27MbpsBW10MHz()
Return a WifiMode for OFDM at 27Mbps with 10MHz channel spacing.
virtual void NotifyTxStart(Time duration, double txPowerDbm)=0
double m_txGainDb
Transmission gain (dB)
static WifiMode GetOfdmRate3MbpsBW5MHz()
Return a WifiMode for OFDM at 3Mbps with 5MHz channel spacing.
static WifiMode GetVhtMcs0()
Return MCS 0 from VHT MCS values.
virtual void NotifyWakeup(void)=0
Notify listeners that we woke up.
virtual void SetLdpc(bool ldpc)
Enable or disable LDPC.
static WifiMode GetDsssRate1Mbps()
Return a WifiMode for DSSS at 1Mbps.
bool m_ldpc
Flag if LDPC is used.
virtual bool GetGreenfield(void) const
Return whether Greenfield is supported.
static WifiMode GetErpOfdmRate18Mbps()
Return a WifiMode for ERP-OFDM at 18Mbps.
void SetTxGain(double gain)
Sets the transmission gain (dB).
The PHY layer has sense the medium busy through the CCA mechanism.
handles interference calculations
static WifiMode GetHtMcs7()
Return MCS 7 from HT MCS values.
virtual void DoDispose(void)
Destructor implementation.
static WifiMode GetHtPlcpHeaderMode(WifiMode payloadMode)
Forward calls to a chain of Callback.
virtual void SetStbc(bool stbc)
Enable or disable STBC.
static Time GetPlcpHtSigHeaderDuration(WifiPreamble preamble)
static WifiMode GetVhtMcs5()
Return MCS 5 from VHT MCS values.
static WifiMode GetHtMcs22()
Return MCS 22 from HT MCS values.
std::vector< uint32_t > m_bssMembershipSelectorSet
static WifiMode GetHtMcs14()
Return MCS 14 from HT MCS values.
static WifiMode GetOfdmRate12Mbps()
Return a WifiMode for OFDM at 12Mbps.
TracedCallback< Ptr< const Packet > > m_phyRxEndTrace
The trace source fired when a packet ends the reception process from the medium.
static WifiMode GetHtMcs31()
Return MCS 31 from HT MCS values.
static WifiMode GetHtMcs21()
Return MCS 21 from HT MCS values.
uint32_t m_numberOfReceivers
Number of receivers.
static WifiMode GetHtMcs30()
Return MCS 30 from HT MCS values.
static WifiMode GetHtMcs10()
Return MCS 10 from HT MCS values.
Ptr< ErrorRateModel > GetErrorRateModel(void) const
Return the error rate model this PHY is using.
static WifiMode GetHtMcs26()
Return MCS 26 from HT MCS values.
static WifiMode GetOfdmRate1_5MbpsBW5MHz()
Return a WifiMode for OFDM at 1.5Mbps with 5MHz channel spacing.
Callback< void, Ptr< Packet >, double, WifiTxVector, enum WifiPreamble > RxOkCallback
arg1: packet received successfully arg2: snr of packet arg3: TXVECTOR of packet arg4: type of preambl...
virtual void SetNumberOfReceiveAntennas(uint32_t rx)
The PHY layer is sleeping.
static WifiMode GetHtMcs17()
Return MCS 17 from HT MCS values.
static WifiMode GetHtMcs24()
Return MCS 24 from HT MCS values.
static WifiMode GetOfdmRate4_5MbpsBW10MHz()
Return a WifiMode for OFDM at 4.5Mbps with 10MHz channel spacing.
static WifiMode GetOfdmRate54Mbps()
Return a WifiMode for OFDM at 54Mbps.
void SetRxNoiseFigure(double noiseFigureDb)
Sets the RX loss (dB) in the Signal-to-Noise-Ratio due to non-idealities in the receiver.
void ConfigureHolland(void)
virtual uint8_t GetNMcs(void) const
The WifiPhy::GetNMcs() method is used (e.g., by a WifiRemoteStationManager) to determine the set of t...
void NotifyTxDrop(Ptr< const Packet > packet)
Public method used to fire a PhyTxDrop trace.
virtual void SetGreenfield(bool greenfield)
Enable or disable Greenfield support.
void Configure80211_10Mhz(void)
Configure WifiPhy with appropriate channel frequency and supported rates for 802.11a standard with 10...
static WifiMode GetHtMcs8()
Return MCS 8 from HT MCS values.
static WifiMode GetHtMcs18()
Return MCS 18 from HT MCS values.
virtual void SetGuardInterval(bool guardInterval)
Enable or disable short/long guard interval.
void NotifyTxBegin(Ptr< const Packet > packet)
Public method used to fire a PhyTxBegin trace.
static WifiMode GetVhtMcs4()
Return MCS 4 from VHT MCS values.
static WifiMode GetHtMcs27()
Return MCS 27 from HT MCS values.
represent a single transmission modeA WifiMode is implemented by a single integer which is used to lo...
virtual bool IsModeSupported(WifiMode mode) const
Check if the given WifiMode is supported by the PHY.
static WifiMode GetOfdmRate36Mbps()
Return a WifiMode for OFDM at 36Mbps.
Time GetPayloadDuration(uint32_t size, WifiTxVector txVector, WifiPreamble preamble, double frequency)
static WifiMode GetVhtMcs7()
Return MCS 7 from VHT MCS values.
static WifiMode GetOfdmRate6MbpsBW5MHz()
Return a WifiMode for OFDM at 6Mbps with 5MHz channel spacing.
virtual bool GetStbc(void) const
Return whether STBC is supported.
static WifiMode GetVhtMcs3()
Return MCS 3 from VHT MCS values.
virtual void RegisterListener(WifiPhyListener *listener)=0
void NotifyMonitorSniffRx(Ptr< const Packet > packet, uint16_t channelFreqMhz, uint16_t channelNumber, uint32_t rate, WifiPreamble preamble, WifiTxVector txVector, struct mpduInfo aMpdu, struct signalNoiseDbm signalNoise)
Public method used to fire a MonitorSniffer trace for a wifi packet being received.
virtual uint32_t GetBssMembershipSelector(uint32_t selector) const
The WifiPhy::BssMembershipSelector() method is used (e.g., by a WifiRemoteStationManager) to determin...
virtual void NotifySwitchingStart(Time duration)=0
WifiModeList m_deviceMcsSet
virtual void ResumeFromSleep(void)=0
Resume from sleep mode.
static WifiMode GetVhtPlcpHeaderMode(WifiMode payloadMode)
static WifiMode GetHtMcs16()
Return MCS 16 from HT MCS values.
virtual bool GetLdpc(void) const
Return if LDPC is supported.
static WifiMode GetErpOfdmRate54Mbps()
Return a WifiMode for ERP-OFDM at 54Mbps.
uint16_t m_mpdusNum
carries the number of expected mpdus that are part of an A-MPDU
static WifiMode GetHtMcs29()
Return MCS 29 from HT MCS values.
static WifiMode GetHtMcs11()
Return MCS 11 from HT MCS values.
void NotifyRxDrop(Ptr< const Packet > packet)
Public method used to fire a PhyRxDrop trace.
virtual uint32_t GetNumberOfReceiveAntennas(void) const
WifiPreamble
The type of preamble to be used by an IEEE 802.11 transmission.
void SetNTxPower(uint32_t n)
Sets the number of transmission power levels available between the minimum level and the maximum leve...
static ChannelToFrequencyWidthMap m_channelToFrequencyWidth
This table maintains the mapping of valid ChannelNumber to Frequency/ChannelWidth pairs...
double GetPowerDbm(uint8_t power) const
Get the power of the given power level in dBm.
double GetEdThreshold(void) const
Return the energy detection threshold (dBm).
WifiPhyStandard
Identifies the PHY specification that a Wifi device is configured to use.
TracedCallback< Ptr< const Packet >, uint16_t, uint16_t, uint32_t, WifiPreamble, WifiTxVector, struct mpduInfo, struct signalNoiseDbm > m_phyMonitorSniffRxTrace
A trace source that emulates a wifi device in monitor mode sniffing a packet being received...
virtual void NotifyRxEndOk(void)=0
We have received the last bit of a packet for which NotifyRxStart was invoked first and...
The MPDU is not part of an A-MPDU.
static WifiMode GetHtMcs2()
Return MCS 2 from HT MCS values.
virtual uint16_t GetChannelNumber(void) const
Return current channel number.
virtual void SetReceiveErrorCallback(RxErrorCallback callback)=0
Ptr< MobilityModel > m_mobility
Pointer to the mobility model.
Time CalculatePlcpPreambleAndHeaderDuration(WifiTxVector txVector, enum WifiPreamble preamble)
bool DefineChannelNumber(uint16_t channelNumber, enum WifiPhyStandard standard, uint32_t frequency, uint32_t channelWidth)
Add a channel definition to the WifiPhy.
receive notifications about phy events.
TracedCallback< Ptr< const Packet > > m_phyTxDropTrace
The trace source fired when the phy layer drops a packet as it tries to transmit it.
virtual void AddSupportedChannelWidth(uint32_t channelwidth)
bool m_shortPreamble
Flag if short PLCP preamble is supported.
virtual bool IsStateTx(void)
virtual void SetChannelWidth(uint32_t channelwidth)
static WifiMode GetPlcpHeaderMode(WifiMode payloadMode, WifiPreamble preamble, WifiTxVector txVector)
std::pair< uint32_t, uint32_t > FrequencyWidthPair
A pair of a center Frequency and a ChannelWidth.
static WifiMode GetHtMcs12()
Return MCS 12 from HT MCS values.
static WifiMode GetErpOfdmRate48Mbps()
Return a WifiMode for ERP-OFDM at 48Mbps.
void SetTxPowerEnd(double end)
Sets the maximum available transmission power level (dBm).
static WifiMode GetOfdmRate12MbpsBW10MHz()
Return a WifiMode for OFDM at 12Mbps with 10MHz channel spacing.
virtual Time GetDelayUntilIdle(void)
Time CalculateTxDuration(uint32_t size, WifiTxVector txVector, enum WifiPreamble preamble, double frequency)
uint32_t m_rxMpduReferenceNumber
A-MPDU reference number to identify all received subframes belonging to the same received A-MPDU...
The PHY layer is receiving a packet.
TracedCallback< Ptr< const Packet > > m_phyRxDropTrace
The trace source fired when the phy layer drops a packet it has received.
double m_edThresholdW
Energy detection threshold in watts.
void Configure80211_5Mhz()
Configure WifiPhy with appropriate channel frequency and supported rates for 802.11a standard with 5M...
virtual ~WifiPhyListener()
virtual uint32_t GetFrequency(void) const
uint16_t FindChannelNumberForFrequencyWidth(uint32_t frequency, uint32_t width) const
Look for channel number matching the frequency and width.
void NotifyRxBegin(Ptr< const Packet > packet)
Public method used to fire a PhyRxBegin trace.
The PHY layer is sending a packet.
static WifiMode GetOfdmRate18Mbps()
Return a WifiMode for OFDM at 18Mbps.
virtual uint32_t GetNModes(void) const
The WifiPhy::GetNModes() and WifiPhy::GetMode() methods are used (e.g., by a WifiRemoteStationManager...
static WifiMode GetOfdmRate9MbpsBW10MHz()
Return a WifiMode for OFDM at 9Mbps with 10MHz channel spacing.
static WifiMode GetOfdmRate12MbpsBW5MHz()
Return a WifiMode for OFDM at 12Mbps with 5MHz channel spacing.
virtual void SetChannelNumber(uint16_t id)
Set channel number.
virtual WifiModeList GetMembershipSelectorModes(uint32_t selector)
The WifiPhy::GetMembershipSelectorModes() method is used (e.g., by a WifiRemoteStationManager) to det...
std::pair< uint16_t, enum WifiPhyStandard > ChannelNumberStandardPair
A pair of a ChannelNumber and WifiPhyStandard.
The PHY layer is switching to other channel.
virtual bool DoChannelSwitch(uint16_t id)
The default implementation does nothing and returns true.
TracedCallback< Ptr< const Packet > > m_phyTxBeginTrace
The trace source fired when a packet begins the transmission process on the medium.
The MPDU is part of an A-MPDU, but is not the last aggregate.
virtual uint32_t GetNTxPower(void) const
Return the number of available transmission power levels.
static WifiMode GetVhtMcs1()
Return MCS 1 from VHT MCS values.
virtual void ConfigureDefaultsForStandard(enum WifiPhyStandard standard)
Configure the PHY-level parameters for different Wi-Fi standard.
static WifiMode GetOfdmRate48Mbps()
Return a WifiMode for OFDM at 48Mbps.
virtual void NotifySleep(void)=0
Notify listeners that we went to sleep.
std::ostream & operator<<(std::ostream &os, const Angles &a)
print a struct Angles to output
static WifiMode GetHtMcs0()
Return MCS 0 from HT MCS values.
virtual WifiMode GetMcs(uint8_t mcs) const
The WifiPhy::GetMcs() method is used (e.g., by a WifiRemoteStationManager) to determine the set of tr...
Callback< void, Ptr< Packet >, double > RxErrorCallback
arg1: packet received unsuccessfully arg2: snr of packet
virtual uint32_t GetChannelWidth(void) const
static TypeId GetTypeId(void)
Every class exported by the ns3 library is enclosed in the ns3 namespace.
virtual double GetTxPowerEnd(void) const
Return the maximum available transmission power level (dBm).
virtual bool IsStateIdle(void)
virtual void UnregisterListener(WifiPhyListener *listener)=0
static bool IsValidTxVector(WifiTxVector txVector)
The standard disallows certain combinations of WifiMode, number of spatial streams, and channel widths.
TracedCallback< Ptr< const Packet >, uint16_t, uint16_t, uint32_t, WifiPreamble, WifiTxVector, struct mpduInfo > m_phyMonitorSniffTxTrace
A trace source that emulates a wifi device in monitor mode sniffing a packet being transmitted...
static WifiMode GetOfdmRate24Mbps()
Return a WifiMode for OFDM at 24Mbps.
static WifiMode GetHtMcs13()
Return MCS 13 from HT MCS values.
virtual double CalculateSnr(WifiTxVector txVector, double ber) const
static WifiMode GetHtMcs20()
Return MCS 20 from HT MCS values.
static WifiMode GetHtMcs5()
Return MCS 5 from HT MCS values.
void SetCcaMode1Threshold(double threshold)
Sets the CCA threshold (dBm).
virtual Time GetLastRxStartTime(void) const
Return the start time of the last received packet.
void SetMobility(Ptr< MobilityModel > mobility)
assign a mobility model to this device
static WifiMode GetVhtMcs2()
Return MCS 2 from VHT MCS values.
virtual bool IsStateCcaBusy(void)
static WifiMode GetDsssRate5_5Mbps()
Return a WifiMode for DSSS at 5.5Mbps.
Ptr< MobilityModel > GetMobility(void)
Return the mobility model this PHY is associated with.
void Configure80211ac(void)
Configure WifiPhy with appropriate channel frequency and supported rates for 802.11ac standard...
virtual void DoInitialize(void)
Initialize() implementation.
static WifiMode GetOfdmRate2_25MbpsBW5MHz()
Return a WifiMode for OFDM at 2.25Mbps with 5MHz channel spacing.
std::vector< WifiMode > WifiModeList
In various parts of the code, folk are interested in maintaining a list of transmission modes...
static Time GetPlcpVhtSigA1Duration(WifiPreamble preamble)
static WifiMode GetErpOfdmRate9Mbps()
Return a WifiMode for ERP-OFDM at 9Mbps.
void NotifyTxEnd(Ptr< const Packet > packet)
Public method used to fire a PhyTxEnd trace.
Ptr< UniformRandomVariable > m_random
Provides uniform random variables.
virtual Time GetStateDuration(void)
virtual void NotifyRxStart(Time duration)=0
virtual void NotifyRxEndError(void)=0
We have received the last bit of a packet for which NotifyRxStart was invoked first and...
void InitializeFrequencyChannelNumber(void)
post-construction setting of frequency and/or channel number
virtual void ConfigureStandard(enum WifiPhyStandard standard)
Configure the PHY-level parameters for different Wi-Fi standard.
Ptr< NetDevice > GetDevice(void) const
Return the device this PHY is associated with.
void SetRxGain(double gain)
Sets the reception gain (dB).
void Configure80211b(void)
Configure WifiPhy with appropriate channel frequency and supported rates for 802.11b standard...
virtual std::vector< uint32_t > GetSupportedChannelWidthSet(void) const
static WifiMode GetErpOfdmRate6Mbps()
Return a WifiMode for ERP-OFDM at 6Mbps.
static WifiMode GetErpOfdmRate12Mbps()
Return a WifiMode for ERP-OFDM at 12Mbps.
bool m_plcpSuccess
Flag if the PLCP of the packet or the first MPDU in an A-MPDU has been received.
bool m_greenfield
Flag if GreenField format is supported.
virtual void ConfigureChannelForStandard(enum WifiPhyStandard standard)
Configure the PHY-level parameters for different Wi-Fi standard.
virtual bool IsStateSleep(void)
Ptr< WifiPhyStateHelper > m_state
Pointer to WifiPhyStateHelper.
void SetEdThreshold(double threshold)
Sets the energy detection threshold (dBm).
void NotifyRxEnd(Ptr< const Packet > packet)
Public method used to fire a PhyRxEnd trace.
void Configure80211n(void)
Configure WifiPhy with appropriate channel frequency and supported rates for 802.11n standard...
void SetTxPowerStart(double start)
Sets the minimum available transmission power level (dBm).
double m_txPowerBaseDbm
Minimum transmission power (dBm)
An identifier for simulation events.
virtual bool IsStateSwitching(void)
bool m_frequencyChannelNumberInitialized
Store initialization state.
static WifiMode GetHtMcs19()
Return MCS 19 from HT MCS values.
InterferenceHelper m_interference
Pointer to InterferenceHelper.
enum WifiPhyStandard m_standard
WifiPhyStandard.
virtual uint8_t GetSupportedTxSpatialStreams(void) const
bool m_isConstructed
true when ready to set frequency
static WifiMode GetHtMcs6()
Return MCS 6 from HT MCS values.
virtual uint32_t GetNumberOfTransmitAntennas(void) const
void ConfigureHtDeviceMcsSet(void)
Configure the device Mcs set with the appropriate HtMcs modes for the number of available transmit sp...
void(* MonitorSnifferRxCallback)(Ptr< const Packet > packet, uint16_t channelFreqMhz, uint16_t channelNumber, uint32_t rate, WifiPreamble preamble, WifiTxVector txVector, struct mpduInfo aMpdu, struct signalNoiseDbm signalNoise)
TracedCallback signature for monitor mode receive events.
double m_totalAmpduNumSymbols
Number of symbols previously transmitted for the MPDUs in an A-MPDU, used for the computation of the ...
static WifiMode GetHtMcs28()
Return MCS 28 from HT MCS values.
FrequencyWidthPair GetFrequencyWidthForChannelNumberStandard(uint16_t channelNumber, enum WifiPhyStandard standard) const
Lookup frequency/width pair for channelNumber/standard pair.
static WifiMode GetHtMcs9()
Return MCS 9 from HT MCS values.
virtual void SetSleepMode(void)=0
Put in sleep mode.
virtual void SetReceiveOkCallback(RxOkCallback callback)=0
virtual void SetFrequency(uint32_t freq)
static Time GetPlcpHeaderDuration(WifiTxVector txVector, WifiPreamble preamble)
uint32_t m_channelCenterFrequency
Center frequency in MHz.
virtual Time GetChannelSwitchDelay(void) const
static WifiMode GetHtMcs4()
Return MCS 4 from HT MCS values.
static WifiMode GetHtMcs25()
Return MCS 25 from HT MCS values.
uint32_t m_initialFrequency
Store frequency until initialization.
void Configure80211g(void)
Configure WifiPhy with appropriate channel frequency and supported rates for 802.11g standard...
double WToDbm(double w) const
Convert from Watts to dBm.
uint32_t m_channelWidth
Channel width.
uint32_t m_totalAmpduSize
Total size of the previously transmitted MPDUs in an A-MPDU, used for the computation of the number o...
virtual void SendPacket(Ptr< const Packet > packet, WifiTxVector txVector, enum WifiPreamble preamble)=0
virtual uint8_t GetSupportedRxSpatialStreams(void) const
WifiModeList m_deviceRateSet
This vector holds the set of transmission modes that this WifiPhy(-derived class) can support...
double DbmToW(double dbm) const
Convert from dBm to Watts.
static WifiMode GetHtMcs1()
Return MCS 1 from HT MCS values.
static WifiMode GetHtMcs23()
Return MCS 23 from HT MCS values.
A base class which provides memory management and object aggregation.
virtual enum WifiPhyStandard GetStandard(void) const
Get the configured Wi-Fi standard.
static WifiMode GetDsssRate2Mbps()
Return a WifiMode for DSSS at 2Mbps.
static WifiMode GetVhtMcs9()
Return MCS 9 from VHT MCS values.
static WifiMode GetOfdmRate6MbpsBW10MHz()
Return a WifiMode for OFDM at 6Mbps with 10MHz channel spacing.
double GetEdThresholdW(void) const
Return the energy detection threshold.
double m_txPowerEndDbm
Maximum transmission power (dBm)
virtual bool GetShortPlcpPreambleSupported(void) const
Return whether short PLCP preamble is supported.
State
The state of the PHY layer.
static Time GetPlcpHtTrainingSymbolDuration(WifiPreamble preamble, WifiTxVector txVector)
static WifiMode GetOfdmRate24MbpsBW10MHz()
Return a WifiMode for OFDM at 24Mbps with 10MHz channel spacing.
Time m_channelSwitchDelay
Time required to switch between channel.
static Time GetPlcpVhtSigBDuration(WifiPreamble preamble)
virtual bool IsStateRx(void)
uint32_t m_numberOfTransmitters
Number of transmitters.
static WifiMode GetOfdmRate13_5MbpsBW5MHz()
Return a WifiMode for OFDM at 13.5Mbps with 5MHz channel spacing.
double m_ccaMode1ThresholdW
Clear channel assessment (CCA) threshold in watts.
double GetCcaMode1Threshold(void) const
Return the CCA threshold (dBm).
a unique identifier for an interface.
static WifiMode GetHtMcs15()
Return MCS 15 from HT MCS values.
static Time GetPlcpPreambleDuration(WifiTxVector txVector, WifiPreamble preamble)
static WifiMode GetHtMcs3()
Return MCS 3 from HT MCS values.
uint16_t m_initialChannelNumber
Initial channel number.
double DbToRatio(double db) const
Convert from dB to ratio.
static WifiMode GetOfdmRate6Mbps()
Return a WifiMode for OFDM at 6Mbps.
double GetRxGain(void) const
Return the reception gain (dB).
virtual int64_t AssignStreams(int64_t stream)
Assign a fixed random variable stream number to the random variables used by this model...
virtual double GetTxPowerStart(void) const
Return the minimum available transmission power level (dBm).
static Time GetPlcpVhtSigA2Duration(WifiPreamble preamble)
static WifiMode GetOfdmRate4_5MbpsBW5MHz()
Return a WifiMode for OFDM at 4.5Mbps with 5MHz channel spacing.
uint32_t m_nTxPower
Number of available transmission power levels.
bool m_stbc
Flag if STBC is used.
void Configure80211a(void)
Configure WifiPhy with appropriate channel frequency and supported rates for 802.11a standard...
mpduType
This enumeration defines the type of an MPDU.
void SetErrorRateModel(Ptr< ErrorRateModel > rate)
Sets the error rate model.
std::map< ChannelNumberStandardPair, FrequencyWidthPair > ChannelToFrequencyWidthMap
static WifiMode GetOfdmRate3MbpsBW10MHz()
Return a WifiMode for OFDM at 3Mbps with 10MHz channel spacing.
TracedCallback< Ptr< const Packet > > m_phyTxEndTrace
The trace source fired when a packet ends the transmission process on the medium. ...
bool m_guardInterval
Flag if short guard interval is used.
virtual WifiMode GetMode(uint32_t mode) const
The WifiPhy::GetNModes() and WifiPhy::GetMode() methods are used (e.g., by a WifiRemoteStationManager...
virtual void NotifyMaybeCcaBusyStart(Time duration)=0
The MPDU is the last aggregate in an A-MPDU.