ns3::SatPhyRxCarrierPerFrame Class Reference

Inherited the functionality of ground station SatPhyRxCarriers and extended it with CRDSA functionality. More...

#include "satellite-phy-rx-carrier-per-frame.h"

+ Inheritance diagram for ns3::SatPhyRxCarrierPerFrame:
+ Collaboration diagram for ns3::SatPhyRxCarrierPerFrame:

Classes

struct  crdsaPacketRxParams_s
 Struct for storing the CRDSA packet specific Rx parameters. More...
 

Public Member Functions

 SatPhyRxCarrierPerFrame (uint32_t carrierId, Ptr< SatPhyRxCarrierConf > carrierConf, Ptr< SatWaveformConf > waveformConf, bool randomAccessEnabled)
 Constructor. More...
 
virtual ~SatPhyRxCarrierPerFrame ()
 Destructor. More...
 
void BeginEndScheduling ()
 Function for initializing the frame end scheduling. More...
 
virtual CarrierType GetCarrierType ()
 Method for querying the type of the carrier. More...
 
- Public Member Functions inherited from ns3::SatPhyRxCarrierPerSlot
 SatPhyRxCarrierPerSlot (uint32_t carrierId, Ptr< SatPhyRxCarrierConf > carrierConf, Ptr< SatWaveformConf > waveformConf, bool randomAccessEnabled)
 Constructor. More...
 
virtual ~SatPhyRxCarrierPerSlot ()
 Destructor. More...
 
uint8_t GetRandomAccessAllocationChannelId () const
 Function for getting the random access allocation channel ID. More...
 
void SetRandomAccessAllocationChannelId (uint8_t randomAccessAllocationChannelId)
 Function for setting the random access allocation channel ID. More...
 
- Public Member Functions inherited from ns3::SatPhyRxCarrier
 SatPhyRxCarrier (uint32_t carrierId, Ptr< SatPhyRxCarrierConf > carrierConf, Ptr< SatWaveformConf > waveformConf, bool isRandomAccessEnabled)
 Constructor. More...
 
virtual ~SatPhyRxCarrier ()
 Destructor. More...
 
uint32_t GetBeamId ()
 Get ID the ID of the beam this carrier is attached to. More...
 
double GetRxTemperatureK ()
 Method for querying the temperature of the carrier. More...
 
uint32_t GetSatId ()
 Get ID the ID of the satellite this carrier is attached to. More...
 
void SetAverageNormalizedOfferedLoadCallback (SatPhyRx::AverageNormalizedOfferedLoadCallback callback)
 Function for setting the AverageNormalizedOfferedLoadCallback callback. More...
 
void SetBeamId (uint32_t beamId)
 Function for setting the beam id for all the transmissions from this SatPhyTx. More...
 
void SetCnoCb (SatPhyRx::CnoCallback cb)
 Function for settign the C/NO callback. More...
 
void SetNodeInfo (const Ptr< SatNodeInfo > nodeInfo)
 Function for setting the node info class. More...
 
void SetPhy (Ptr< SatPhy > phy)
 Function for setting the SatPhy module. More...
 
void SetReceiveCb (SatPhyRx::ReceiveCallback cb)
 Function for setting the receive callback. More...
 
void SetSatId (uint32_t satId)
 Function for setting the satellite id for all the transmissions from this SatPhyTx. More...
 
virtual bool StartRx (Ptr< SatSignalParameters > rxParams)
 Function for starting packet reception from the SatChannel. More...
 

Static Public Member Functions

static bool CompareCrdsaPacketId (SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s obj1, SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s obj2)
 Function for comparing the CRDSA unique packet IDs. More...
 
static TypeId GetTypeId (void)
 Get the TypeId of the class. More...
 
- Static Public Member Functions inherited from ns3::SatPhyRxCarrierPerSlot
static TypeId GetTypeId (void)
 Get the TypeId of the class. More...
 
- Static Public Member Functions inherited from ns3::SatPhyRxCarrier
static TypeId GetTypeId (void)
 Function for gettign the NS-3 type ID. More...
 

Protected Member Functions

double CalculatePacketCompositeSinr (crdsaPacketRxParams_s &packet)
 Function for computing the composite SINR of the given packet. More...
 
virtual void DoDispose ()
 Dispose implementation. More...
 
