ns3::SatCnoHelper Class Reference

This helper allows to set customs C/N0 values for some GW or UT nodes. More...

#include "satellite-cno-helper.h"

+ Inheritance diagram for ns3::SatCnoHelper:
+ Collaboration diagram for ns3::SatCnoHelper:

Classes

struct  cnoCustomParams_s
 Struct for storing the custom C/N0 for some nodes. More...
 

Public Member Functions

 SatCnoHelper ()
 Default constructor. More...
 
 SatCnoHelper (Ptr< SatHelper > satHelper)
 Create a base SatCnoHelper. More...
 
virtual ~SatCnoHelper ()
 Destructor for SatCnoHelper. More...
 
TypeId GetInstanceTypeId (void) const
 Get the type ID of object instance. More...
 
void SetGwNodeCno (NodeContainer nodes, SatEnums::ChannelType_t channel, double cno)
 Set a constant C/N0 for one GW node and one channel direction. More...
 
void SetGwNodeCno (Ptr< Node > node, SatEnums::ChannelType_t channel, double cno)
 Set a constant C/N0 for one GW node and one channel direction. More...
 
void SetGwNodeCno (uint32_t nodeId, SatEnums::ChannelType_t channel, double cno)
 Set a constant C/N0 for one GW node and one channel direction. More...
 
void SetGwNodeCnoFile (Ptr< Node > node, SatEnums::ChannelType_t channel, std::string path)
 Set a constant C/N0 for one GW node and one channel direction. More...
 
void SetGwNodeCnoFile (uint32_t nodeId, SatEnums::ChannelType_t channel, std::string path)
 Set a constant C/N0 for one GW node and one channel direction. More...
 
void SetUtNodeCno (NodeContainer nodes, SatEnums::ChannelType_t channel, double cno)
 Set a constant C/N0 for one UT node and one channel direction. More...
 
void SetUtNodeCno (Ptr< Node > node, SatEnums::ChannelType_t channel, double cno)
 Set a constant C/N0 for one UT node and one channel direction. More...
 
void SetUtNodeCno (uint32_t nodeId, SatEnums::ChannelType_t channel, double cno)
 Set a constant C/N0 for one UT node and one channel direction. More...
 
void SetUtNodeCnoFile (Ptr< Node > node, SatEnums::ChannelType_t channel, std::string path)
 Set a constant C/N0 for one UT node and one channel direction. More...
 
void SetUtNodeCnoFile (uint32_t nodeId, SatEnums::ChannelType_t channel, std::string path)
 Set a constant C/N0 for one UT node and one channel direction. More...
 
void UseTracesForDefault (bool useTraces)
 Set m_useTraces attribute. More...
 

Static Public Member Functions

static TypeId GetTypeId (void)
 Get the type ID. More...
 

Private Member Functions

void ApplyConfiguration ()
 Apply configuration to all the satellite channels Needs to be done after node creation. More...
 
bool CheckDuplicate (Ptr< Node > node, SatEnums::ChannelType_t channel)
 Verify if a node has already been set. More...
 

Private Attributes

std::vector< cnoCustomParams_sm_customCno
 Array storing manual C/N0 updates (constant or custom file) More...
 
Ptr< SatHelperm_satHelper
 Pointer to the SatHelper objet. More...
 
bool m_useTraces
 Use C/N0 input traces instead of power calculation from antenna gain. More...
 

Detailed Description

This helper allows to set customs C/N0 values for some GW or UT nodes.

For each node, the C/N0 value can be constant over time, or follow a trace file giving the temporal evolution of this parameter.

Definition at line 38 of file satellite-cno-helper.h.

Constructor & Destructor Documentation

◆ SatCnoHelper() [1/2]

ns3::SatCnoHelper::SatCnoHelper ( )

Default constructor.

Definition at line 53 of file satellite-cno-helper.cc.

References ns3::SatEnums::RX_CNO_INPUT_TRACE.

◆ SatCnoHelper() [2/2]

ns3::SatCnoHelper::SatCnoHelper ( Ptr< SatHelper satHelper)

Create a base SatCnoHelper.

Parameters
satHelperThe satellite Helper

Definition at line 61 of file satellite-cno-helper.cc.

References ns3::SatEnums::RX_CNO_INPUT_TRACE.

◆ ~SatCnoHelper()

virtual ns3::SatCnoHelper::~SatCnoHelper ( )
inlinevirtual

Destructor for SatCnoHelper.

Definition at line 80 of file satellite-cno-helper.h.

Member Function Documentation

◆ ApplyConfiguration()

void ns3::SatCnoHelper::ApplyConfiguration ( )
private

Apply configuration to all the satellite channels Needs to be done after node creation.

Definition at line 207 of file satellite-cno-helper.cc.

References ns3::SatEnums::FORWARD_FEEDER_CH, ns3::SatEnums::FORWARD_USER_CH, m_customCno, m_satHelper, m_useTraces, ns3::SatEnums::RETURN_FEEDER_CH, and ns3::SatEnums::RETURN_USER_CH.

