INET Framework for OMNeT++/OMNEST
inet::physicallayer::Ieee80211VhtModeBase Class Referenceabstract

#include <Ieee80211VhtMode.h>

Inheritance diagram for inet::physicallayer::Ieee80211VhtModeBase:
inet::physicallayer::Ieee80211VhtDataMode inet::physicallayer::Ieee80211VhtSignalMode

Public Types

enum  GuardIntervalType { HT_GUARD_INTERVAL_SHORT, HT_GUARD_INTERVAL_LONG }
 

Public Member Functions

 Ieee80211VhtModeBase (unsigned int modulationAndCodingScheme, unsigned int numberOfSpatialStreams, const Hz bandwidth, GuardIntervalType guardIntervalType)
 
virtual int getNumberOfDataSubcarriers () const
 
virtual int getNumberOfPilotSubcarriers () const
 
virtual int getNumberOfTotalSubcarriers () const
 
virtual GuardIntervalType getGuardIntervalType () const
 
virtual int getNumberOfSpatialStreams () const
 
virtual unsigned int getMcsIndex () const
 
virtual Hz getBandwidth () const
 
virtual bps getNetBitrate () const
 
virtual bps getGrossBitrate () const
 

Protected Member Functions

virtual bps computeGrossBitrate () const =0
 
virtual bps computeNetBitrate () const =0
 

Protected Attributes

const Hz bandwidth
 
const GuardIntervalType guardIntervalType
 
const unsigned int mcsIndex
 
const unsigned int numberOfSpatialStreams
 
bps netBitrate
 
bps grossBitrate
 

Member Enumeration Documentation

◆ GuardIntervalType

Enumerator
HT_GUARD_INTERVAL_SHORT 
HT_GUARD_INTERVAL_LONG 
25  {
26  HT_GUARD_INTERVAL_SHORT, // 400 ns
27  HT_GUARD_INTERVAL_LONG // 800 ns
28  };

Constructor & Destructor Documentation

◆ Ieee80211VhtModeBase()

inet::physicallayer::Ieee80211VhtModeBase::Ieee80211VhtModeBase ( unsigned int  modulationAndCodingScheme,
unsigned int  numberOfSpatialStreams,
const Hz  bandwidth,
GuardIntervalType  guardIntervalType 
)
28  :
31  mcsIndex(modulationAndCodingScheme),
33  netBitrate(bps(NaN)),
35 {
36 }

Member Function Documentation

◆ computeGrossBitrate()

virtual bps inet::physicallayer::Ieee80211VhtModeBase::computeGrossBitrate ( ) const
protectedpure virtual

◆ computeNetBitrate()

virtual bps inet::physicallayer::Ieee80211VhtModeBase::computeNetBitrate ( ) const
protectedpure virtual

◆ getBandwidth()

virtual Hz inet::physicallayer::Ieee80211VhtModeBase::getBandwidth ( ) const
inlinevirtual

Reimplemented in inet::physicallayer::Ieee80211VhtDataMode.

52 { return bandwidth; }

◆ getGrossBitrate()

bps inet::physicallayer::Ieee80211VhtModeBase::getGrossBitrate ( ) const
virtual

◆ getGuardIntervalType()

virtual GuardIntervalType inet::physicallayer::Ieee80211VhtModeBase::getGuardIntervalType ( ) const
inlinevirtual
49 { return guardIntervalType; }

◆ getMcsIndex()

◆ getNetBitrate()

bps inet::physicallayer::Ieee80211VhtModeBase::getNetBitrate ( ) const
virtual

◆ getNumberOfDataSubcarriers()

int inet::physicallayer::Ieee80211VhtModeBase::getNumberOfDataSubcarriers ( ) const
virtual
323 {
324  if (bandwidth == MHz(20))
325  return 52;
326  else if (bandwidth == MHz(40))
327  return 108;
328  else if (bandwidth == MHz(80))
329  return 234;
330  else if (bandwidth == MHz(160))
331  return 468;
332  else
333  throw cRuntimeError("Unsupported bandwidth");
334 }

Referenced by inet::physicallayer::Ieee80211VhtSignalMode::computeGrossBitrate(), inet::physicallayer::Ieee80211VhtDataMode::computeGrossBitrate(), and inet::physicallayer::Ieee80211VhtDataMode::getDuration().