void EliminateInterference (std::map< uint32_t, std::list< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s >>::iterator iter, SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s processedPacket)
 Function for eliminating the interference to other packets in the slot from the correctly received packet. More...
 
void FindAndRemoveReplicas (SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s packet)
 Function for finding and removing the replicas of the CRDSA packet. More...
 
std::map< uint32_t, std::list< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s > > & GetCrdsaPacketContainer ()
 
bool IsReplica (const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s &packet, const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s &otherPacket) const
 Function for identifying whether the packet is a replica of another packet. More...
 
virtual void PerformSicCycles (std::vector< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s > &combinedPacketsForFrame)
 Function for receiving decodable packets and removing their interference from the other packets in the slots they’re in; perform as many cycles as needed to try to decode each packet. More...
 
virtual void ReceiveSlot (SatPhyRxCarrier::rxParams_s packetRxParams, const uint32_t nPackets)
 Receive a slot. More...
 
- Protected Member Functions inherited from ns3::SatPhyRxCarrierPerSlot
double CalculateAverageNormalizedOfferedRandomAccessLoad ()
 Function for calculating the average normalized offered random access load. More...
 
virtual Ptr< SatInterference::InterferenceChangeEventCreateInterference (Ptr< SatSignalParameters > rxParams, Address rxAddress)
 Create an interference event based on Rx parameters and address. More...
 
virtual void EndRxData (uint32_t key)
 Function for ending the packet reception from the SatChannel. More...
 
SatPhyRxCarrierConf::RandomAccessCollisionModel GetRandomAccessCollisionModel () const
 Get the random access collision model of the carrier. More...
 
bool IsRandomAccessDynamicLoadControlEnabled () const
 Check if random access dynamic load control is enabled. More...
 
void SaveMeasuredRandomAccessLoad (double measuredRandomAccessLoad)
 Function for saving the measured random access load. More...
 
- Protected Member Functions inherited from ns3::SatPhyRxCarrier
double CalculateCompositeSinr (double sinr1, double sinr2)
 Function for calculating the composite SINR. More...
 
double CalculateSinr (double rxPowerW, double ifPowerW, double rxNoisePowerW, double rxAciIfPowerW, double rxExtNoisePowerW, double otherInterference)
 Function for calculating the SINR. More...
 
double CalculateSinr (double sinr, double otherInterference)
 Calculate final SINR with PHY specific parameters and given calculated SINR. More...
 
void ChangeState (State newState)
 Function for changing the receiver state. More...
 
bool CheckAgainstLinkResults (double cSinr, Ptr< SatSignalParameters > rxParams)
 Function for checking the SINR against the link results. More...
 
void CheckRxStateSanity ()
 Function for checking the Rx state sanity. More...
 
void DecreaseNumOfRxState (SatEnums::PacketType_t packetType)
 Function for decreasing the number of ongoing transmissions. More...
 
void DoCompositeSinrOutputTrace (double cSinr)
 Function for composite SINR output tracing. More...
 
virtual void DoCreateInterferenceEliminationModel (Ptr< SatPhyRxCarrierConf > carrierConf, uint32_t carrierId, Ptr< SatWaveformConf > waveformConf)
 Create an interference cancelation model for this carrier. More...
 
virtual void DoCreateInterferenceModel (Ptr< SatPhyRxCarrierConf > carrierConf, uint32_t carrierId, double rxBandwidthHz)
 Create an interference model for this carrier. More...
 
uint32_t GetCarrierId () const
 Get the ID of the carrier. More...
 
Ptr< SatChannelEstimationErrorContainerGetChannelEstimationErrorContainer ()
 Get a pointer to the channel estimation error container of the carrier. More...
 
virtual SatEnums::ChannelType_t GetChannelType ()
 Get the channel type. More...
 
virtual const bool GetDefaultReceiveMode ()
 Get the default receive mode for the carrier. More...
 
Ptr< SatInterferenceEliminationGetInterferenceEliminationModel ()
 Get pointer to the current interference elimination model. More...
 
Ptr< SatInterferenceGetInterferenceModel ()
 Get pointer to the current interference model. More...
 
virtual SatEnums::RegenerationMode_t GetLinkRegenerationMode ()
 Get the link regeneration mode. More...
 