Referenced by SetGwNodeCno(), SetGwNodeCnoFile(), SetUtNodeCno(), SetUtNodeCnoFile(), and UseTracesForDefault().

+ Here is the caller graph for this function:

◆ CheckDuplicate()

bool ns3::SatCnoHelper::CheckDuplicate ( Ptr< Node >  node,
SatEnums::ChannelType_t  channel 
)
private

Verify if a node has already been set.

Parameters
nodeThe node to verify
Returns
true if the node is aleady stored in m_customCno

Definition at line 293 of file satellite-cno-helper.cc.

References m_customCno.

Referenced by SetGwNodeCno(), SetGwNodeCnoFile(), SetUtNodeCno(), and SetUtNodeCnoFile().

+ Here is the caller graph for this function:

◆ GetInstanceTypeId()

TypeId ns3::SatCnoHelper::GetInstanceTypeId ( void  ) const

Get the type ID of object instance.

Returns
the TypeId of object instance

Definition at line 46 of file satellite-cno-helper.cc.

References GetTypeId().

+ Here is the call graph for this function:

◆ GetTypeId()

TypeId ns3::SatCnoHelper::GetTypeId ( void  )
static

Get the type ID.

Returns
the object TypeId

Definition at line 38 of file satellite-cno-helper.cc.

Referenced by GetInstanceTypeId().

+ Here is the caller graph for this function:

◆ SetGwNodeCno() [1/3]

void ns3::SatCnoHelper::SetGwNodeCno ( NodeContainer  nodes,
SatEnums::ChannelType_t  channel,
double  cno 
)

Set a constant C/N0 for one GW node and one channel direction.

Parameters
nodesThe nodes to apply the new C/N0
channelThe channel type
cnoThe constant C/N0 value to set

Definition at line 133 of file satellite-cno-helper.cc.

References SetGwNodeCno().

+ Here is the call graph for this function:

◆ SetGwNodeCno() [2/3]

void ns3::SatCnoHelper::SetGwNodeCno ( Ptr< Node >  node,
SatEnums::ChannelType_t  channel,
double  cno 
)

Set a constant C/N0 for one GW node and one channel direction.

Parameters
nodeThe node to apply the new C/N0
channelThe channel type
cnoThe constant C/N0 value to set

Definition at line 77 of file satellite-cno-helper.cc.

References ApplyConfiguration(), ns3::SatCnoHelper::cnoCustomParams_s::channelType, CheckDuplicate(), ns3::SatCnoHelper::cnoCustomParams_s::cno, ns3::SatCnoHelper::cnoCustomParams_s::constant, ns3::SatEnums::FORWARD_FEEDER_CH, ns3::SatCnoHelper::cnoCustomParams_s::isGw, m_customCno, ns3::SatCnoHelper::cnoCustomParams_s::node, and ns3::SatEnums::RETURN_FEEDER_CH.

Referenced by SetGwNodeCno().

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

◆ SetGwNodeCno() [3/3]

void ns3::SatCnoHelper::SetGwNodeCno ( uint32_t  nodeId,
SatEnums::ChannelType_t  channel,
double  cno 
)

Set a constant C/N0 for one GW node and one channel direction.

Parameters
nodeIdThe ID of the node to apply the new C/N0
channelThe channel type
cnoThe constant C/N0 value to set

Definition at line 121 of file satellite-cno-helper.cc.

References m_satHelper, and SetGwNodeCno().

+ Here is the call graph for this function:

◆ SetGwNodeCnoFile() [1/2]

void ns3::SatCnoHelper::SetGwNodeCnoFile ( Ptr< Node >  node,
SatEnums::ChannelType_t  channel,
std::string  path 
)

Set a constant C/N0 for one GW node and one channel direction.

Parameters
nodeThe node to apply the new C/N0
channelThe channel type
pathThe path to the file to read

Definition at line 151 of file satellite-cno-helper.cc.

References ApplyConfiguration(), ns3::SatCnoHelper::cnoCustomParams_s::channelType, CheckDuplicate(), ns3::SatCnoHelper::cnoCustomParams_s::constant, ns3::SatEnums::FORWARD_FEEDER_CH, ns3::SatCnoHelper::cnoCustomParams_s::isGw, m_customCno, ns3::SatCnoHelper::cnoCustomParams_s::node, ns3::SatCnoHelper::cnoCustomParams_s::pathToFile, and ns3::SatEnums::RETURN_FEEDER_CH.

Referenced by SetGwNodeCnoFile().

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

◆ SetGwNodeCnoFile() [2/2]

void ns3::SatCnoHelper::SetGwNodeCnoFile ( uint32_t  nodeId,
SatEnums::ChannelType_t  channel,
std::string  path 
)

Set a constant C/N0 for one GW node and one channel direction.

Parameters
nodeIdThe ID of the node to apply the new C/N0
channelThe channel type
pathThe path to the file to read

Definition at line 195 of file satellite-cno-helper.cc.

References m_satHelper, and SetGwNodeCnoFile().

+ Here is the call graph for this function:

