ns-3
ns3::LteSpectrumPhy Class Reference

#include <lte-spectrum-phy.h>

Inheritance diagram for ns3::LteSpectrumPhy:
Collaboration diagram for ns3::LteSpectrumPhy:

List of all members.

Public Types

enum  State { IDLE, TX, RX }

Public Member Functions

virtual void DoDispose ()
void SetChannel (Ptr< SpectrumChannel > c)
void SetMobility (Ptr< MobilityModel > m)
void SetDevice (Ptr< NetDevice > d)
Ptr< MobilityModelGetMobility ()
Ptr< NetDeviceGetDevice ()
Ptr< const SpectrumModelGetRxSpectrumModel () const
Ptr< AntennaModelGetRxAntenna ()
void StartRx (Ptr< SpectrumSignalParameters > params)
void SetTxPowerSpectralDensity (Ptr< SpectrumValue > txPsd)
void SetNoisePowerSpectralDensity (Ptr< const SpectrumValue > noisePsd)
 set the noise power spectral density
void SetAntenna (Ptr< AntennaModel > a)
bool StartTx (Ptr< PacketBurst > pb)
void SetGenericPhyTxEndCallback (GenericPhyTxEndCallback c)
void SetGenericPhyRxEndErrorCallback (GenericPhyRxEndErrorCallback c)
void SetGenericPhyRxEndOkCallback (GenericPhyRxEndOkCallback c)
void SetState (State newState)
 Set the state of the phy layer.
void SetCellId (uint16_t cellId)
void AddSinrChunkProcessor (Ptr< LteSinrChunkProcessor > p)
void AddExpectedTb (uint16_t rnti, uint16_t size, uint8_t mcs, std::vector< int > map, uint8_t layer)
void UpdateSinrPerceived (const SpectrumValue &sinr)
void SetTransmissionMode (uint8_t txMode)

Static Public Member Functions

static TypeId GetTypeId (void)
 This method returns the TypeId associated to ns3::LteSpectrumPhy.

Friends

class LteUePhy

Detailed Description

The LteSpectrumPhy models the physical layer of LTE

It supports a single antenna model instance which is used for both transmission and reception.


Member Enumeration Documentation

PHY states


Member Function Documentation

void ns3::LteSpectrumPhy::AddExpectedTb ( uint16_t  rnti,
uint16_t  size,
uint8_t  mcs,
std::vector< int >  map,
uint8_t  layer 
)
Parameters:
rntithe rnti of the source of the TB
sizethe size of the TB
mcsthe MCS of the TB
mapthe map of RB(s) used
layerthe layer (in case of MIMO tx)

References NS_LOG_LOGIC.

Referenced by ns3::LteUePhy::ReceiveIdealControlMessage(), and ns3::LteEnbPhy::StartSubFrame().

void ns3::LteSpectrumPhy::AddSinrChunkProcessor ( Ptr< LteSinrChunkProcessor p)
Parameters:
pthe new LteSinrChunkProcessor to be added to the processing chain

References ns3::LteInterference::AddSinrChunkProcessor().

void ns3::LteSpectrumPhy::DoDispose ( void  )
virtual

This method is called by Object::Dispose or by the object's destructor, whichever comes first.

Subclasses are expected to implement their real destruction code in an overriden version of this method and chain up to their parent's implementation once they are done. i.e., for simplicity, the destructor of every subclass should be empty and its content should be moved to the associated DoDispose method.

It is safe to call GetObject from within this method.

Reimplemented from ns3::Object.

References ns3::Object::Dispose(), and NS_LOG_FUNCTION.

Ptr< NetDevice > ns3::LteSpectrumPhy::GetDevice ( )
virtual

get the associated NetDevice instance

Returns:
a Ptr to the associated NetDevice instance

Implements ns3::SpectrumPhy.

References NS_LOG_FUNCTION.

Ptr< MobilityModel > ns3::LteSpectrumPhy::GetMobility ( )
virtual

get the associated MobilityModel instance

Returns:
a Ptr to the associated MobilityModel instance

Implements ns3::SpectrumPhy.

References NS_LOG_FUNCTION.

Referenced by ns3::LteHelper::Attach().

Ptr< AntennaModel > ns3::LteSpectrumPhy::GetRxAntenna ( )
virtual

get the AntennaModel used by the NetDevice for reception

Returns:
a Ptr to the AntennaModel used by the NetDevice for reception

Implements ns3::SpectrumPhy.

Ptr< const SpectrumModel > ns3::LteSpectrumPhy::GetRxSpectrumModel ( ) const
virtual
Returns:
returns the SpectrumModel that this SpectrumPhy expects to be used for all SpectrumValues that are passed to StartRx. If 0 is returned, it means that any model will be accepted.

Implements ns3::SpectrumPhy.

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

This method returns the TypeId associated to ns3::LteSpectrumPhy.

Attributes defined for this type:

  • PemEnabled: Activate/Deactivate the error model (by default is active).
    • Set with class: BooleanValue
    • Underlying type: bool
    • Initial value: true
    • Flags: construct write read

TraceSources defined for this type:

  • TxStart: Trace fired when a new transmission is started
  • TxEnd: Trace fired when a previosuly started transmission is finished
  • RxStart: Trace fired when the start of a signal is detected
  • RxEndOk: Trace fired when a previosuly started RX terminates successfully
  • RxEndError: Trace fired when a previosuly started RX terminates with an error