Ptr< SatLinkResultsGetLinkResults ()
 Get pointer to the link results given by the carrier creation configuration. More...
 
Ptr< SatNodeInfoGetNodeInfo ()
 Get the satellite node info. More...
 
Mac48Address GetOwnAddress ()
 Get the MAC address of the carrier. More...
 
std::pair< bool, SatPhyRxCarrier::rxParams_sGetReceiveParams (Ptr< SatSignalParameters > rxParams)
 Rx parameter storage methods. More...
 
State GetState ()
 Get the state of the carrier. More...
 
rxParams_s GetStoredRxParams (uint32_t key)
 Get stored rxParams under a key. More...
 
double GetUniformRandomValue (double min, double max)
 A helper method for getting values form a uniform random variable in child classes. More...
 
Ptr< SatWaveformConfGetWaveformConf ()
 Get pointer to the waveform configuration. More...
 
double GetWorstSinr (double sinr1, double sinr2)
 Function for calculating the worst sinr between uplink and downlink. More...
 
void IncreaseNumOfRxState (SatEnums::PacketType_t packetType)
 Function for increasing the number of ongoing transmissions. More...
 
bool IsCompositeSinrOutputTraceEnabled () const
 Check if composite SINR output trace is enabled. More...
 
bool IsReceivingDedicatedAccess ()
 Check if the carrier is receiving a dedicated access packet. More...
 
void RemoveStoredRxParams (uint32_t key)
 Remove stored rxParams under a key. More...
 
void SetChannelType (SatEnums::ChannelType_t channelType)
 Set the channel type for the carrier. More...
 
void SetLinkRegenerationMode (SatEnums::RegenerationMode_t linkRegenerationMode)
 Set the link regeneration mode. More...
 
void StoreRxParams (uint32_t key, rxParams_s rxParams)
 Store rxParams under a key. More...
 

Private Member Functions

void AddCrdsaPacket (SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s crdsaPacketParams)
 Function for storing the received CRDSA packets. More...
 
double CalculateNormalizedOfferedRandomAccessLoad ()
 Function for calculating the normalized offered random access load. More...
 
void DoFrameEnd ()
 Function for processing the frame interval operations. More...
 
bool HaveSameSlotIds (const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s &packet, const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s &otherPacket) const
 Function for checking do the packets have identical slots. More...
 
void MeasureRandomAccessLoad ()
 Function for measuring the random access load. More...
 
std::vector< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_sProcessFrame ()
 Function for processing the CRDSA frame. More...
 
SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s ProcessReceivedCrdsaPacket (SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s packet, uint32_t numOfPacketsForThisSlot)
 Process received CRDSA packet. More...
 
void UpdateRandomAccessLoad ()
 Update the random access load for CRDSA. More...
 

Private Attributes

std::map< uint32_t, std::list< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s > > m_crdsaPacketContainer
 CRDSA packet container. More...
 
TracedCallback< uint32_t, const Address &, bool > m_crdsaReplicaRxTrace
 CrdsaReplicaRx trace source. More...
 
TracedCallback< uint32_t, const Address &, bool > m_crdsaUniquePayloadRxTrace
 CrdsaUniquePayloadRx trace source. More...
 
bool m_frameEndSchedulingInitialized
 Has the frame end scheduling been initialized. More...
 

Additional Inherited Members

- Public Types inherited from ns3::SatPhyRxCarrier
enum  CarrierType {
  BASE , DEDICATED_ACCESS , RA_SLOTTED_ALOHA , RA_CRDSA ,
  RA_ESSA
}
 Possible carrier types. More...
 
typedef void(* LinkBudgetTraceCallback) (Ptr< SatSignalParameters > rxParams, Mac48Address receiverAddress, Mac48Address destinationAddress, double interference, double sinr)
 Callback signature for LinkBudgetTrace trace source. More...
 
typedef void(* LinkSinrTraceCallback) (double sinr, const Address &utAddress)
 Callback signature for LinkSinrTrace trace source. More...
 
typedef void(* PhyRxCollisionCallback) (uint32_t nPackets, const Address &utAddress, bool isCollided)
 Common callback signature for trace sources related to packets reception by PHY and its collision. More...
 
typedef void(* PhyRxErrorCallback) (uint32_t nPackets, const Address &utAddress, bool isError)
 Common callback signature for trace sources related to packets reception by PHY and its error. More...
 
