A Discrete-Event Network Simulator
API
ns3::UanTxMode Class Reference

Abstraction of packet modulation information. More...

#include "uan-tx-mode.h"

+ Collaboration diagram for ns3::UanTxMode:

Public Types

enum  ModulationType { PSK , QAM , FSK , OTHER }
 Modulation type. More...
 

Public Member Functions

 UanTxMode ()
 Constructor. More...
 
 ~UanTxMode ()
 Destructor. More...
 
uint32_t GetBandwidthHz (void) const
 Get the transmission signal bandwidth. More...
 
uint32_t GetCenterFreqHz (void) const
 Get the transmission center frequency. More...
 
uint32_t GetConstellationSize (void) const
 Get the number of constellation points in the modulation scheme. More...
 
uint32_t GetDataRateBps (void) const
 Get the data rate of the transmit mode. More...
 
ModulationType GetModType (void) const
 Get the modulation type of the mode. More...
 
std::string GetName (void) const
 Get the mode name. More...
 
uint32_t GetPhyRateSps (void) const
 Get the physical signaling rate. More...
 
uint32_t GetUid (void) const
 Get a unique id for the mode. More...
 

Private Attributes

uint32_t m_uid
 Mode id. More...
 

Friends

std::ostream & operator<< (std::ostream &os, const UanTxMode &mode)
 Writes tx mode entry to stream os. More...
 
std::istream & operator>> (std::istream &is, UanTxMode &mode)
 Reads tx mode entry from stream is. More...
 
class UanTxModeFactory
 

Detailed Description

Abstraction of packet modulation information.

This contains a lightweight globally unique id for the mode. Mode details are held in the UanTxModeFactory. Attributes are set in by the UanTxModeFactory constructor.

Definition at line 41 of file uan-tx-mode.h.

Member Enumeration Documentation

◆ ModulationType

Modulation type.

Enumerator
PSK 

Phase shift keying.

QAM 

Quadrature amplitude modulation.

FSK 

Frequency shift keying.

OTHER 

Unspecified/undefined.

Definition at line 50 of file uan-tx-mode.h.

Constructor & Destructor Documentation

◆ UanTxMode()

ns3::UanTxMode::UanTxMode ( )

Constructor.

Definition at line 29 of file uan-tx-mode.cc.

◆ ~UanTxMode()

ns3::UanTxMode::~UanTxMode ( )

Destructor.

Definition at line 33 of file uan-tx-mode.cc.

Member Function Documentation

◆ GetBandwidthHz()

uint32_t ns3::UanTxMode::GetBandwidthHz ( void  ) const

Get the transmission signal bandwidth.

Returns
Bandwidth in Hz.

Definition at line 63 of file uan-tx-mode.cc.

References ns3::UanTxModeFactory::GetFactory(), ns3::UanTxModeFactory::GetModeItem(), ns3::UanTxModeFactory::UanTxModeItem::m_bwHz, and m_uid.

Referenced by ns3::UanPhyPerCommonModes::CalcPer(), ns3::UanPhyCalcSinrDual::CalcSinrDb(), and ns3::UanPhyGen::CalculateSinrDb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetCenterFreqHz()

uint32_t ns3::UanTxMode::GetCenterFreqHz ( void  ) const

Get the transmission center frequency.

Returns
Center frequency, in Hz.

Definition at line 57 of file uan-tx-mode.cc.

References ns3::UanTxModeFactory::GetFactory(), ns3::UanTxModeFactory::GetModeItem(), ns3::UanTxModeFactory::UanTxModeItem::m_cfHz, and m_uid.

Referenced by ns3::UanPhyCalcSinrDual::CalcSinrDb(), ns3::UanPhyGen::CalculateSinrDb(), and ns3::UanPropModelThorp::GetPathLossDb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetConstellationSize()

uint32_t ns3::UanTxMode::GetConstellationSize ( void  ) const

Get the number of constellation points in the modulation scheme.

Returns
Number of constellation points.

