|
A Discrete-Event Network Simulator
|
API
|
Go to the documentation of this file.
26 #include "ns3/traced-value.h"
33 class QosBlockedDestinations;
34 class MgtAddBaResponseHeader;
36 class AggregationCapableTransmissionListener;
38 class QosFrameExchangeManager;
39 class WifiTxParameters;
360 Time availableTime,
bool initialFrame,
445 uint32_t
GetMinCw (
void)
const override;
453 uint32_t
GetMaxCw (
void)
const override;
461 uint8_t
GetAifsn (
void)
const override;
a unique identifier for an interface.
QosTxop(AcIndex ac=AC_UNDEF)
Constructor.
Ptr< BlockAckManager > m_baManager
the block ack manager
void DoDispose(void) override
Destructor implementation.
uint16_t GetBaBufferSize(Mac48Address address, uint8_t tid) const
Every class exported by the ns3 library is enclosed in the ns3 namespace.
bool m_useExplicitBarAfterMissedBlockAck
flag whether explicit BlockAckRequest should be sent upon missed BlockAck Response
Ptr< QosBlockedDestinations > m_qosBlockedDestinations
the QoS blocked destinations
uint8_t GetBlockAckThreshold(void) const
Return the current threshold for block ack mechanism.
uint32_t m_muCwMax
the MU CW maximum
bool GetBaAgreementEstablished(Mac48Address address, uint8_t tid) const
void GotAddBaResponse(const MgtAddBaResponseHeader *respHdr, Mac48Address recipient)
Event handler when an ADDBA response is received.
Ptr< BlockAckManager > GetBaManager(void)
Get the Block Ack Manager associated with this QosTxop.
void GotDelBaFrame(const MgtDelBaHeader *delBaHdr, Mac48Address recipient)
Event handler when a DELBA frame is received.
void SetBlockAckInactivityTimeout(uint16_t timeout)
Set the BlockAck inactivity timeout.
uint16_t PeekNextSequenceNumberFor(const WifiMacHeader *hdr)
Return the next sequence number for the Traffic ID and destination, but do not pick it (i....
bool UseExplicitBarAfterMissedBlockAck(void) const
Return true if an explicit BlockAckRequest is sent after a missed BlockAck.
uint8_t m_muAifsn
the MU AIFSN
uint16_t GetNextSequenceNumberFor(const WifiMacHeader *hdr)
Return the next sequence number for the given header.
Ptr< const WifiMacQueueItem > PeekNextMpdu(uint8_t tid=8, Mac48Address recipient=Mac48Address::GetBroadcast())
Peek the next frame to transmit to the given receiver and of the given TID from the block ack manager...
uint8_t GetQosQueueSize(uint8_t tid, Mac48Address receiver) const
Get the value for the Queue Size subfield of the QoS Control field of a QoS data frame of the given T...
This class stores the TX parameters (TX vector, protection mechanism, acknowledgment mechanism,...
void AddBaResponseTimeout(Mac48Address recipient, uint8_t tid)
Callback when ADDBA response is not received after timeout.
void NotifyChannelAccessed(Time txopDuration) override
Called by the FrameExchangeManager to notify that channel access has been granted for the given amoun...
void SetDroppedMpduCallback(DroppedMpdu callback) override
uint16_t GetBlockAckInactivityTimeout(void) const
Get the BlockAck inactivity timeout.
void SetQosFrameExchangeManager(const Ptr< QosFrameExchangeManager > qosFem)
Set the Frame Exchange Manager associated with this QoS STA.
void DoInitialize(void) override
Initialize() implementation.
void SetBlockAckThreshold(uint8_t threshold)
Set threshold for block ack mechanism.
uint16_t GetBaStartingSequence(Mac48Address address, uint8_t tid) const
BlockAckReqType GetBlockAckReqType(Mac48Address recipient, uint8_t tid) const
Smart pointer class similar to boost::intrusive_ptr.
static Mac48Address GetBroadcast(void)
std::list< Ptr< WifiMacQueueItem > >::const_iterator ConstIterator
Const iterator typedef.
friend class AggregationCapableTransmissionListener
allow AggregationCapableTransmissionListener class access
void SetMuCwMin(uint16_t cwMin)
Set the minimum contention window size to use while the MU EDCA Timer is running.
AcIndex GetAccessCategory(void) const
Get the access category of this object.
void SetMuEdcaTimer(Time timer)
Set the MU EDCA Timer.
The different BlockAckRequest variants.
Time m_muEdcaTimerStartTime
last start time of the MU EDCA Timer
uint8_t GetAifsn(void) const override
Return the number of slots that make up an AIFS according to the EDCA Parameter Set or the MU EDCA Pa...
void AssignSequenceNumber(Ptr< WifiMacQueueItem > mpdu) const
Assign a sequence number to the given MPDU, if it is not a fragment and it is not a retransmitted fra...
void ResetBa(Mac48Address recipient, uint8_t tid)
Reset BA agreement after BA negotiation failed.
Time m_failedAddBaTimeout
timeout after failed BA agreement
@ AC_UNDEF
Total number of ACs.
The different BlockAck variants.
bool HasFramesToTransmit(void) override
Check if the Txop has frames to transmit.
Ptr< QosFrameExchangeManager > m_qosFem
the QoS Frame Exchange Manager
void SetFailedAddBaTimeout(Time failedAddBaTimeout)
Set the timeout for failed BA agreement.
Simulation virtual time values and global simulation resolution.
void PushFront(Ptr< const Packet > packet, const WifiMacHeader &hdr)
uint16_t m_blockAckInactivityTimeout
the BlockAck inactivity timeout value (in TUs, i.e.
Time GetAddBaResponseTimeout(void) const
Get the timeout for ADDBA response.
Handle packet fragmentation and retransmissions for QoS data frames as well as MSDU aggregation (A-MS...
Time m_txopDuration
the duration of a TXOP
Ptr< const WifiMacQueueItem > PrepareBlockAckRequest(Mac48Address recipient, uint8_t tid) const
void SetAddBaResponseTimeout(Time addBaResponseTimeout)
Set the timeout to wait for ADDBA response.
Time m_currentPacketTimestamp
the current packet timestamp
Time m_addBaResponseTimeout
timeout for ADDBA response
uint32_t GetMinCw(void) const override
Return the minimum contention window size from the EDCA Parameter Set or the MU EDCA Parameter Set,...
bool IsQosOldPacket(Ptr< const WifiMacQueueItem > mpdu)
Check if the given MPDU is to be considered old according to the current starting sequence number of ...
AcIndex m_ac
the access category
Ptr< WifiMacQueueItem > GetNextMpdu(Ptr< const WifiMacQueueItem > peekedItem, WifiTxParameters &txParams, Time availableTime, bool initialFrame, WifiMacQueueItem::ConstIterator &queueIt)
Prepare the frame to transmit starting from the MPDU that has been previously peeked by calling PeekN...
uint32_t m_muCwMin
the MU CW minimum
void NotifyChannelReleased(void) override
Called by the FrameExchangeManager to notify the completion of the transmissions.
uint32_t GetMaxCw(void) const override
Return the maximum contention window size from the EDCA Parameter Set or the MU EDCA Parameter Set,...
Time m_muEdcaTimer
the MU EDCA Timer
AcIndex
This enumeration defines the Access Categories as an enumeration with values corresponding to the AC ...
void StartMuEdcaTimerNow(void)
Start the MU EDCA Timer.
void ScheduleBar(Ptr< const WifiMacQueueItem > bar, bool skipIfNoDataQueued=false)
Time m_startTxop
the start TXOP time
bool EdcaDisabled(void) const
Return true if the EDCA is disabled (the MU EDCA Timer is running and the MU AIFSN is zero),...
BlockAckType GetBlockAckType(Mac48Address recipient, uint8_t tid) const
uint8_t m_blockAckThreshold
the block ack threshold (use BA mechanism if number of packets in queue reaches this value.
bool MuEdcaTimerRunning(void) const
Return true if the MU EDCA Timer is running, false otherwise.
void CompleteMpduTx(Ptr< WifiMacQueueItem > mpdu)
Stores an MPDU (part of an A-MPDU) in block ack agreement (i.e.
bool IsQosTxop(void) const override
Check for QoS TXOP.
void SetMuAifsn(uint8_t aifsn)
Set the number of slots that make up an AIFS while the MU EDCA Timer is running.
void SetMuCwMax(uint16_t cwMax)
Set the maximum contention window size to use while the MU EDCA Timer is running.
virtual bool IsTxopStarted(void) const
Return true if a TXOP has started.
Time GetFailedAddBaTimeout(void) const
Get the timeout for failed BA agreement.
static TypeId GetTypeId(void)
Get the type ID.
TracedCallback< Time, Time > m_txopTrace
TXOP trace callback.
virtual Time GetRemainingTxop(void) const
Return the remaining duration in the current TXOP.
Handle packet fragmentation and retransmissions for data and management frames.