typedef void(* RxPowerTraceCallback) (double rxPower, const Address &utAddress)
 Callback signature for RxPowerTrace trace source. More...
 
enum  State { IDLE , RX }
 Enum for PHY states. More...
 
- Protected Attributes inherited from ns3::SatPhyRxCarrierPerSlot
uint32_t m_randomAccessBitsInFrame
 The number of random access bits in current frame. More...
 
TracedCallback< uint32_t, const Address &, bool > m_slottedAlohaRxCollisionTrace
 SlottedAlohaRxCollision trace source. More...
 
TracedCallback< uint32_t, const Address &, bool > m_slottedAlohaRxErrorTrace
 SlottedAlohaRxError trace source. More...
 
- Protected Attributes inherited from ns3::SatPhyRxCarrier
SatPhyRxCarrierConf::AdditionalInterferenceCallback m_additionalInterferenceCallback
 Callback to get additional interference. More...
 
SatPhy::AverageNormalizedOfferedLoadCallback m_avgNormalizedOfferedLoadCallback
 Average normalized offered load callback. More...
 
SatPhy::CnoCallback m_cnoCallback
 The upper layer C/N0 receive callback. More...
 
TracedCallback< uint32_t, const Address & > m_daRxCarrierIdTrace
 
TracedCallback< uint32_t, const Address &, bool > m_daRxTrace
 DaRx trace source. More...
 
TracedCallback< Ptr< SatSignalParameters >, Mac48Address, Mac48Address, double, double > m_linkBudgetTrace
 The trace source on packet receptiong. More...
 
SatEnums::RegenerationMode_t m_linkRegenerationMode
 Link regeneration mode. More...
 
TracedCallback< double, const Address & > m_linkSinrTrace
 A callback for link specific SINR in dB. More...
 
const bool m_randomAccessEnabled
 Is random access enabled for this carrier. More...
 
double m_rxAciIfPowerW
 RX Adjacent channel interference. More...
 
double m_rxBandwidthHz
 RX Bandwidth in Hz. More...
 
SatPhyRx::ReceiveCallback m_rxCallback
 The upper layer package receive callback. More...
 
double m_rxExtNoisePowerW
 External noise power system RX noise. More...
 
double m_rxNoisePowerW
 RX noise. More...
 
TracedCallback< double, const Address & > m_rxPowerTrace
 A callback for received signal power in dBW. More...
 
double m_rxTemperatureK
 RX noise temperature in K. More...
 
TracedCallback< double, const Address & > m_sinrTrace
 A callback for transmission composite SINR at UT (BBFrame) or GW (time slot). More...
 

Detailed Description

Inherited the functionality of ground station SatPhyRxCarriers and extended it with CRDSA functionality.

Definition at line 51 of file satellite-phy-rx-carrier-per-frame.h.

Constructor & Destructor Documentation

◆ SatPhyRxCarrierPerFrame()

ns3::SatPhyRxCarrierPerFrame::SatPhyRxCarrierPerFrame ( uint32_t  carrierId,
Ptr< SatPhyRxCarrierConf carrierConf,
Ptr< SatWaveformConf waveformConf,
bool  randomAccessEnabled 
)

Constructor.

Parameters
carrierIdID of the carrier
carrierConfCarrier configuration
waveformConfWaveform configuration
randomAccessEnabledIs this a RA carrier

Definition at line 43 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatPhyRxCarrier::m_randomAccessEnabled.

◆ ~SatPhyRxCarrierPerFrame()

ns3::SatPhyRxCarrierPerFrame::~SatPhyRxCarrierPerFrame ( )
virtual

Destructor.

Definition at line 87 of file satellite-phy-rx-carrier-per-frame.cc.

Member Function Documentation

◆ AddCrdsaPacket()

void ns3::SatPhyRxCarrierPerFrame::AddCrdsaPacket ( SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s  crdsaPacketParams)
private

Function for storing the received CRDSA packets.

Parameters
Rxparameters of the packet

check the first packet for tag

the first slot ID is this replicas own slot ID

rest of the slot IDs are for the replicas

tags are not needed after this

Definition at line 340 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatCrdsaReplicaTag::GetSlotIds(), m_crdsaPacketContainer, ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::ownSlotId, ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::rxParams, and ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::slotIdsForOtherReplicas.