Reimplemented from ns3::SpectrumPhy.

References ns3::MakeTraceSourceAccessor(), and ns3::TypeId::SetParent().

void ns3::LteSpectrumPhy::SetAntenna ( Ptr< AntennaModel a)

set the AntennaModel to be used

Parameters:
athe Antenna Model

References NS_LOG_FUNCTION.

void ns3::LteSpectrumPhy::SetCellId ( uint16_t  cellId)
Parameters:
cellIdthe Cell Identifier

Referenced by ns3::LtePhy::DoSetCellId(), and ns3::LteUePhy::SetEnbCellId().

void ns3::LteSpectrumPhy::SetChannel ( Ptr< SpectrumChannel c)
virtual

Set the channel attached to this device.

Parameters:
cthe channel

Implements ns3::SpectrumPhy.

References NS_LOG_FUNCTION.

Referenced by ns3::LtePhy::SetDownlinkChannel(), and ns3::LtePhy::SetUplinkChannel().

void ns3::LteSpectrumPhy::SetDevice ( Ptr< NetDevice d)
virtual

set the associated NetDevice instance

Parameters:
dthe NetDevice instance

Implements ns3::SpectrumPhy.

References NS_LOG_FUNCTION.

void ns3::LteSpectrumPhy::SetGenericPhyRxEndErrorCallback ( GenericPhyRxEndErrorCallback  c)

set the callback for the end of a RX in error, as part of the interconnections betweenthe PHY and the MAC

Parameters:
cthe callback

References NS_LOG_FUNCTION.

void ns3::LteSpectrumPhy::SetGenericPhyRxEndOkCallback ( GenericPhyRxEndOkCallback  c)

set the callback for the successful end of a RX, as part of the interconnections betweenthe PHY and the MAC

Parameters:
cthe callback

References NS_LOG_FUNCTION.

void ns3::LteSpectrumPhy::SetGenericPhyTxEndCallback ( GenericPhyTxEndCallback  c)

set the callback for the end of a TX, as part of the interconnections betweenthe PHY and the MAC

Parameters:
cthe callback

References NS_LOG_FUNCTION.

void ns3::LteSpectrumPhy::SetMobility ( Ptr< MobilityModel m)
virtual

Set the mobility model associated with this device.

Parameters:
mthe mobility model

Implements ns3::SpectrumPhy.

References NS_LOG_FUNCTION.

void ns3::LteSpectrumPhy::SetNoisePowerSpectralDensity ( Ptr< const SpectrumValue noisePsd)

set the noise power spectral density

Parameters:
noisePsdthe Noise Power Spectral Density in power units (Watt, Pascal...) per Hz.

References ns3::SpectrumValue::GetSpectrumModel(), NS_ASSERT, NS_LOG_FUNCTION, and ns3::LteInterference::SetNoisePowerSpectralDensity().

Referenced by ns3::LteEnbPhy::DoStart(), and ns3::LteUePhy::DoStart().

void ns3::LteSpectrumPhy::SetState ( State  newState)

Set the state of the phy layer.

Parameters:
newStatethe state
void ns3::LteSpectrumPhy::SetTransmissionMode ( uint8_t  txMode)
Parameters:
txModeUE transmission mode (SISO, MIMO tx diversity, ...)

References NS_ASSERT_MSG, and NS_LOG_FUNCTION.

void ns3::LteSpectrumPhy::SetTxPowerSpectralDensity ( Ptr< SpectrumValue txPsd)

set the Power Spectral Density of outgoing signals in W/Hz.

Parameters:
txPsd

References NS_ASSERT, and NS_LOG_FUNCTION.

Referenced by ns3::LteEnbPhy::DoSetDownlinkSubChannels(), and ns3::LteUePhy::SetSubChannelsForTransmission().

void ns3::LteSpectrumPhy::StartRx ( Ptr< SpectrumSignalParameters params)
virtual

Notify the SpectrumPhy instance of an incoming signal

Parameters:
paramsthe parameters of the signals being received

Implements ns3::SpectrumPhy.

References ns3::LteInterference::AddSignal(), ns3::Now(), ns3::Simulator::Now(), NS_ASSERT, NS_FATAL_ERROR, NS_LOG_FUNCTION, NS_LOG_LOGIC, ns3::Packet::RemovePacketTag(), ns3::Simulator::Schedule(), and ns3::LteInterference::StartRx().

bool ns3::LteSpectrumPhy::StartTx ( Ptr< PacketBurst pb)

Start a transmission

Parameters:
pbthe burst of packets to be transmitted
Returns:
true if an error occurred and the transmission was not started, false otherwise.

References ns3::Packet::AddPacketTag(), NS_ASSERT, NS_FATAL_ERROR, NS_LOG_FUNCTION, NS_LOG_LOGIC, ns3::Simulator::Schedule(), ns3::Seconds(), and ns3::SpectrumChannel::StartTx().

Referenced by ns3::LteEnbPhy::StartSubFrame(), and ns3::LteUePhy::SubframeIndication().

void ns3::LteSpectrumPhy::UpdateSinrPerceived ( const SpectrumValue sinr)
Parameters:
sinrvector of sinr perceived per each RB

References NS_LOG_FUNCTION.


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