Definition at line 69 of file uan-tx-mode.cc.

References ns3::UanTxModeFactory::GetFactory(), ns3::UanTxModeFactory::GetModeItem(), ns3::UanTxModeFactory::UanTxModeItem::m_constSize, and m_uid.

Referenced by ns3::UanPhyPerUmodem::CalcPer(), ns3::UanPhyPerCommonModes::CalcPer(), and ns3::UanPhyCalcSinrFhFsk::CalcSinrDb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetDataRateBps()

uint32_t ns3::UanTxMode::GetDataRateBps ( void  ) const

Get the data rate of the transmit mode.

Returns
Data rate of the TX mode, in bits per second.

Definition at line 45 of file uan-tx-mode.cc.

References ns3::UanTxModeFactory::GetFactory(), ns3::UanTxModeFactory::GetModeItem(), ns3::UanTxModeFactory::UanTxModeItem::m_dataRateBps, and m_uid.

Referenced by ns3::UanPhyPerCommonModes::CalcPer(), ns3::UanTransducerHd::Receive(), ns3::UanPhyGen::SendPacket(), ns3::UanPhyGen::StartRxPacket(), and ns3::UanTransducerHd::Transmit().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetModType()

UanTxMode::ModulationType ns3::UanTxMode::GetModType ( void  ) const

Get the modulation type of the mode.

Returns
The modulation type.

Definition at line 39 of file uan-tx-mode.cc.

References ns3::UanTxModeFactory::GetFactory(), ns3::UanTxModeFactory::GetModeItem(), ns3::UanTxModeFactory::UanTxModeItem::m_type, and m_uid.

Referenced by ns3::UanPhyPerUmodem::CalcPer(), ns3::UanPhyPerCommonModes::CalcPer(), ns3::UanPhyCalcSinrDual::CalcSinrDb(), ns3::UanPhyCalcSinrDefault::CalcSinrDb(), and ns3::UanPhyCalcSinrFhFsk::CalcSinrDb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetName()

std::string ns3::UanTxMode::GetName ( void  ) const

Get the mode name.

Returns
Name

Definition at line 75 of file uan-tx-mode.cc.

References ns3::UanTxModeFactory::GetFactory(), ns3::UanTxModeFactory::GetModeItem(), ns3::UanTxModeFactory::UanTxModeItem::m_name, and m_uid.

Referenced by ns3::UanPhyCalcSinrDual::CalcSinrDb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetPhyRateSps()

uint32_t ns3::UanTxMode::GetPhyRateSps ( void  ) const

Get the physical signaling rate.

Returns
PHY rate in symbols per second.

Definition at line 51 of file uan-tx-mode.cc.

References ns3::UanTxModeFactory::GetFactory(), ns3::UanTxModeFactory::GetModeItem(), ns3::UanTxModeFactory::UanTxModeItem::m_phyRateSps, and m_uid.

Referenced by ns3::UanPhyCalcSinrFhFsk::CalcSinrDb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetUid()

uint32_t ns3::UanTxMode::GetUid ( void  ) const

Get a unique id for the mode.

Returns
Unique ID.

Definition at line 81 of file uan-tx-mode.cc.

References m_uid.

Referenced by ns3::UanPhyGen::StartRxPacket().

+ Here is the caller graph for this function:

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
const UanTxMode mode 
)
friend

Writes tx mode entry to stream os.

Parameters
osThe output stream.
modeThe mode.
Returns
The stream.

Definition at line 86 of file uan-tx-mode.cc.

◆ operator>>

std::istream& operator>> ( std::istream &  is,
UanTxMode mode 
)
friend

Reads tx mode entry from stream is.

Parameters
isThe input stream.
modeThe mode.
Returns
The stream.

Definition at line 94 of file uan-tx-mode.cc.

◆ UanTxModeFactory

friend class UanTxModeFactory
friend

Definition at line 106 of file uan-tx-mode.h.

Member Data Documentation

◆ m_uid

uint32_t ns3::UanTxMode::m_uid
private

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