Referenced by ReceiveSlot().

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

◆ BeginEndScheduling()

void ns3::SatPhyRxCarrierPerFrame::BeginEndScheduling ( void  )
virtual

Function for initializing the frame end scheduling.

Reimplemented from ns3::SatPhyRxCarrierPerSlot.

Definition at line 58 of file satellite-phy-rx-carrier-per-frame.cc.

References DoFrameEnd(), ns3::SatPhyRxCarrier::GetNodeInfo(), m_frameEndSchedulingInitialized, and ns3::SatConstVariables::SUPERFRAME_SEQUENCE.

+ Here is the call graph for this function:

◆ CalculateNormalizedOfferedRandomAccessLoad()

double ns3::SatPhyRxCarrierPerFrame::CalculateNormalizedOfferedRandomAccessLoad ( )
private

Function for calculating the normalized offered random access load.

Returns
Normalized offered load

reset the counter

Definition at line 318 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatPhyRxCarrierPerSlot::m_randomAccessBitsInFrame, ns3::SatPhyRxCarrier::m_rxBandwidthHz, and ns3::SatConstVariables::SUPERFRAME_SEQUENCE.

Referenced by MeasureRandomAccessLoad().

+ Here is the caller graph for this function:

◆ CalculatePacketCompositeSinr()

double ns3::SatPhyRxCarrierPerFrame::CalculatePacketCompositeSinr ( SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s packet)
protected

◆ CompareCrdsaPacketId()

bool ns3::SatPhyRxCarrierPerFrame::CompareCrdsaPacketId ( SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s  obj1,
SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s  obj2 
)
static

Function for comparing the CRDSA unique packet IDs.

Parameters
obj1Comparison object 1
obj2Comparison object 2
Returns
Comparison result

Definition at line 889 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::rxParams.

Referenced by DoFrameEnd().

+ Here is the caller graph for this function:

◆ DoDispose()

void ns3::SatPhyRxCarrierPerFrame::DoDispose ( void  )
protectedvirtual

Dispose implementation.

Reimplemented from ns3::SatPhyRxCarrierPerSlot.

Definition at line 113 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatPhyRxCarrierPerSlot::DoDispose(), and m_crdsaPacketContainer.

+ Here is the call graph for this function:

◆ DoFrameEnd()

void ns3::SatPhyRxCarrierPerFrame::DoFrameEnd ( )
private

Function for processing the frame interval operations.

sort the results based on CRDSA packet IDs to make sure the packets are processed in correct order

uses composite sinr

CRDSA trace

send packet upwards

Definition at line 169 of file satellite-phy-rx-carrier-per-frame.cc.

References CompareCrdsaPacketId(), ns3::SatPhyRxCarrier::GetOwnAddress(), ns3::SatPhyRxCarrierPerSlot::IsRandomAccessDynamicLoadControlEnabled(), ns3::SatUtils::LinearToDb(), m_crdsaPacketContainer, m_crdsaUniquePayloadRxTrace, ns3::SatPhyRxCarrier::m_linkBudgetTrace, ns3::SatPhyRxCarrier::m_rxCallback, ns3::SatPhyRxCarrier::m_sinrTrace, MeasureRandomAccessLoad(), ProcessFrame(), ns3::SatConstVariables::SUPERFRAME_SEQUENCE, and UpdateRandomAccessLoad().

Referenced by BeginEndScheduling().

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

◆ EliminateInterference()

void ns3::SatPhyRxCarrierPerFrame::EliminateInterference ( std::map< uint32_t, std::list< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s >>::iterator  iter,
SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s  processedPacket 
)
protected

Function for eliminating the interference to other packets in the slot from the correctly received packet.

Parameters
iterPackets in the slot
processedPacketCorrectly received processed packet

release packets in this slot for re-processing

Reduce interference power for the colliding packets. Note, that the interference is eliminated only from the user link interference power at the satellite! The intra-beam interference is not handled in the return feeder link so that the intra-beam interference is not taken into account twice! TODO A more novel way to eliminate partially overlapping interference should be considered! In addition, as the interference values are extremely small, the use of long double (instead of double) should be considered to improve the accuracy.

