24 #include "ns3/event-id.h" 25 #include "ns3/wifi-phy.h" 40 .SetGroupName (
"Wave")
68 found = ConstCast<Packet> (packet)->PeekPacketTag (datatag);
116 uint32_t curChannel =
phy->GetChannelNumber ();
118 if (!
m_scheduler->IsAlternatingAccessAssigned (curChannel))
127 if (transmissionTime > remainingTime)
132 <<
"ms exceeds the remainingTime = " << remainingTime.
GetMilliSeconds ()
133 <<
"ms, currently this packet will not be transmitted.");
virtual void StartTransmission(Ptr< const Packet > packet, const WifiMacHeader *hdr, MacLowTransmissionParameters parameters, Ptr< Txop > txop)
Simulation virtual time values and global simulation resolution.
This class is the subclass of MacLow to provide support for MAC extension (1) allows higher layer con...
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by "...
bool IsAdaptable(void) const
This class mimics the TXVECTOR which is to be passed to the PHY in order to define the parameters whi...
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
void SetChannelWidth(uint16_t channelWidth)
Sets the selected channelWidth (in MHz)
#define NS_ASSERT(condition)
At runtime, in debugging builds, if this condition is not true, the program prints the source file...
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Time NeedTimeToGuardInterval(Time duration=Seconds(0.0)) const
virtual WifiTxVector GetDataTxVector(Ptr< const Packet > packet, const WifiMacHeader *hdr) const
Return a TXVECTOR for the DATA frame given the destination.
Ptr< ChannelScheduler > GetChannelScheduler(void) const
static TypeId GetTypeId(void)
Get the type ID.
virtual void StartTransmission(Ptr< const Packet > packet, const WifiMacHeader *hdr, MacLowTransmissionParameters parameters, Ptr< Txop > txop)
Ptr< ChannelScheduler > m_scheduler
the channel scheduler
Time CalculateTransmissionTime(Ptr< const Packet > packet, const WifiMacHeader *hdr, const MacLowTransmissionParameters ¶meters) const
control how a packet is transmitted.
This tag will be used to support higher layer control DataRate and TxPwr_Level for transmission...
WifiPreamble GetPreambleType(void) const
WifiTxVector GetTxVector(void) const
WifiMode GetMode(void) const
Ptr< ChannelCoordinator > GetChannelCoordinator(void) const
Every class exported by the ns3 library is enclosed in the ns3 namespace.
void SetPreambleType(WifiPreamble preamble)
Sets the preamble type.
void SetTxPowerLevel(uint8_t powerlevel)
Sets the selected transmission power level.
virtual WifiTxVector GetDataTxVector(Ptr< const Packet > packet, const WifiMacHeader *hdr) const
Return a TXVECTOR for the DATA frame given the destination.
void SetMode(WifiMode mode)
Sets the selected payload transmission mode.
handle RTS/CTS/DATA/ACK transactions.
int64_t GetMilliSeconds(void) const
Get an approximation of the time stored in this instance in the indicated unit.
#define NS_LOG_DEBUG(msg)
Use NS_LOG to output a message of level LOG_DEBUG.
uint8_t GetTxPowerLevel(void) const
uint16_t GetChannelWidth(void) const
Ptr< ChannelCoordinator > m_coordinator
the channel coordinator
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
Set the parent TypeId.
uint64_t GetDataRate(uint16_t channelWidth, uint16_t guardInterval, uint8_t nss) const
Ptr< WifiPhy > GetPhy(void) const
void SetWaveNetDevice(Ptr< WaveNetDevice > device)