|
A Discrete-Event Network Simulator
|
API
|
Go to the documentation of this file.
24 #include <ns3/object-factory.h>
26 #include <ns3/double.h>
27 #include <ns3/simulator.h>
28 #include <ns3/trace-source-accessor.h>
29 #include <ns3/lte-spectrum-signal-parameters.h>
30 #include <ns3/antenna-model.h>
42 m_referenceSignalPower (0),
45 m_useDataChannel (false),
134 if (lteDlDataRxParams != 0)
140 power = (*(params->psd))[
m_rbId] * 180000;
157 if (lteDlCtrlRxParams != 0)
163 power = (*(params->psd))[
m_rbId] * 180000;
a unique identifier for an interface.
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
double Integral(const SpectrumValue &arg)
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
void SetChannel(Ptr< SpectrumChannel > c)
Set the channel attached to this device.
This minimal SpectrumPhy implementation calculates the SINR with respect to the strongest signal for ...
double m_sumPower
sum power
Ptr< const SpectrumModel > m_rxSpectrumModel
receive spectrum model
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Ptr< MobilityModel > GetMobility() const
Get the associated MobilityModel instance.
double m_referenceSignalPower
reference signal power
void Reset()
Reset the SINR calculator.
Smart pointer class similar to boost::intrusive_ptr.
Ptr< NetDevice > GetDevice() const
Get the associated NetDevice instance.
void SetRxSpectrumModel(Ptr< const SpectrumModel > m)
set the RX spectrum model to be used
Ptr< const SpectrumModel > GetRxSpectrumModel() const
void Deactivate()
make StartRx a no-op from now on, and mark instance as inactive
Ptr< MobilityModel > m_mobility
the mobility model
Abstract base class for Spectrum-aware PHY layers.
double GetSinr(double noisePower)
#define NS_LOG_DEBUG(msg)
Use NS_LOG to output a message of level LOG_DEBUG.
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
void SetDevice(Ptr< NetDevice > d)
Set the associated NetDevice instance.
void DoDispose()
Destructor implementation.
Ptr< AntennaModel > GetRxAntenna() const
Get the AntennaModel used by the NetDevice for reception.
bool m_useDataChannel
use data channel
virtual ~RemSpectrumPhy()
void SetMobility(Ptr< MobilityModel > m)
Set the mobility model associated with this device.
void StartRx(Ptr< SpectrumSignalParameters > params)
Notify the SpectrumPhy instance of an incoming signal.
virtual void DoDispose(void)
Destructor implementation.
static TypeId GetTypeId(void)
Get the type ID.
void SetRbId(int32_t rbId)
set RB Id
void SetUseDataChannel(bool value)
set usage of DataChannel