Definition at line 748 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::cSinr, ns3::SatPhyRxCarrier::GetInterferenceEliminationModel(), m_crdsaPacketContainer, ns3::SatPhyRxCarrier::m_linkRegenerationMode, ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::rxParams, and ns3::SatEnums::TRANSPARENT.

Referenced by FindAndRemoveReplicas(), ns3::SatPhyRxCarrierMarsala::PerformMarsala(), and PerformSicCycles().

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

◆ FindAndRemoveReplicas()

void ns3::SatPhyRxCarrierPerFrame::FindAndRemoveReplicas ( SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s  packet)
protected

Function for finding and removing the replicas of the CRDSA packet.

Parameters
packetCRDSA packet

get the vector of packets for processing

check for the same UT & same slots

replica found for removal

Definition at line 690 of file satellite-phy-rx-carrier-per-frame.cc.

References CalculatePacketCompositeSinr(), EliminateInterference(), IsReplica(), m_crdsaPacketContainer, ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::phyError, and ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::slotIdsForOtherReplicas.

Referenced by ns3::SatPhyRxCarrierMarsala::PerformMarsala(), PerformSicCycles(), and ProcessFrame().

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

◆ GetCarrierType()

virtual CarrierType ns3::SatPhyRxCarrierPerFrame::GetCarrierType ( )
inlinevirtual

Method for querying the type of the carrier.

Reimplemented from ns3::SatPhyRxCarrierPerSlot.

Definition at line 111 of file satellite-phy-rx-carrier-per-frame.h.

◆ GetCrdsaPacketContainer()

std::map<uint32_t, std::list<SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s> >& ns3::SatPhyRxCarrierPerFrame::GetCrdsaPacketContainer ( )
inlineprotected

Definition at line 170 of file satellite-phy-rx-carrier-per-frame.h.

References m_crdsaPacketContainer.

Referenced by ns3::SatPhyRxCarrierMarsala::PerformMarsala().

+ Here is the caller graph for this function:

◆ GetTypeId()

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

Get the TypeId of the class.

Returns
TypeId

Definition at line 93 of file satellite-phy-rx-carrier-per-frame.cc.

References m_crdsaReplicaRxTrace, and m_crdsaUniquePayloadRxTrace.

◆ HaveSameSlotIds()

bool ns3::SatPhyRxCarrierPerFrame::HaveSameSlotIds ( const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s packet,
const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s otherPacket 
) const
private

Function for checking do the packets have identical slots.

Parameters
packetA packet
otherPacketA packet that we want to check if it has identical slots
Returns
Have the packets identical slots

sanity check

form sets

compare sets

sanity check

Definition at line 827 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::ownSlotId, and ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::slotIdsForOtherReplicas.

Referenced by IsReplica().

+ Here is the caller graph for this function:

◆ IsReplica()

bool ns3::SatPhyRxCarrierPerFrame::IsReplica ( const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s packet,
const SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s otherPacket 
) const
protected

Function for identifying whether the packet is a replica of another packet.

Parameters
packetA packet
otherPacketA packet that we want to check if it is a duplicate
Returns
Is the packet a replica

Definition at line 803 of file satellite-phy-rx-carrier-per-frame.cc.

References HaveSameSlotIds(), and ns3::SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s::sourceAddress.

Referenced by FindAndRemoveReplicas(), and ns3::SatPhyRxCarrierMarsala::FindReplicaInSlot().

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

◆ MeasureRandomAccessLoad()

void ns3::SatPhyRxCarrierPerFrame::MeasureRandomAccessLoad ( )
private

Function for measuring the random access load.

calculate the load for this frame

save the load for this frame

calculate the average load over the measurement window

Definition at line 295 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatPhyRxCarrierPerSlot::CalculateAverageNormalizedOfferedRandomAccessLoad(), CalculateNormalizedOfferedRandomAccessLoad(), ns3::SatPhyRxCarrier::GetBeamId(), ns3::SatPhyRxCarrier::GetCarrierId(), ns3::SatPhyRxCarrierPerSlot::GetRandomAccessAllocationChannelId(), ns3::SatPhyRxCarrier::GetSatId(), ns3::SatPhyRxCarrier::m_avgNormalizedOfferedLoadCallback, and ns3::SatPhyRxCarrierPerSlot::SaveMeasuredRandomAccessLoad().

