#include <spectrum-analyzer.h>
Public Member Functions | |
Ptr< NetDevice > | GetDevice () |
Ptr< MobilityModel > | GetMobility () |
Ptr< AntennaModel > | GetRxAntenna () |
Ptr< const SpectrumModel > | GetRxSpectrumModel () const |
void | SetAntenna (Ptr< AntennaModel > a) |
void | SetChannel (Ptr< SpectrumChannel > c) |
void | SetDevice (Ptr< NetDevice > d) |
void | SetMobility (Ptr< MobilityModel > m) |
void | SetRxSpectrumModel (Ptr< SpectrumModel > m) |
virtual void | Start () |
void | StartRx (Ptr< SpectrumSignalParameters > params) |
virtual void | Stop () |
Public Member Functions inherited from ns3::Object | |
void | AggregateObject (Ptr< Object > other) |
void | Dispose (void) |
AggregateIterator | GetAggregateIterator (void) const |
virtual TypeId | GetInstanceTypeId (void) const |
template<typename T > | |
Ptr< T > | GetObject (void) const |
template<typename T > | |
Ptr< T > | GetObject (TypeId tid) const |
void | Initialize (void) |
Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter > | |
SimpleRefCount (const SimpleRefCount &o) | |
uint32_t | GetReferenceCount (void) const |
SimpleRefCount & | operator= (const SimpleRefCount &o) |
void | Ref (void) const |
void | Unref (void) const |
Public Member Functions inherited from ns3::ObjectBase | |
void | GetAttribute (std::string name, AttributeValue &value) const |
bool | GetAttributeFailSafe (std::string name, AttributeValue &attribute) const |
void | SetAttribute (std::string name, const AttributeValue &value) |
bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
Static Public Member Functions | |
static TypeId | GetTypeId (void) |
Static Public Member Functions inherited from ns3::SpectrumPhy | |
static TypeId | GetTypeId (void) |
Static Public Member Functions inherited from ns3::Object | |
static TypeId | GetTypeId (void) |
Static Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter > | |
static void | Cleanup (void) |
Static Public Member Functions inherited from ns3::ObjectBase | |
static TypeId | GetTypeId (void) |
Protected Member Functions | |
void | DoDispose () |
Protected Member Functions inherited from ns3::Object | |
Object (const Object &o) | |
virtual void | DoInitialize (void) |
virtual void | NotifyNewAggregate (void) |
Protected Member Functions inherited from ns3::ObjectBase | |
void | ConstructSelf (const AttributeConstructionList &attributes) |
virtual void | NotifyConstructionCompleted (void) |
Private Member Functions | |
void | AddSignal (Ptr< const SpectrumValue > psd) |
virtual void | GenerateReport () |
void | SubtractSignal (Ptr< const SpectrumValue > psd) |
void | UpdateEnergyReceivedSoFar () |
Private Attributes | |
bool | m_active |
Ptr< AntennaModel > | m_antenna |
TracedCallback< Ptr< const SpectrumValue > > | m_averagePowerSpectralDensityReportTrace |
Ptr< SpectrumChannel > | m_channel |
Ptr< SpectrumValue > | m_energySpectralDensity |
Time | m_lastChangeTime |
Ptr< MobilityModel > | m_mobility |
Ptr< NetDevice > | m_netDevice |
double | m_noisePowerSpectralDensity |
Time | m_resolution |
Ptr< SpectrumModel > | m_spectrumModel |
Ptr< SpectrumValue > | m_sumPowerSpectralDensity |
Simple SpectrumPhy implemetation that averages the spectrum power density of incoming transmissions to produce a spectrogram.
This PHY model supports a single antenna model instance which is used for reception (this PHY model never transmits).
Doxygen introspection did not find any typical Config paths.
Definition at line 48 of file spectrum-analyzer.h.
|
protectedvirtual |
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.
Definition at line 57 of file spectrum-analyzer.cc.
References ns3::Object::DoDispose(), and NS_LOG_FUNCTION.
get the associated NetDevice instance
Implements ns3::SpectrumPhy.
Definition at line 96 of file spectrum-analyzer.cc.
|
virtual |
get the associated MobilityModel instance
Implements ns3::SpectrumPhy.
Definition at line 103 of file spectrum-analyzer.cc.
|
virtual |
get the AntennaModel used by the NetDevice for reception
Implements ns3::SpectrumPhy.
Definition at line 140 of file spectrum-analyzer.cc.
|
virtual |
Implements ns3::SpectrumPhy.
Definition at line 110 of file spectrum-analyzer.cc.
void ns3::SpectrumAnalyzer::SetAntenna | ( | Ptr< AntennaModel > | a | ) |
set the AntennaModel to be used
a | the Antenna Model |
Definition at line 146 of file spectrum-analyzer.cc.
References NS_LOG_FUNCTION.
|
virtual |
Set the channel attached to this device.
c | the channel |
Implements ns3::SpectrumPhy.
Definition at line 132 of file spectrum-analyzer.cc.
References NS_LOG_FUNCTION.
set the associated NetDevice instance
d | the NetDevice instance |
Implements ns3::SpectrumPhy.
Definition at line 116 of file spectrum-analyzer.cc.
References NS_LOG_FUNCTION.
|
virtual |
Set the mobility model associated with this device.
m | the mobility model |
Implements ns3::SpectrumPhy.
Definition at line 124 of file spectrum-analyzer.cc.
References NS_LOG_FUNCTION.
void ns3::SpectrumAnalyzer::SetRxSpectrumModel | ( | Ptr< SpectrumModel > | m | ) |
Set the spectrum model used by the SpectrumAnalyzer to represent incoming signals
m |
Definition at line 219 of file spectrum-analyzer.cc.
References NS_ASSERT, and NS_LOG_FUNCTION.
|
virtual |
Start the spectrum analyzer
Definition at line 233 of file spectrum-analyzer.cc.
References NS_LOG_FUNCTION, NS_LOG_LOGIC, and ns3::Simulator::Schedule().
|
virtual |
Notify the SpectrumPhy instance of an incoming signal
params | the parameters of the signals being received |
Implements ns3::SpectrumPhy.
Definition at line 155 of file spectrum-analyzer.cc.
References NS_LOG_FUNCTION, and ns3::Simulator::Schedule().
|
virtual |
Stop the spectrum analyzer
Definition at line 246 of file spectrum-analyzer.cc.