#include "wimax-phy.h"
Public Types | |
enum | ModulationType { MODULATION_TYPE_BPSK_12, MODULATION_TYPE_QPSK_12, MODULATION_TYPE_QPSK_34, MODULATION_TYPE_QAM16_12, MODULATION_TYPE_QAM16_34, MODULATION_TYPE_QAM64_23, MODULATION_TYPE_QAM64_34 } |
ModulationType enumeration. More... | |
enum | PhyState { PHY_STATE_IDLE, PHY_STATE_SCANNING, PHY_STATE_TX, PHY_STATE_RX } |
PhyState enumeration. More... | |
enum | PhyType { SimpleWimaxPhy, simpleOfdmWimaxPhy } |
PhyType enumeration. More... | |
Public Member Functions | |
WimaxPhy (void) | |
virtual | ~WimaxPhy (void) |
virtual int64_t | AssignStreams (int64_t stream)=0 |
Assign a fixed random variable stream number to the random variables used by this model. More... | |
void | Attach (Ptr< WimaxChannel > channel) |
Attach the physical layer to a channel. More... | |
virtual void | DoDispose (void) |
Destructor implementation. More... | |
Ptr< WimaxChannel > | GetChannel (void) const |
uint32_t | GetChannelBandwidth (void) const |
Get the channel bandwidth. More... | |
EventId | GetChnlSrchTimeoutEvent (void) const |
Get channel search timeout event. More... | |
uint32_t | GetDataRate (ModulationType modulationType) const |
Get the data rate corresponding to a modulation type. More... | |
Ptr< NetDevice > | GetDevice (void) const |
Time | GetFrameDuration (void) const |
Get the frame duration. More... | |
Time | GetFrameDuration (uint8_t frameDurationCode) const |
Get the frame duration corresponding to a given code. More... | |
uint8_t | GetFrameDurationCode (void) const |
Get the frame duration code. More... | |
Time | GetFrameDurationSec (void) const |
Get the frame duration This method is redundant with GetFrameDuration () More... | |
uint32_t | GetFrequency (void) const |
Get the frequency on which the device is locked. More... | |
double | GetGValue (void) const |
Get the guard interval factor (the ratio TG/Td) More... | |
virtual Ptr< Object > | GetMobility (void) |
Get the mobility model of the device. More... | |
uint16_t | GetNfft (void) const |
Get the size of the FFT. More... | |
uint64_t | GetNrBytes (uint32_t symbols, ModulationType modulationType) const |
Get the maximum number of bytes that could be carried by symbols symbols using the modulation modulationType. More... | |
uint8_t | GetNrCarriers (void) const |
Get the number of carriers in the physical frame. More... | |
uint64_t | GetNrSymbols (uint32_t size, ModulationType modulationType) const |
Get the number of symbols needed to transmit size bytes using the modulation modulationType. More... | |
virtual PhyType | GetPhyType (void) const =0 |
Get the type of the physical layer. More... | |
Time | GetPsDuration (void) const |
Get the physical slot duration. More... | |
uint16_t | GetPsPerFrame (void) const |
Get the number of physical slots per frame. More... | |
uint16_t | GetPsPerSymbol (void) const |
Get the number of physical slots per symbol. More... | |
Callback< void, Ptr< const PacketBurst > > | GetReceiveCallback (void) const |
uint16_t | GetRtg (void) const |
Get the receive/transmit transition gap. More... | |
uint64_t | GetRxFrequency (void) const |
Get the reception frequency. More... | |
double | GetSamplingFactor (void) const |
Get the sampling factor. More... | |
double | GetSamplingFrequency (void) const |
Get the sampling frequency. More... | |
uint64_t | GetScanningFrequency (void) const |
Get the scanning frequency. More... | |
PhyState | GetState (void) const |
Get the state of the device. More... | |
Time | GetSymbolDuration (void) const |
Get the OFDM symbol duration. More... | |
uint32_t | GetSymbolsPerFrame (void) const |
Get the number of symbols per frame. More... | |
Time | GetTransmissionTime (uint32_t size, ModulationType modulationType) const |
Get transmission time needed to send bytes at a given modulation. More... | |
uint16_t | GetTtg (void) const |
Get the transmit/receive transition gap. More... | |
uint64_t | GetTxFrequency (void) const |
Get the transmission frequency. More... | |
bool | IsDuplex (void) const |
Check if configured in duplex mode. More... | |
virtual void | Send (SendParams *params)=0 |
send a packet on the channel More... | |
void | SetChannelBandwidth (uint32_t channelBandwidth) |
Set the channel bandwidth. More... | |
void | SetDataRates (void) |
calculates the data rate of each modulation and save them for future use More... | |
void | SetDevice (Ptr< WimaxNetDevice > device) |
Set the device in which this physical layer is installed. More... | |
void | SetDuplex (uint64_t rxFrequency, uint64_t txFrequency) |
configure the physical layer in duplex mode More... | |
void | SetFrameDuration (Time frameDuration) |
Set the frame duration. More... | |
void | SetFrequency (uint32_t frequency) |
set the frequency on which the device should lock More... | |
virtual void | SetMobility (Ptr< Object > mobility) |
set the mobility model of the device More... | |
void | SetNrCarriers (uint8_t nrCarriers) |
Set the number of carriers in the physical frame. More... | |
void | SetPhyParameters (void) |
computes the Physical parameters and store them More... | |
void | SetPsDuration (Time psDuration) |
set the physical slot duration More... | |
void | SetPsPerFrame (uint16_t psPerFrame) |
set the number of physical slots per frame More... | |
void | SetPsPerSymbol (uint16_t psPerSymbol) |
set the number of physical slots per symbol More... | |
void | SetReceiveCallback (Callback< void, Ptr< const PacketBurst > > callback) |
set the callback function to call when a burst is received More... | |
void | SetScanningCallback (void) const |
calls the scanning call back function More... | |
void | SetSimplex (uint64_t frequency) |
configure the physical layer in simplex mode More... | |
void | SetState (PhyState state) |
set the state of the device More... | |
void | SetSymbolDuration (Time symbolDuration) |
set the OFDM symbol duration More... | |
void | SetSymbolsPerFrame (uint32_t symbolsPerFrame) |
set the number of symbols per frame More... | |
void | StartScanning (uint64_t frequency, Time timeout, Callback< void, bool, uint64_t > callback) |
scan a frequency for maximum timeout seconds and call the callback if the frequency can be used More... | |
Public Member Functions inherited from ns3::Object | |
Object () | |
Constructor. More... | |
virtual | ~Object () |
Destructor. More... | |
void | AggregateObject (Ptr< Object > other) |
Aggregate two Objects together. More... | |
void | Dispose (void) |
Dispose of this Object. More... | |
AggregateIterator | GetAggregateIterator (void) const |
Get an iterator to the Objects aggregated to this one. More... | |
virtual TypeId | GetInstanceTypeId (void) const |
Get the most derived TypeId for this Object. More... | |
template<typename T > | |
Ptr< T > | GetObject (void) const |
Get a pointer to the requested aggregated Object. More... | |
template<typename T > | |
Ptr< T > | GetObject (TypeId tid) const |
Get a pointer to the requested aggregated Object by TypeId. More... | |
void | Initialize (void) |
Invoke DoInitialize on all Objects aggregated to this one. More... | |
bool | IsInitialized (void) const |
Check if the object has been initialized. More... | |
Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter > | |
SimpleRefCount () | |
Default constructor. More... | |
SimpleRefCount (const SimpleRefCount &o) | |
Copy constructor. More... | |
uint32_t | GetReferenceCount (void) const |
Get the reference count of the object. More... | |
SimpleRefCount & | operator= (const SimpleRefCount &o) |
Assignment operator. More... | |
void | Ref (void) const |
Increment the reference count. More... | |
void | Unref (void) const |
Decrement the reference count. More... | |
Public Member Functions inherited from ns3::ObjectBase | |
virtual | ~ObjectBase () |
Virtual destructor. More... | |
void | GetAttribute (std::string name, AttributeValue &value) const |
Get the value of an attribute, raising fatal errors if unsuccessful. More... | |
bool | GetAttributeFailSafe (std::string name, AttributeValue &value) const |
Get the value of an attribute without raising erros. More... | |
void | SetAttribute (std::string name, const AttributeValue &value) |
Set a single attribute, raising fatal errors if unsuccessful. More... | |
bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
Set a single attribute without raising errors. More... | |
bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
Connect a TraceSource to a Callback with a context. More... | |
bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
Connect a TraceSource to a Callback without a context. More... | |
bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected with a context. More... | |
bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected without a context. More... | |
Static Public Member Functions | |
static TypeId | GetTypeId (void) |
Get the type ID. More... | |
Static Public Member Functions inherited from ns3::Object | |
static TypeId | GetTypeId (void) |
Register this type. More... | |
Static Public Member Functions inherited from ns3::ObjectBase | |
static TypeId | GetTypeId (void) |
Get the type ID. More... | |
Private Member Functions | |
virtual void | DoAttach (Ptr< WimaxChannel > channel)=0 |
Attach channel. More... | |
virtual uint32_t | DoGetDataRate (ModulationType modulationType) const =0 |
Get data rate. More... | |
virtual Time | DoGetFrameDuration (uint8_t frameDurationCode) const =0 |
Get frame duration. More... | |
virtual uint8_t | DoGetFrameDurationCode (void) const =0 |
Get frame duration code. More... | |
virtual double | DoGetGValue (void) const =0 |
Get G value. More... | |
virtual uint16_t | DoGetNfft (void) const =0 |
Get NFFT. More... | |
virtual uint64_t | DoGetNrBytes (uint32_t symbols, ModulationType modulationType) const =0 |
Get number of bytes. More... | |
virtual uint64_t | DoGetNrSymbols (uint32_t size, ModulationType modulationType) const =0 |
Get number of symbols. More... | |
virtual uint16_t | DoGetRtg (void) const =0 |
Get RTG. More... | |
virtual double | DoGetSamplingFactor (void) const =0 |
Get sampling factor. More... | |
virtual double | DoGetSamplingFrequency (void) const =0 |
Get sampling frequency. More... | |
virtual Time | DoGetTransmissionTime (uint32_t size, ModulationType modulationType) const =0 |
Get transmission time. More... | |
virtual uint16_t | DoGetTtg (void) const =0 |
Get TTG. More... | |
virtual void | DoSetDataRates (void)=0 |
Set data rates. More... | |
virtual void | DoSetPhyParameters (void)=0 |
Set phy parameters. More... | |
void | EndScanning (void) |
End scanning. More... | |
void | GetModulationFecParams (ModulationType modulationType, uint8_t &bitsPerSymbol, double &fecCode) const |
Get modulation FEC parameters. More... | |
Private Attributes | |
Ptr< WimaxChannel > | m_channel |
channel More... | |
uint32_t | m_channelBandwidth |
in Hz More... | |
Ptr< WimaxNetDevice > | m_device |
the device More... | |
EventId | m_dlChnlSrchTimeoutEvent |
DL channel search timeout event. More... | |
bool | m_duplex |
duplex More... | |
Time | m_frameDuration |
in seconds More... | |
uint32_t | m_frequency |
in KHz More... | |
Ptr< Object > | m_mobility |
modility model More... | |
uint8_t | m_nrCarriers |
number of carriers More... | |
Time | m_psDuration |
in seconds More... | |
uint16_t | m_psPerFrame |
ps per framce More... | |
uint16_t | m_psPerSymbol |
ps per sumbol More... | |
Callback< void, Ptr< const PacketBurst > > | m_rxCallback |
receive callback function More... | |
uint64_t | m_rxFrequency |
receive frequency More... | |
Callback< void, bool, uint64_t > | m_scanningCallback |
scanning callback function More... | |
uint64_t | m_scanningFrequency |
scanning frequency More... | |
PhyState | m_state |
state More... | |
Time | m_symbolDuration |
in seconds More... | |
uint32_t | m_symbolsPerFrame |
symbols per frame More... | |
uint64_t | m_txFrequency |
transmit frequency More... | |
Additional Inherited Members | |
Protected Member Functions inherited from ns3::Object | |
Object (const Object &o) | |
Copy an Object. More... | |
virtual void | DoInitialize (void) |
Initialize() implementation. More... | |
virtual void | NotifyNewAggregate (void) |
Notify all Objects aggregated to this one of a new Object being aggregated. More... | |
Protected Member Functions inherited from ns3::ObjectBase | |
void | ConstructSelf (const AttributeConstructionList &attributes) |
Complete construction of ObjectBase; invoked by derived classes. More... | |
virtual void | NotifyConstructionCompleted (void) |
Notifier called once the ObjectBase is fully constructed. More... | |
Related Functions inherited from ns3::ObjectBase | |
static TypeId | GetObjectIid (void) |
Ensure the TypeId for ObjectBase gets fully configured to anchor the inheritance tree properly. More... | |
ns3::WimaxPhy is accessible through the following paths with Config::Set and Config::Connect:
No TraceSources are defined for this type.
Size of this type is 176 bytes (on a 64-bit architecture).
Definition at line 45 of file wimax-phy.h.
ModulationType enumeration.
Enumerator | |
---|---|
MODULATION_TYPE_BPSK_12 | |
MODULATION_TYPE_QPSK_12 | |
MODULATION_TYPE_QPSK_34 | |
MODULATION_TYPE_QAM16_12 | |
MODULATION_TYPE_QAM16_34 | |
MODULATION_TYPE_QAM64_23 | |
MODULATION_TYPE_QAM64_34 |
Definition at line 49 of file wimax-phy.h.
PhyState enumeration.
Enumerator | |
---|---|
PHY_STATE_IDLE | |
PHY_STATE_SCANNING | |
PHY_STATE_TX | |
PHY_STATE_RX |
Definition at line 61 of file wimax-phy.h.
PhyType enumeration.
Enumerator | |
---|---|
SimpleWimaxPhy | |
simpleOfdmWimaxPhy |
Definition at line 70 of file wimax-phy.h.
ns3::WimaxPhy::WimaxPhy | ( | void | ) |
Definition at line 75 of file wimax-phy.cc.
References m_duplex, m_mobility, m_rxFrequency, and m_txFrequency.
|
virtual |
Definition at line 94 of file wimax-phy.cc.
|
pure virtual |
Assign a fixed random variable stream number to the random variables used by this model.
Return the number of streams (possibly zero) that have been assigned.
stream | first stream index to use |
Implemented in ns3::SimpleOfdmWimaxPhy.
void ns3::WimaxPhy::Attach | ( | Ptr< WimaxChannel > | channel | ) |
Attach the physical layer to a channel.
channel | the channel to which the physical layer will be attached |
Definition at line 106 of file wimax-phy.cc.
References third::channel, DoAttach(), and m_channel.
Referenced by GetTypeId().
|
privatepure virtual |
Attach channel.
channel | the wimax channel |
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by Attach().
|
virtual |
Destructor implementation.
This method is called by Dispose() or by the Object's destructor, whichever comes first.
Subclasses are expected to implement their real destruction code in an overridden 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.
Reimplemented in ns3::SimpleOfdmWimaxPhy.
Definition at line 99 of file wimax-phy.cc.
References m_channel, and m_device.
Referenced by ns3::SimpleOfdmWimaxPhy::DoDispose().
|
privatepure virtual |
Get data rate.
modulationType | the modulation type |
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetDataRate().
|
privatepure virtual |
Get frame duration.
frameDurationCode | the frame duration code |
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetFrameDuration().
|
privatepure virtual |
Get frame duration code.
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetFrameDurationCode().
|
privatepure virtual |
|
privatepure virtual |
|
privatepure virtual |
Get number of bytes.
symbols | the number of symbols |
modulationType | the modulation type |
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetNrBytes().
|
privatepure virtual |
Get number of symbols.
size | the transmission size |
modulationType | the modulation type |
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetNrSymbols().
|
privatepure virtual |
|
privatepure virtual |
Get sampling factor.
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetSamplingFactor().
|
privatepure virtual |
Get sampling frequency.
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetSamplingFrequency().
|
privatepure virtual |
Get transmission time.
size | the transmission size |
modulationType | the modulation type |
Implemented in ns3::SimpleOfdmWimaxPhy.
Referenced by GetTransmissionTime().
|
privatepure virtual |
|
privatepure virtual |
|
privatepure virtual |
|
private |
End scanning.
Definition at line 143 of file wimax-phy.cc.
References m_scanningCallback, and m_scanningFrequency.
Referenced by StartScanning().
Ptr< WimaxChannel > ns3::WimaxPhy::GetChannel | ( | void | ) | const |
Definition at line 113 of file wimax-phy.cc.
References m_channel.
Referenced by ns3::SimpleOfdmWimaxPhy::DoAttach(), GetTypeId(), and ns3::SimpleOfdmWimaxPhy::StartSendDummyFecBlock().
uint32_t ns3::WimaxPhy::GetChannelBandwidth | ( | void | ) | const |
Get the channel bandwidth.
Definition at line 332 of file wimax-phy.cc.
References m_channelBandwidth.
Referenced by ns3::SimpleOfdmWimaxPhy::DoGetSamplingFactor(), ns3::SimpleOfdmWimaxPhy::DoGetSamplingFrequency(), ns3::SimpleOfdmWimaxPhy::GetBandwidth(), and GetTypeId().
EventId ns3::WimaxPhy::GetChnlSrchTimeoutEvent | ( | void | ) | const |
Get channel search timeout event.
Definition at line 210 of file wimax-phy.cc.
References m_dlChnlSrchTimeoutEvent.
Referenced by ns3::SimpleOfdmWimaxPhy::StartReceive().
uint32_t ns3::WimaxPhy::GetDataRate | ( | WimaxPhy::ModulationType | modulationType | ) | const |
Get the data rate corresponding to a modulation type.
modulationType | the modulation that you want to get its data rate |
Definition at line 228 of file wimax-phy.cc.
References DoGetDataRate().
Definition at line 125 of file wimax-phy.cc.
References m_device.
Time ns3::WimaxPhy::GetFrameDuration | ( | void | ) | const |
Get the frame duration.
Definition at line 302 of file wimax-phy.cc.
References GetFrameDurationSec().
Referenced by ns3::SimpleOfdmWimaxPhy::DoGetFrameDurationCode(), and ns3::SimpleOfdmWimaxPhy::DoSetPhyParameters().
Time ns3::WimaxPhy::GetFrameDuration | ( | uint8_t | frameDurationCode | ) | const |
Get the frame duration corresponding to a given code.
frameDurationCode | the frame duration code to use |
Definition at line 270 of file wimax-phy.cc.
References DoGetFrameDuration().
uint8_t ns3::WimaxPhy::GetFrameDurationCode | ( | void | ) | const |
Get the frame duration code.
Definition at line 264 of file wimax-phy.cc.
References DoGetFrameDurationCode().
Time ns3::WimaxPhy::GetFrameDurationSec | ( | void | ) | const |
Get the frame duration This method is redundant with GetFrameDuration ()
Definition at line 308 of file wimax-phy.cc.
References m_frameDuration.
Referenced by GetFrameDuration(), and GetTypeId().
uint32_t ns3::WimaxPhy::GetFrequency | ( | void | ) | const |
Get the frequency on which the device is locked.
Definition at line 320 of file wimax-phy.cc.
References m_frequency.
Referenced by GetTypeId().
double ns3::WimaxPhy::GetGValue | ( | void | ) | const |
Get the guard interval factor (the ratio TG/Td)
Definition at line 380 of file wimax-phy.cc.
References DoGetGValue().
Get the mobility model of the device.
Definition at line 421 of file wimax-phy.cc.
References m_mobility.
|
private |
Get modulation FEC parameters.
modulationType | the modultion type |
bitsPerSymbol | the number of bits per symbol page |
fecCode | the FEC code |
uint16_t ns3::WimaxPhy::GetNfft | ( | void | ) | const |
Get the size of the FFT.
Definition at line 338 of file wimax-phy.cc.
References DoGetNfft().
uint64_t ns3::WimaxPhy::GetNrBytes | ( | uint32_t | symbols, |
WimaxPhy::ModulationType | modulationType | ||
) | const |
Get the maximum number of bytes that could be carried by symbols symbols using the modulation modulationType.
symbols | the number of symbols to use |
modulationType | the modulation that will be used |
Definition at line 246 of file wimax-phy.cc.
References DoGetNrBytes().
uint8_t ns3::WimaxPhy::GetNrCarriers | ( | void | ) | const |
Get the number of carriers in the physical frame.
Definition at line 290 of file wimax-phy.cc.
References m_nrCarriers.
Referenced by ns3::SimpleOfdmWimaxPhy::CalculateDataRate().
uint64_t ns3::WimaxPhy::GetNrSymbols | ( | uint32_t | size, |
WimaxPhy::ModulationType | modulationType | ||
) | const |
Get the number of symbols needed to transmit size bytes using the modulation modulationType.
size | the number of byte to transmit |
modulationType | the modulation that will be used to transmit the bytes |
Definition at line 240 of file wimax-phy.cc.
References DoGetNrSymbols().
|
pure virtual |
Time ns3::WimaxPhy::GetPsDuration | ( | void | ) | const |
Get the physical slot duration.
Definition at line 362 of file wimax-phy.cc.
References m_psDuration.
uint16_t ns3::WimaxPhy::GetPsPerFrame | ( | void | ) | const |
Get the number of physical slots per frame.
Definition at line 404 of file wimax-phy.cc.
References m_psPerFrame.
uint16_t ns3::WimaxPhy::GetPsPerSymbol | ( | void | ) | const |
Get the number of physical slots per symbol.
Definition at line 392 of file wimax-phy.cc.
References m_psPerSymbol.
Referenced by ns3::SimpleOfdmWimaxPhy::DoGetRtg(), and ns3::SimpleOfdmWimaxPhy::DoGetTtg().
Callback< void, Ptr< const PacketBurst > > ns3::WimaxPhy::GetReceiveCallback | ( | void | ) | const |
Definition at line 155 of file wimax-phy.cc.
References m_rxCallback.
Referenced by ns3::SimpleOfdmWimaxPhy::EndReceive().
uint16_t ns3::WimaxPhy::GetRtg | ( | void | ) | const |
Get the receive/transmit transition gap.
Definition at line 258 of file wimax-phy.cc.
References DoGetRtg().
uint64_t ns3::WimaxPhy::GetRxFrequency | ( | void | ) | const |
Get the reception frequency.
Definition at line 175 of file wimax-phy.cc.
References m_rxFrequency.
Referenced by ns3::SimpleOfdmWimaxPhy::StartReceive().
double ns3::WimaxPhy::GetSamplingFactor | ( | void | ) | const |
Get the sampling factor.
Definition at line 344 of file wimax-phy.cc.
References DoGetSamplingFactor().
double ns3::WimaxPhy::GetSamplingFrequency | ( | void | ) | const |
Get the sampling frequency.
Definition at line 350 of file wimax-phy.cc.
References DoGetSamplingFrequency().
uint64_t ns3::WimaxPhy::GetScanningFrequency | ( | void | ) | const |
Get the scanning frequency.
Definition at line 187 of file wimax-phy.cc.
References m_scanningFrequency.
Referenced by SetScanningCallback(), and ns3::SimpleOfdmWimaxPhy::StartReceive().
WimaxPhy::PhyState ns3::WimaxPhy::GetState | ( | void | ) | const |
Get the state of the device.
Definition at line 198 of file wimax-phy.cc.
References m_state.
Referenced by ns3::SimpleOfdmWimaxPhy::Send(), and ns3::SimpleOfdmWimaxPhy::StartReceive().
Time ns3::WimaxPhy::GetSymbolDuration | ( | void | ) | const |
Get the OFDM symbol duration.
Definition at line 374 of file wimax-phy.cc.
References m_symbolDuration.
Referenced by ns3::SimpleOfdmWimaxPhy::CalculateDataRate(), ns3::SimpleOfdmWimaxPhy::DoGetNrBytes(), ns3::SimpleOfdmWimaxPhy::DoGetNrSymbols(), and ns3::SimpleOfdmWimaxPhy::DoGetTransmissionTime().
uint32_t ns3::WimaxPhy::GetSymbolsPerFrame | ( | void | ) | const |
Get the number of symbols per frame.
Definition at line 416 of file wimax-phy.cc.
References m_symbolsPerFrame.
Time ns3::WimaxPhy::GetTransmissionTime | ( | uint32_t | size, |
WimaxPhy::ModulationType | modulationType | ||
) | const |
Get transmission time needed to send bytes at a given modulation.
size | the number of byte to transmit |
modulationType | the modulation that will be used to transmit the bytes |
Definition at line 234 of file wimax-phy.cc.
References DoGetTransmissionTime().
uint16_t ns3::WimaxPhy::GetTtg | ( | void | ) | const |
Get the transmit/receive transition gap.
Definition at line 252 of file wimax-phy.cc.
References DoGetTtg().
uint64_t ns3::WimaxPhy::GetTxFrequency | ( | void | ) | const |
Get the transmission frequency.
Definition at line 181 of file wimax-phy.cc.
References m_txFrequency.
Referenced by ns3::SimpleOfdmWimaxPhy::StartSendDummyFecBlock().
|
static |
Get the type ID.
Definition at line 39 of file wimax-phy.cc.
References Attach(), GetChannel(), GetChannelBandwidth(), GetFrameDurationSec(), GetFrequency(), ns3::MakePointerAccessor(), ns3::MakeTimeAccessor(), ns3::MakeTimeChecker(), ns3::MakeUintegerAccessor(), ns3::Seconds(), SetChannelBandwidth(), SetFrameDuration(), SetFrequency(), and ns3::TypeId::SetParent().
bool ns3::WimaxPhy::IsDuplex | ( | void | ) | const |
Check if configured in duplex mode.
Definition at line 204 of file wimax-phy.cc.
References m_duplex.
Referenced by ns3::SimpleOfdmWimaxPhy::StartReceive().
|
pure virtual |
send a packet on the channel
params | the parameters used to send the packet |
Implemented in ns3::SimpleOfdmWimaxPhy.
void ns3::WimaxPhy::SetChannelBandwidth | ( | uint32_t | channelBandwidth | ) |
Set the channel bandwidth.
channelBandwidth | The channel bandwidth |
Definition at line 326 of file wimax-phy.cc.
References m_channelBandwidth.
Referenced by GetTypeId(), and ns3::SimpleOfdmWimaxPhy::SetBandwidth().
void ns3::WimaxPhy::SetDataRates | ( | void | ) |
calculates the data rate of each modulation and save them for future use
Definition at line 222 of file wimax-phy.cc.
References DoSetDataRates().
void ns3::WimaxPhy::SetDevice | ( | Ptr< WimaxNetDevice > | device | ) |
Set the device in which this physical layer is installed.
device | the device in which this physical layer is installed |
Definition at line 119 of file wimax-phy.cc.
References m_device.
void ns3::WimaxPhy::SetDuplex | ( | uint64_t | rxFrequency, |
uint64_t | txFrequency | ||
) |
configure the physical layer in duplex mode
rxFrequency | the reception frequency |
txFrequency | the transmission frequency |
Definition at line 161 of file wimax-phy.cc.
References m_rxFrequency, and m_txFrequency.
void ns3::WimaxPhy::SetFrameDuration | ( | Time | frameDuration | ) |
Set the frame duration.
frameDuration | the frame duration |
Definition at line 296 of file wimax-phy.cc.
References m_frameDuration.
Referenced by GetTypeId().
void ns3::WimaxPhy::SetFrequency | ( | uint32_t | frequency | ) |
set the frequency on which the device should lock
frequency | the frequency to configure |
Definition at line 314 of file wimax-phy.cc.
References m_frequency.
Referenced by GetTypeId().
set the mobility model of the device
mobility | the mobility model to set |
Definition at line 427 of file wimax-phy.cc.
References m_mobility, and third::mobility.
void ns3::WimaxPhy::SetNrCarriers | ( | uint8_t | nrCarriers | ) |
Set the number of carriers in the physical frame.
Set the number of carriers in the physical frame
nrCarriers | the number of carriers in the frame |
Definition at line 284 of file wimax-phy.cc.
References m_nrCarriers.
Referenced by ns3::SimpleOfdmWimaxPhy::InitSimpleOfdmWimaxPhy().
void ns3::WimaxPhy::SetPhyParameters | ( | void | ) |
computes the Physical parameters and store them
Definition at line 278 of file wimax-phy.cc.
References DoSetPhyParameters().
void ns3::WimaxPhy::SetPsDuration | ( | Time | psDuration | ) |
set the physical slot duration
psDuration | the physical slot duration |
Definition at line 356 of file wimax-phy.cc.
References m_psDuration.
Referenced by ns3::SimpleOfdmWimaxPhy::DoSetPhyParameters().
void ns3::WimaxPhy::SetPsPerFrame | ( | uint16_t | psPerFrame | ) |
set the number of physical slots per frame
psPerFrame | the number of physical slots per frame |
Definition at line 398 of file wimax-phy.cc.
References m_psPerFrame.
Referenced by ns3::SimpleOfdmWimaxPhy::DoSetPhyParameters().
void ns3::WimaxPhy::SetPsPerSymbol | ( | uint16_t | psPerSymbol | ) |
set the number of physical slots per symbol
psPerSymbol | the number of physical slots per symbol |
Definition at line 386 of file wimax-phy.cc.
References m_psPerSymbol.
Referenced by ns3::SimpleOfdmWimaxPhy::DoSetPhyParameters().
void ns3::WimaxPhy::SetReceiveCallback | ( | Callback< void, Ptr< const PacketBurst > > | callback | ) |
set the callback function to call when a burst is received
callback | the callback function to call when a burst is received |
Definition at line 149 of file wimax-phy.cc.
References m_rxCallback.
void ns3::WimaxPhy::SetScanningCallback | ( | void | ) | const |
calls the scanning call back function
Definition at line 216 of file wimax-phy.cc.
References GetScanningFrequency(), and m_scanningCallback.
Referenced by ns3::SimpleOfdmWimaxPhy::StartReceive().
void ns3::WimaxPhy::SetSimplex | ( | uint64_t | frequency | ) |
configure the physical layer in simplex mode
frequency | the frequency to be used for reception and transmission process |
Definition at line 168 of file wimax-phy.cc.
References m_rxFrequency, and m_txFrequency.
Referenced by ns3::SimpleOfdmWimaxPhy::StartReceive().
void ns3::WimaxPhy::SetState | ( | PhyState | state | ) |
set the state of the device
state | the state to be set (PHY_STATE_IDLE, PHY_STATE_SCANNING, PHY_STATE_TX, PHY_STATE_RX) |
Definition at line 193 of file wimax-phy.cc.
References m_state.
Referenced by ns3::SimpleOfdmWimaxPhy::EndReceiveFecBlock(), ns3::SimpleOfdmWimaxPhy::EndSend(), ns3::SimpleOfdmWimaxPhy::EndSendFecBlock(), ns3::SimpleOfdmWimaxPhy::StartReceive(), and ns3::SimpleOfdmWimaxPhy::StartSendDummyFecBlock().
void ns3::WimaxPhy::SetSymbolDuration | ( | Time | symbolDuration | ) |
set the OFDM symbol duration
symbolDuration | the symbol duration |
Definition at line 368 of file wimax-phy.cc.
References m_symbolDuration.
Referenced by ns3::SimpleOfdmWimaxPhy::DoSetPhyParameters().
void ns3::WimaxPhy::SetSymbolsPerFrame | ( | uint32_t | symbolsPerFrame | ) |
set the number of symbols per frame
symbolsPerFrame | the number of symbols per frame |
Definition at line 410 of file wimax-phy.cc.
References m_symbolsPerFrame.
Referenced by ns3::SimpleOfdmWimaxPhy::DoSetPhyParameters().
void ns3::WimaxPhy::StartScanning | ( | uint64_t | frequency, |
Time | timeout, | ||
Callback< void, bool, uint64_t > | callback | ||
) |
scan a frequency for maximum timeout seconds and call the callback if the frequency can be used
frequency | the frequency to scan |
timeout | the timeout before considering the channel as unusable |
callback | the function to call if the channel could be used |
Definition at line 131 of file wimax-phy.cc.
References EndScanning(), m_dlChnlSrchTimeoutEvent, m_scanningCallback, m_scanningFrequency, m_state, NS_ASSERT_MSG(), PHY_STATE_IDLE, PHY_STATE_SCANNING, ns3::Simulator::Schedule(), and timeout.
|
private |
channel
Definition at line 466 of file wimax-phy.h.
Referenced by Attach(), DoDispose(), and GetChannel().
|
private |
in Hz
Definition at line 481 of file wimax-phy.h.
Referenced by GetChannelBandwidth(), and SetChannelBandwidth().
|
private |
the device
Definition at line 465 of file wimax-phy.h.
Referenced by DoDispose(), GetDevice(), and SetDevice().
|
private |
DL channel search timeout event.
Definition at line 471 of file wimax-phy.h.
Referenced by GetChnlSrchTimeoutEvent(), and StartScanning().
|
private |
|
private |
in seconds
Definition at line 479 of file wimax-phy.h.
Referenced by GetFrameDurationSec(), and SetFrameDuration().
|
private |
in KHz
Definition at line 480 of file wimax-phy.h.
Referenced by GetFrequency(), and SetFrequency().
modility model
Definition at line 487 of file wimax-phy.h.
Referenced by GetMobility(), SetMobility(), and WimaxPhy().
|
private |
number of carriers
Definition at line 478 of file wimax-phy.h.
Referenced by GetNrCarriers(), and SetNrCarriers().
|
private |
in seconds
Definition at line 482 of file wimax-phy.h.
Referenced by GetPsDuration(), and SetPsDuration().
|
private |
ps per framce
Definition at line 485 of file wimax-phy.h.
Referenced by GetPsPerFrame(), and SetPsPerFrame().
|
private |
ps per sumbol
Definition at line 484 of file wimax-phy.h.
Referenced by GetPsPerSymbol(), and SetPsPerSymbol().
|
private |
receive callback function
Definition at line 475 of file wimax-phy.h.
Referenced by GetReceiveCallback(), and SetReceiveCallback().
|
private |
receive frequency
Definition at line 469 of file wimax-phy.h.
Referenced by GetRxFrequency(), SetDuplex(), SetSimplex(), and WimaxPhy().
|
private |
scanning callback function
Definition at line 476 of file wimax-phy.h.
Referenced by EndScanning(), SetScanningCallback(), and StartScanning().
|
private |
scanning frequency
Definition at line 470 of file wimax-phy.h.
Referenced by EndScanning(), GetScanningFrequency(), and StartScanning().
|
private |
state
Definition at line 473 of file wimax-phy.h.
Referenced by GetState(), SetState(), and StartScanning().
|
private |
in seconds
Definition at line 483 of file wimax-phy.h.
Referenced by GetSymbolDuration(), and SetSymbolDuration().
|
private |
symbols per frame
Definition at line 486 of file wimax-phy.h.
Referenced by GetSymbolsPerFrame(), and SetSymbolsPerFrame().
|
private |
transmit frequency
Definition at line 468 of file wimax-phy.h.
Referenced by GetTxFrequency(), SetDuplex(), SetSimplex(), and WimaxPhy().