Referenced by DoFrameEnd().

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

◆ PerformSicCycles()

void ns3::SatPhyRxCarrierPerFrame::PerformSicCycles ( std::vector< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s > &  combinedPacketsForFrame)
protectedvirtual

Function for receiving decodable packets and removing their interference from the other packets in the slots they’re in; perform as many cycles as needed to try to decode each packet.

Parameters
combinedPacketsForFramecontainer to store packets as they are decoded and removed from the frame

reset the flag

go through the packets

process the received packet

packet successfully received

save packet for processing outside the loop

remove the successfully received packet from the container

eliminate the interference caused by this packet to other packets in this slot

break the cycle

successfully received packet found

find and remove replicas of the received packet

save the the received packet

Reimplemented in ns3::SatPhyRxCarrierMarsala.

Definition at line 482 of file satellite-phy-rx-carrier-per-frame.cc.

References EliminateInterference(), FindAndRemoveReplicas(), m_crdsaPacketContainer, and ProcessReceivedCrdsaPacket().

Referenced by ns3::SatPhyRxCarrierMarsala::PerformSicCycles(), and ProcessFrame().

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

◆ ProcessFrame()

std::vector< SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s > ns3::SatPhyRxCarrierPerFrame::ProcessFrame ( )
private

Function for processing the CRDSA frame.

Returns
Processed packets

go through the packets

find and remove replicas of the received packet

save the the received packet

remove the packet from the container

remove the empty slot container

remove the empty slot container

Definition at line 415 of file satellite-phy-rx-carrier-per-frame.cc.

References FindAndRemoveReplicas(), m_crdsaPacketContainer, and PerformSicCycles().

Referenced by DoFrameEnd().

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

◆ ProcessReceivedCrdsaPacket()

SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s ns3::SatPhyRxCarrierPerFrame::ProcessReceivedCrdsaPacket ( SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s  packet,
uint32_t  numOfPacketsForThisSlot 
)
private

◆ ReceiveSlot()

◆ UpdateRandomAccessLoad()

void ns3::SatPhyRxCarrierPerFrame::UpdateRandomAccessLoad ( )
private

Update the random access load for CRDSA.

Count only the received unique payloads.

Definition at line 256 of file satellite-phy-rx-carrier-per-frame.cc.

References ns3::SatConstVariables::BITS_PER_BYTE, m_crdsaPacketContainer, and ns3::SatPhyRxCarrierPerSlot::m_randomAccessBitsInFrame.

Referenced by DoFrameEnd().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_crdsaPacketContainer

std::map<uint32_t, std::list<SatPhyRxCarrierPerFrame::crdsaPacketRxParams_s> > ns3::SatPhyRxCarrierPerFrame::m_crdsaPacketContainer
private

◆ m_crdsaReplicaRxTrace

TracedCallback<uint32_t, const Address&, bool> ns3::SatPhyRxCarrierPerFrame::m_crdsaReplicaRxTrace
private

CrdsaReplicaRx trace source.

Fired when a CRDSA packet replica is received through Random Access CRDSA.

Contains the following information:

  • number of upper layer packets in the received packet burst;
  • the MAC48 address of the sender; and
  • whether a collision has occurred.

Definition at line 192 of file satellite-phy-rx-carrier-per-frame.h.

Referenced by GetTypeId(), and ReceiveSlot().

◆ m_crdsaUniquePayloadRxTrace

TracedCallback<uint32_t, const Address&, bool> ns3::SatPhyRxCarrierPerFrame::m_crdsaUniquePayloadRxTrace
private

CrdsaUniquePayloadRx trace source.

Fired when a unique CRDSA payload is received (after frame processing) through Random Access CRDSA.

Contains the following information:

  • number of upper layer packets in the received packet burst;
  • the MAC48 address of the sender; and
  • whether a PHY error has occurred.

Definition at line 205 of file satellite-phy-rx-carrier-per-frame.h.

Referenced by DoFrameEnd(), and GetTypeId().

◆ m_frameEndSchedulingInitialized

bool ns3::SatPhyRxCarrierPerFrame::m_frameEndSchedulingInitialized
private

Has the frame end scheduling been initialized.

Definition at line 260 of file satellite-phy-rx-carrier-per-frame.h.

Referenced by BeginEndScheduling().


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