◆ SetUtNodeCno() [1/3]

void ns3::SatCnoHelper::SetUtNodeCno ( NodeContainer  nodes,
SatEnums::ChannelType_t  channel,
double  cno 
)

Set a constant C/N0 for one UT node and one channel direction.

Parameters
nodesThe nodes to apply the new C/N0
channelThe channel type
cnoThe constant C/N0 value to set

Definition at line 142 of file satellite-cno-helper.cc.

References SetUtNodeCno().

+ Here is the call graph for this function:

◆ SetUtNodeCno() [2/3]

void ns3::SatCnoHelper::SetUtNodeCno ( Ptr< Node >  node,
SatEnums::ChannelType_t  channel,
double  cno 
)

Set a constant C/N0 for one UT node and one channel direction.

Parameters
nodeThe node to apply the new C/N0
channelThe channel type
cnoThe constant C/N0 value to set

Definition at line 99 of file satellite-cno-helper.cc.

References ApplyConfiguration(), ns3::SatCnoHelper::cnoCustomParams_s::channelType, CheckDuplicate(), ns3::SatCnoHelper::cnoCustomParams_s::cno, ns3::SatCnoHelper::cnoCustomParams_s::constant, ns3::SatEnums::FORWARD_USER_CH, ns3::SatCnoHelper::cnoCustomParams_s::isGw, m_customCno, ns3::SatCnoHelper::cnoCustomParams_s::node, and ns3::SatEnums::RETURN_USER_CH.

Referenced by SetUtNodeCno().

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

◆ SetUtNodeCno() [3/3]

void ns3::SatCnoHelper::SetUtNodeCno ( uint32_t  nodeId,
SatEnums::ChannelType_t  channel,
double  cno 
)

Set a constant C/N0 for one UT node and one channel direction.

Parameters
nodeIdThe ID of the node to apply the new C/N0
channelThe channel type
cnoThe constant C/N0 value to set

Definition at line 127 of file satellite-cno-helper.cc.

References m_satHelper, and SetUtNodeCno().

+ Here is the call graph for this function:

◆ SetUtNodeCnoFile() [1/2]

void ns3::SatCnoHelper::SetUtNodeCnoFile ( Ptr< Node >  node,
SatEnums::ChannelType_t  channel,
std::string  path 
)

Set a constant C/N0 for one UT node and one channel direction.

Parameters
nodeThe node to apply the new C/N0
channelThe channel type
pathThe path to the file to read

Definition at line 173 of file satellite-cno-helper.cc.

References ApplyConfiguration(), ns3::SatCnoHelper::cnoCustomParams_s::channelType, CheckDuplicate(), ns3::SatCnoHelper::cnoCustomParams_s::constant, ns3::SatEnums::FORWARD_USER_CH, ns3::SatCnoHelper::cnoCustomParams_s::isGw, m_customCno, ns3::SatCnoHelper::cnoCustomParams_s::node, ns3::SatCnoHelper::cnoCustomParams_s::pathToFile, and ns3::SatEnums::RETURN_USER_CH.

Referenced by SetUtNodeCnoFile().

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

◆ SetUtNodeCnoFile() [2/2]

void ns3::SatCnoHelper::SetUtNodeCnoFile ( uint32_t  nodeId,
SatEnums::ChannelType_t  channel,
std::string  path 
)

Set a constant C/N0 for one UT node and one channel direction.

Parameters
nodeIdThe ID of the node to apply the new C/N0
channelThe channel type
pathThe path to the file to read

Definition at line 201 of file satellite-cno-helper.cc.

References m_satHelper, and SetUtNodeCnoFile().

+ Here is the call graph for this function:

◆ UseTracesForDefault()

void ns3::SatCnoHelper::UseTracesForDefault ( bool  useTraces)

Set m_useTraces attribute.

Definition at line 70 of file satellite-cno-helper.cc.

References ApplyConfiguration(), and m_useTraces.

+ Here is the call graph for this function:

Member Data Documentation

◆ m_customCno

std::vector<cnoCustomParams_s> ns3::SatCnoHelper::m_customCno
private

Array storing manual C/N0 updates (constant or custom file)

Definition at line 184 of file satellite-cno-helper.h.

Referenced by ApplyConfiguration(), CheckDuplicate(), SetGwNodeCno(), SetGwNodeCnoFile(), SetUtNodeCno(), and SetUtNodeCnoFile().

◆ m_satHelper

Ptr<SatHelper> ns3::SatCnoHelper::m_satHelper
private

Pointer to the SatHelper objet.

Definition at line 174 of file satellite-cno-helper.h.

Referenced by ApplyConfiguration(), SetGwNodeCno(), SetGwNodeCnoFile(), SetUtNodeCno(), and SetUtNodeCnoFile().

◆ m_useTraces

bool ns3::SatCnoHelper::m_useTraces
private

Use C/N0 input traces instead of power calculation from antenna gain.

Definition at line 179 of file satellite-cno-helper.h.

Referenced by ApplyConfiguration(), and UseTracesForDefault().


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