◆ getNumberOfPilotSubcarriers()

int inet::physicallayer::Ieee80211VhtModeBase::getNumberOfPilotSubcarriers ( ) const
virtual
337 {
338  if (bandwidth == MHz(20))
339  return 4;
340  else if (bandwidth == MHz(40))
341  // It is a spacial case, see the comment above.
342  return 6;
343  else if (bandwidth == MHz(80))
344  // It is a spacial case, see the comment above.
345  return 8;
346  else if (bandwidth == MHz(160))
347  // It is a spacial case, see the comment above.
348  return 16;
349  else
350  throw cRuntimeError("Unsupported bandwidth");
351 }

◆ getNumberOfSpatialStreams()

virtual int inet::physicallayer::Ieee80211VhtModeBase::getNumberOfSpatialStreams ( ) const
inlinevirtual

◆ getNumberOfTotalSubcarriers()

virtual int inet::physicallayer::Ieee80211VhtModeBase::getNumberOfTotalSubcarriers ( ) const
inlinevirtual

Member Data Documentation

◆ bandwidth

const Hz inet::physicallayer::Ieee80211VhtModeBase::bandwidth
protected

◆ grossBitrate

bps inet::physicallayer::Ieee80211VhtModeBase::grossBitrate
mutableprotected

Referenced by getGrossBitrate().

◆ guardIntervalType

const GuardIntervalType inet::physicallayer::Ieee80211VhtModeBase::guardIntervalType
protected

◆ mcsIndex

const unsigned int inet::physicallayer::Ieee80211VhtModeBase::mcsIndex
protected

◆ netBitrate

bps inet::physicallayer::Ieee80211VhtModeBase::netBitrate
mutableprotected

Referenced by getNetBitrate().

◆ numberOfSpatialStreams

const unsigned int inet::physicallayer::Ieee80211VhtModeBase::numberOfSpatialStreams
protected

The documentation for this class was generated from the following files:
inet::physicallayer::Ieee80211VhtModeBase::HT_GUARD_INTERVAL_LONG
@ HT_GUARD_INTERVAL_LONG
Definition: Ieee80211VhtMode.h:27
inet::physicallayer::Ieee80211VhtModeBase::grossBitrate
bps grossBitrate
Definition: Ieee80211VhtMode.h:37
inet::physicallayer::Ieee80211VhtModeBase::bandwidth
const Hz bandwidth
Definition: Ieee80211VhtMode.h:31
inet::units::units::bps
compose< b, pow< s, -1 > > bps
Definition: Units.h:1169
inet::physicallayer::Ieee80211VhtModeBase::mcsIndex
const unsigned int mcsIndex
Definition: Ieee80211VhtMode.h:33
inet::physicallayer::Ieee80211VhtModeBase::getNumberOfPilotSubcarriers
virtual int getNumberOfPilotSubcarriers() const
Definition: Ieee80211VhtMode.cc:336
inet::physicallayer::Ieee80211VhtModeBase::guardIntervalType
const GuardIntervalType guardIntervalType
Definition: Ieee80211VhtMode.h:32
inet::physicallayer::Ieee80211VhtModeBase::HT_GUARD_INTERVAL_SHORT
@ HT_GUARD_INTERVAL_SHORT
Definition: Ieee80211VhtMode.h:26
NaN
#define NaN
Definition: INETMath.h:91
inet::physicallayer::Ieee80211VhtModeBase::netBitrate
bps netBitrate
Definition: Ieee80211VhtMode.h:36
inet::physicallayer::Ieee80211VhtModeBase::computeNetBitrate
virtual bps computeNetBitrate() const =0
inet::physicallayer::Ieee80211VhtModeBase::computeGrossBitrate
virtual bps computeGrossBitrate() const =0
inet::physicallayer::Ieee80211VhtModeBase::numberOfSpatialStreams
const unsigned int numberOfSpatialStreams
Definition: Ieee80211VhtMode.h:34
inet::physicallayer::Ieee80211VhtModeBase::getNumberOfDataSubcarriers
virtual int getNumberOfDataSubcarriers() const
Definition: Ieee80211VhtMode.cc:322
inet::units::value::get
const value_type & get() const
Definition: Units.h:108
inet::units::units::MHz
mega< Hz >::type MHz
Definition: Units.h:1083