EmlsrManager is an abstract base class defining the API that EHT non-AP MLDs with EMLSR activated can use to handle the operations on the EMLSR links. More...
#include "emlsr-manager.h"
Classes | |
struct | MainPhySwitchInfo |
Store information about a main PHY switch. More... | |
struct | MediumSyncDelayStatus |
Information about the status of the MediumSyncDelay timer associated with a link. More... | |
Public Member Functions | |
EmlsrManager () | |
~EmlsrManager () override | |
void | CancelMediumSyncDelayTimer (uint8_t linkId) |
Cancel the MediumSyncDelay timer associated with the given link and take the appropriate actions. | |
std::pair< bool, Time > | CheckPossiblyReceivingIcf (uint8_t linkId) const |
Check whether a PPDU that may be an ICF is being received on the given link. | |
void | DecrementMediumSyncDelayNTxops (uint8_t linkId) |
Decrement the counter indicating the number of TXOP attempts left while the MediumSyncDelay timer is running. | |
bool | GetAuxPhyTxCapable () const |
bool | GetCamStateReset () const |
std::pair< bool, Time > | GetDelayUntilAccessRequest (uint8_t linkId, AcIndex aci) |
Notify that an UL TXOP is gained on the given link by the given AC. | |
std::optional< Time > | GetElapsedMediumSyncDelayTimer (uint8_t linkId) const |
Check whether the MediumSyncDelay timer is running for the STA operating on the given link. | |
const std::set< uint8_t > & | GetEmlsrLinks () const |
bool | GetInDeviceInterference () const |
uint8_t | GetMainPhyId () const |
Time | GetMediumSyncDuration () const |
std::optional< uint8_t > | GetMediumSyncMaxNTxops () const |
int8_t | GetMediumSyncOfdmEdThreshold () const |
std::optional< Time > | GetTransitionTimeout () const |
bool | MediumSyncDelayNTxopsExceeded (uint8_t linkId) |
Return whether no more TXOP attempt is allowed on the given link. | |
void | NotifyIcfReceived (uint8_t linkId) |
Notify the reception of an initial Control frame on the given link. | |
virtual void | NotifyInDeviceInterferenceStart (uint8_t linkId, Time duration) |
Notify that an STA affiliated with the EMLSR client is causing in-device interference for the given amount of time. | |
void | NotifyMgtFrameReceived (Ptr< const WifiMpdu > mpdu, uint8_t linkId) |
Notify the reception of a management frame addressed to us. | |
void | NotifyProtectionCompleted (uint8_t linkId) |
Notify that protection (if required) is completed and data frame exchange can start on the given link. | |
virtual void | NotifyRtsSent (uint8_t linkId, Ptr< const WifiPsdu > rts, const WifiTxVector &txVector) |
Notify that RTS transmission is starting on the given link. | |
void | NotifyTxopEnd (uint8_t linkId, bool ulTxopNotStarted=false, bool ongoingDlTxop=false) |
Notify the end of a TXOP on the given link. | |
void | NotifyUlTxopStart (uint8_t linkId) |
Notify the start of an UL TXOP on the given link. | |
void | ResetMediumSyncDelayNTxops (uint8_t linkId) |
Reset the counter indicating the number of TXOP attempts left while the MediumSyncDelay timer is running, so as to remove the limit on the number of attempts that can be made while the MediumSyncDelay timer is running. | |
void | SetAuxPhyTxCapable (bool capable) |
Set the member variable indicating whether Aux PHYs are capable of transmitting PPDUs. | |
void | SetCamStateReset (bool enable) |
Set the member variable indicating whether the state of the CAM should be reset when the main PHY switches channel and operates on the link associated with the CAM. | |
void | SetEmlsrLinks (const std::set< uint8_t > &linkIds) |
Take actions to enable EMLSR mode on the given set of links, if non-empty, or disable EMLSR mode, otherwise. | |
void | SetInDeviceInterference (bool enable) |
Set the member variable indicating whether in-device interference is such that a PHY cannot decode anything and cannot decrease the backoff counter when another PHY is transmitting. | |
void | SetMediumSyncDuration (Time duration) |
Set the duration of the MediumSyncDelay timer. | |
void | SetMediumSyncMaxNTxops (std::optional< uint8_t > nTxops) |
Set the maximum number of TXOPs a non-AP STA is allowed to attempt to initiate while the MediumSyncDelay timer is running. | |
void | SetMediumSyncOfdmEdThreshold (int8_t threshold) |
Set the Medium Synchronization OFDM ED threshold (dBm) to use while the MediumSyncDelay timer is running. | |
void | SetTransitionTimeout (Time timeout) |
Set the Transition Timeout advertised by the associated AP with EMLSR activated. | |
void | SetWifiMac (Ptr< StaWifiMac > mac) |
Set the wifi MAC. | |
![]() | |
Object () | |
Constructor. | |
~Object () override | |
Destructor. | |
void | AggregateObject (Ptr< Object > other) |
Aggregate two Objects together. | |
void | Dispose () |
Dispose of this Object. | |
AggregateIterator | GetAggregateIterator () const |
Get an iterator to the Objects aggregated to this one. | |
TypeId | GetInstanceTypeId () const final |
Get the most derived TypeId for this Object. | |
template<typename T > | |
Ptr< T > | GetObject () const |
Get a pointer to the requested aggregated Object. | |
template<> | |
Ptr< Object > | GetObject () const |
Specialization of () for objects of type ns3::Object. | |
template<typename T > | |
Ptr< T > | GetObject (TypeId tid) const |
Get a pointer to the requested aggregated Object by TypeId. | |
template<> | |
Ptr< Object > | GetObject (TypeId tid) const |
Specialization of (TypeId tid) for objects of type ns3::Object. | |
void | Initialize () |
Invoke DoInitialize on all Objects aggregated to this one. | |
bool | IsInitialized () const |
Check if the object has been initialized. | |
void | UnidirectionalAggregateObject (Ptr< Object > other) |
Aggregate an Object to another Object. | |
![]() | |
SimpleRefCount () | |
Default constructor. | |
SimpleRefCount (const SimpleRefCount &o) | |
Copy constructor. | |
uint32_t | GetReferenceCount () const |
Get the reference count of the object. | |
SimpleRefCount & | operator= (const SimpleRefCount &o) |
Assignment operator. | |
void | Ref () const |
Increment the reference count. | |
void | Unref () const |
Decrement the reference count. | |
![]() | |
virtual | ~ObjectBase () |
Virtual destructor. | |
void | GetAttribute (std::string name, AttributeValue &value, bool permissive=false) const |
Get the value of an attribute, raising fatal errors if unsuccessful. | |
bool | GetAttributeFailSafe (std::string name, AttributeValue &value) const |
Get the value of an attribute without raising errors. | |
void | SetAttribute (std::string name, const AttributeValue &value) |
Set a single attribute, raising fatal errors if unsuccessful. | |
bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
Set a single attribute without raising errors. | |
bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
Connect a TraceSource to a Callback with a context. | |
bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
Connect a TraceSource to a Callback without a context. | |
bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected with a context. | |
bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected without a context. | |
Static Public Member Functions | |
static TypeId | GetTypeId () |
Get the type ID. | |
![]() | |
static TypeId | GetTypeId () |
Register this type. | |
![]() | |
static TypeId | GetTypeId () |
Get the type ID. | |
Static Public Attributes | |
static constexpr uint16_t | MEDIUM_SYNC_THRESHOLD_USEC = 72 |
The aMediumSyncThreshold defined by Sec. 35.3.16.18.1 of 802.11be D4.0. | |
Protected Member Functions | |
void | CancelAllSleepEvents () |
Cancel all pending events to put aux PHYs into sleep/awake state. | |
void | DoDispose () override |
Destructor implementation. | |
virtual std::pair< bool, Time > | DoGetDelayUntilAccessRequest (uint8_t linkId)=0 |
Subclasses have to provide an implementation for this method, that is called by the base class when the EMLSR client gets channel access on the given link. | |
virtual void | DoSetWifiMac (Ptr< StaWifiMac > mac) |
Allow subclasses to take actions when the MAC is set. | |
virtual void | EmlsrLinkSwitchCallback (uint8_t linkId, Ptr< WifiPhy > phy) |
Callback connected to the EmlsrLinkSwitch trace source of StaWifiMac. | |
const WifiPhyOperatingChannel & | GetChannelForAuxPhy (uint8_t linkId) const |
const WifiPhyOperatingChannel & | GetChannelForMainPhy (uint8_t linkId) const |
virtual std::pair< bool, Time > | GetDelayUnlessMainPhyTakesOverUlTxop (uint8_t linkId)=0 |
Subclasses have to provide an implementation for this method, that is called by the base class when the EMLSR client gets channel access on the given link, on which an aux PHY that is TX capable is operating. | |
Ptr< EhtFrameExchangeManager > | GetEhtFem (uint8_t linkId) const |
MgtEmlOmn | GetEmlOmn () |
bool | GetExpectedAccessWithinDelay (uint8_t linkId, const Time &delay) const |
Get whether channel access is expected to be granted on the given link within the given delay to an Access Category that has traffic to send on the given link. | |
virtual uint8_t | GetLinkToSendEmlOmn ()=0 |
Ptr< StaWifiMac > | GetStaMac () const |
virtual std::optional< uint8_t > | ResendNotification (Ptr< const WifiMpdu > mpdu)=0 |
A previous EML Operating Mode Notification frame was dropped. | |
void | SetCcaEdThresholdOnLinkSwitch (Ptr< WifiPhy > phy, uint8_t linkId) |
Set the CCA ED threshold (if needed) on the given PHY that is switching channel to operate on the given link. | |
void | SetSleepStateForAllAuxPhys (bool sleep) |
Set sleep state or awake state for all aux PHYs. | |
void | SwitchAuxPhy (Ptr< WifiPhy > auxPhy, uint8_t currLinkId, uint8_t nextLinkId) |
Switch channel on the Aux PHY operating on the given current link so that it operates on the given next link. | |
void | SwitchMainPhy (uint8_t linkId, bool noSwitchDelay, bool resetBackoff, bool requestAccess, EmlsrMainPhySwitchTrace &&traceInfo) |
Switch channel on the Main PHY so that it operates on the given link. | |
virtual void | SwitchMainPhyIfTxopGainedByAuxPhy (uint8_t linkId, AcIndex aci)=0 |
Subclasses have to provide an implementation for this method, that is called by the base class when the given AC of the EMLSR client gets channel access on the given link, on which an aux PHY that is not TX capable is operating. | |
![]() | |
Object (const Object &o) | |
Copy an Object. | |
virtual void | DoInitialize () |
Initialize() implementation. | |
virtual void | NotifyNewAggregate () |
Notify all Objects aggregated to this one of a new Object being aggregated. | |
![]() | |
void | ConstructSelf (const AttributeConstructionList &attributes) |
Complete construction of ObjectBase; invoked by derived classes. | |
virtual void | NotifyConstructionCompleted () |
Notifier called once the ObjectBase is fully constructed. | |
Protected Attributes | |
WifiModulationClass | m_auxPhyMaxModClass |
max modulation class supported by aux PHYs | |
MHz_u | m_auxPhyMaxWidth |
max channel width supported by aux PHYs | |
bool | m_auxPhyToSleep |
whether Aux PHYs should be put into sleep mode while the Main PHY is carrying out a (DL or UL) TXOP | |
std::map< uint8_t, EventId > | m_auxPhyToSleepEvents |
PHY ID-indexed map of events scheduled to put an Aux PHY to sleep. | |
bool | m_auxPhyTxCapable |
whether Aux PHYs are capable of transmitting PPDUs | |
Time | m_emlsrPaddingDelay |
EMLSR Padding delay. | |
Time | m_emlsrTransitionDelay |
EMLSR Transition delay. | |
uint8_t | m_mainPhyId |
ID of main PHY (position in the vector of PHYs held by WifiNetDevice) | |
MainPhySwitchInfo | m_mainPhySwitchInfo |
main PHY switch info | |
std::map< uint8_t, Time > | m_startSleep |
PHY ID-indexed map of last time sleep mode started. | |
std::map< uint8_t, EventId > | m_ulMainPhySwitch |
link ID-indexed map of timers started when an aux PHY gains an UL TXOP and schedules a channel switch for the main PHY | |
bool | m_useNotifiedMacHdr |
whether to use the information about the MAC header of the MPDU being received (if notified by the PHY) | |
Static Protected Attributes | |
static constexpr bool | DONT_REQUEST_ACCESS |
do not request channel access when PHY switch ends | |
static constexpr bool | DONT_RESET_BACKOFF = false |
do not reset backoff on main PHY switch | |
static constexpr bool | REQUEST_ACCESS = true |
request channel access when PHY switch ends | |
static constexpr bool | RESET_BACKOFF = true |
reset backoff on main PHY switch | |
Private Types | |
typedef void(* | MainPhySwitchCallback) (const EmlsrMainPhySwitchTrace &info) |
TracedCallback signature for main PHY switch events. | |
using | MainPhySwitchTracedCallback = TracedCallback<const EmlsrMainPhySwitchTrace&> |
TracedCallback for main PHY switch events typedef. | |
Private Member Functions | |
void | ApplyMaxChannelWidthAndModClassOnAuxPhys () |
Adjust the operating channel of all the aux PHYs to meet the constraint on the maximum channel width supported by aux PHYs. | |
void | ChangeEmlsrMode () |
This method is called to make an EMLSR mode change effective after the transition delay has elapsed or a notification response has been received from the AP. | |
void | ComputeOperatingChannels () |
Compute the operating channels that the main PHY and the aux PHY(s) must switch to in order to operate on each of the setup links. | |
virtual void | DoNotifyIcfReceived (uint8_t linkId)=0 |
Notify the subclass of the reception of an initial Control frame on the given link. | |
virtual void | DoNotifyMgtFrameReceived (Ptr< const WifiMpdu > mpdu, uint8_t linkId)=0 |
Notify the subclass of the reception of a management frame addressed to us. | |
virtual void | DoNotifyTxopEnd (uint8_t linkId)=0 |
Notify the subclass of the end of a TXOP on the given link. | |
virtual void | DoNotifyUlTxopStart (uint8_t linkId)=0 |
Notify the subclass of the start of an UL TXOP on the given link. | |
void | MediumSyncDelayTimerExpired (uint8_t linkId) |
Take the appropriate actions when the MediumSyncDelay timer expires or is cancelled. | |
virtual void | NotifyEmlsrModeChanged ()=0 |
Notify subclass that EMLSR mode changed. | |
virtual void | NotifyMainPhySwitch (std::optional< uint8_t > currLinkId, uint8_t nextLinkId, Ptr< WifiPhy > auxPhy, Time duration)=0 |
Notify subclass that the main PHY is switching channel to operate on another link. | |
void | SendEmlOmn () |
Send an EML Operating Mode Notification frame. | |
void | SetMainPhyId (uint8_t mainPhyId) |
Set the ID of main PHY (position in the vector of PHYs held by WifiNetDevice). | |
void | StartMediumSyncDelayTimer (uint8_t linkId) |
Start the MediumSyncDelay timer and take the appropriate actions. | |
void | TxDropped (WifiMacDropReason reason, Ptr< const WifiMpdu > mpdu) |
Notify that the given MPDU has been discarded for the given reason. | |
void | TxOk (Ptr< const WifiMpdu > mpdu) |
Notify the acknowledgment of the given MPDU. | |
Private Attributes | |
std::map< uint8_t, WifiPhyOperatingChannel > | m_auxPhyChannels |
link ID-indexed map of operating channels for the aux PHYs | |
std::set< uint8_t > | m_emlsrLinks |
ID of the EMLSR links (empty if EMLSR mode is disabled) | |
std::optional< Time > | m_emlsrTransitionTimeout |
Transition timeout advertised by APs with EMLSR activated. | |
bool | m_inDeviceInterference |
whether in-device interference is such that a PHY cannot decode anything and cannot decrease the backoff counter when another PHY is transmitting | |
Time | m_lastAdvPaddingDelay |
last advertised padding delay | |
Time | m_lastAdvTransitionDelay |
last advertised transition delay | |
std::map< uint8_t, WifiPhyOperatingChannel > | m_mainPhyChannels |
link ID-indexed map of operating channels for the main PHY | |
MainPhySwitchTracedCallback | m_mainPhySwitchTrace |
main PHY switch trace source | |
std::map< uint8_t, MediumSyncDelayStatus > | m_mediumSyncDelayStatus |
the status of MediumSyncDelay timers (link ID-indexed) | |
Time | m_mediumSyncDuration |
duration of the MediumSyncDelay timer | |
std::optional< uint8_t > | m_msdMaxNTxops |
MediumSyncDelay max number of TXOPs. | |
int8_t | m_msdOfdmEdThreshold |
MediumSyncDelay OFDM ED threshold. | |
std::optional< std::set< uint8_t > > | m_nextEmlsrLinks |
ID of the links that will become the EMLSR links when the pending notification frame is acknowledged. | |
std::map< uint8_t, Time > | m_noPhySince |
link ID-indexed map of the time since no PHY is operating on the link | |
std::map< Ptr< WifiPhy >, dBm_u > | m_prevCcaEdThreshold |
the CCA sensitivity threshold to restore once the MediumSyncDelay timer expires or the PHY moves to a link on which the timer is not running | |
bool | m_resetCamState |
whether to reset the state of CAM when main PHY switches channel | |
Ptr< StaWifiMac > | m_staMac |
the MAC of the managed non-AP MLD | |
EventId | m_transitionTimeoutEvent |
Timer started after the successful transmission of an EML Operating Mode Notification frame. | |
Friends | |
class | ::EmlsrCcaBusyTest |
Allow test cases to access private members. | |
Additional Inherited Members | |
![]() | |
static TypeId | GetObjectIid () |
Ensure the TypeId for ObjectBase gets fully configured to anchor the inheritance tree properly. | |
EmlsrManager is an abstract base class defining the API that EHT non-AP MLDs with EMLSR activated can use to handle the operations on the EMLSR links.
Introspection did not find any typical Config paths.
HR-DSSS|ERP-OFDM|OFDM|HT|VHT|HE|EHT
ns3::Ptr<N3ns313UintegerValueE>
Time
+0ns:+256000ns Time
+0ns:+256000ns Group: Wifi
Size of this type is 712 bytes (on a 64-bit architecture).
Definition at line 79 of file emlsr-manager.h.
|
private |
TracedCallback signature for main PHY switch events.
info | the information associated with the main PHY switch event |
Definition at line 663 of file emlsr-manager.h.
|
private |
TracedCallback for main PHY switch events typedef.
Definition at line 666 of file emlsr-manager.h.
ns3::EmlsrManager::EmlsrManager | ( | ) |
Definition at line 145 of file emlsr-manager.cc.
References NS_LOG_FUNCTION.
|
override |
Definition at line 158 of file emlsr-manager.cc.
References NS_LOG_FUNCTION_NOARGS.
|
private |
Adjust the operating channel of all the aux PHYs to meet the constraint on the maximum channel width supported by aux PHYs.
Definition at line 1242 of file emlsr-manager.cc.
References NS_ASSERT, NS_LOG_DEBUG, NS_LOG_FUNCTION, and ns3::wifiAcList.
|
protected |
Cancel all pending events to put aux PHYs into sleep/awake state.
Definition at line 1357 of file emlsr-manager.cc.
References NS_LOG_FUNCTION.
void ns3::EmlsrManager::CancelMediumSyncDelayTimer | ( | uint8_t | linkId | ) |
Cancel the MediumSyncDelay timer associated with the given link and take the appropriate actions.
This function must not be called when the MediumSyncDelay timer is not running on the given link.
linkId | the ID of the link associated with the MediumSyncDelay timer to cancel |
Definition at line 981 of file emlsr-manager.cc.
References NS_ASSERT, and NS_LOG_FUNCTION.
|
private |
This method is called to make an EMLSR mode change effective after the transition delay has elapsed or a notification response has been received from the AP.
Definition at line 1217 of file emlsr-manager.cc.
References NS_ASSERT_MSG, and NS_LOG_FUNCTION.
std::pair< bool, Time > ns3::EmlsrManager::CheckPossiblyReceivingIcf | ( | uint8_t | linkId | ) | const |
Check whether a PPDU that may be an ICF is being received on the given link.
If so, return true along with the time to wait to know more information about the PPDU being received. Otherwise, return false.
linkId | the ID of the given link |
Definition at line 549 of file emlsr-manager.cc.
References ns3::EMLSR_RX_PHY_START_DELAY, GetEhtFem(), GetMainPhyId(), GetStaMac(), m_useNotifiedMacHdr, ns3::Simulator::Now(), NS_ASSERT, NS_ASSERT_MSG, NS_LOG_DEBUG, NS_LOG_FUNCTION, ns3::SU_STA_ID, ns3::Time::US, and ns3::WIFI_MOD_CLASS_HT.
Referenced by ns3::AdvancedEmlsrManager::DoGetDelayUntilAccessRequest(), ns3::DefaultEmlsrManager::SwitchAuxPhyAfterMainPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyBackDelayExpired().
|
private |
Compute the operating channels that the main PHY and the aux PHY(s) must switch to in order to operate on each of the setup links.
The operating channels may be different due to limited channel width capabilities of the aux PHY(s). This method shall be called upon completion of ML setup.
Definition at line 1294 of file emlsr-manager.cc.
References ns3::GetMaximumChannelWidth(), NS_ASSERT_MSG, NS_LOG_FUNCTION, and ns3::WIFI_STANDARD_UNSPECIFIED.
Referenced by NotifyMgtFrameReceived().
void ns3::EmlsrManager::DecrementMediumSyncDelayNTxops | ( | uint8_t | linkId | ) |
Decrement the counter indicating the number of TXOP attempts left while the MediumSyncDelay timer is running.
This function must not be called when the MediumSyncDelay timer is not running on the given link.
linkId | the ID of the link on which a new TXOP attempt may be carried out |
Definition at line 1024 of file emlsr-manager.cc.
References NS_ASSERT, and NS_LOG_FUNCTION.
|
overrideprotectedvirtual |
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.
Definition at line 164 of file emlsr-manager.cc.
References ns3::EventId::Cancel(), ns3::Object::DoDispose(), m_mediumSyncDelayStatus, m_staMac, m_transitionTimeoutEvent, ns3::MakeCallback(), NS_LOG_FUNCTION, TxDropped(), and TxOk().
|
protectedpure virtual |
Subclasses have to provide an implementation for this method, that is called by the base class when the EMLSR client gets channel access on the given link.
This method has to check possible reasons to give up the TXOP that apply to both main PHY and aux PHYs.
linkId | the ID of the given link |
Implemented in ns3::AdvancedEmlsrManager, and ns3::DefaultEmlsrManager.
Referenced by GetDelayUntilAccessRequest().
|
privatepure virtual |
Notify the subclass of the reception of an initial Control frame on the given link.
linkId | the ID of the link on which the initial Control frame was received |
Implemented in ns3::AdvancedEmlsrManager, and ns3::DefaultEmlsrManager.
Referenced by NotifyIcfReceived().
|
privatepure virtual |
Notify the subclass of the reception of a management frame addressed to us.
mpdu | the received MPDU |
linkId | the ID of the link over which the MPDU was received |
Implemented in ns3::DefaultEmlsrManager.
Referenced by NotifyMgtFrameReceived().
|
privatepure virtual |
Notify the subclass of the end of a TXOP on the given link.
linkId | the ID of the given link |
Implemented in ns3::AdvancedEmlsrManager, and ns3::DefaultEmlsrManager.
Referenced by NotifyTxopEnd().
|
privatepure virtual |
Notify the subclass of the start of an UL TXOP on the given link.
linkId | the ID of the given link |
Implemented in ns3::AdvancedEmlsrManager, and ns3::DefaultEmlsrManager.
Referenced by NotifyUlTxopStart().
|
protectedvirtual |
Allow subclasses to take actions when the MAC is set.
mac | the wifi MAC |
Reimplemented in ns3::AdvancedEmlsrManager.
Definition at line 201 of file emlsr-manager.cc.
References NS_LOG_FUNCTION.
Referenced by SetWifiMac().
|
protectedvirtual |
Callback connected to the EmlsrLinkSwitch trace source of StaWifiMac.
linkId | the ID of the link involved in the EMLSR link switch event |
phy | a pointer to the PHY involved in the EMLSR link switch event |
Definition at line 207 of file emlsr-manager.cc.
References m_noPhySince, MEDIUM_SYNC_THRESHOLD_USEC, ns3::MicroSeconds(), ns3::Simulator::Now(), NS_ASSERT, NS_ASSERT_MSG, NS_LOG_DEBUG, NS_LOG_FUNCTION, StartMediumSyncDelayTimer(), and ns3::Time::US.
Referenced by SetWifiMac().
bool ns3::EmlsrManager::GetAuxPhyTxCapable | ( | ) | const |
Definition at line 275 of file emlsr-manager.cc.
References m_auxPhyTxCapable.
Referenced by ns3::AdvancedEmlsrManager::DoDispose(), ns3::AdvancedEmlsrManager::DoSetWifiMac(), and GetTypeId().
bool ns3::EmlsrManager::GetCamStateReset | ( | ) | const |
Definition at line 263 of file emlsr-manager.cc.
References m_resetCamState.
Referenced by GetTypeId().
|
protected |
linkId | the ID of the given link |
Definition at line 1348 of file emlsr-manager.cc.
References NS_ASSERT_MSG.
Referenced by ns3::AdvancedEmlsrManager::RequestMainPhyToSwitch(), SwitchAuxPhy(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
|
protected |
linkId | the ID of the given link |
Definition at line 1339 of file emlsr-manager.cc.
References NS_ASSERT_MSG.
Referenced by ns3::AdvancedEmlsrManager::CheckNavAndCcaLastPifs(), ns3::AdvancedEmlsrManager::RequestMainPhyToSwitch(), SwitchMainPhy(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
|
protectedpure virtual |
Subclasses have to provide an implementation for this method, that is called by the base class when the EMLSR client gets channel access on the given link, on which an aux PHY that is TX capable is operating.
This method has to request the main PHY to switch to the given link to take over the TXOP, if possible, or determine the delay after which the EMLSR client restarts channel access on the given link, otherwise.
linkId | the ID of the given link |
Implemented in ns3::AdvancedEmlsrManager, and ns3::DefaultEmlsrManager.
Referenced by GetDelayUntilAccessRequest().
std::pair< bool, Time > ns3::EmlsrManager::GetDelayUntilAccessRequest | ( | uint8_t | linkId, |
AcIndex | aci ) |
Notify that an UL TXOP is gained on the given link by the given AC.
This method has to determine whether to start the UL TXOP or release the channel.
linkId | the ID of the given link |
aci | the index of the given AC |
Definition at line 513 of file emlsr-manager.cc.
References DoGetDelayUntilAccessRequest(), GetDelayUnlessMainPhyTakesOverUlTxop(), m_auxPhyTxCapable, m_mainPhyId, m_staMac, NS_ASSERT_MSG, NS_LOG_DEBUG, and SwitchMainPhyIfTxopGainedByAuxPhy().
|
protected |
linkId | the ID of the given link |
Definition at line 305 of file emlsr-manager.cc.
References m_staMac, and ns3::StaticCast().
Referenced by ns3::AdvancedEmlsrManager::CheckNavAndCcaLastPifs(), CheckPossiblyReceivingIcf(), ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), ns3::AdvancedEmlsrManager::ReceivedMacHdr(), ns3::AdvancedEmlsrManager::SwitchMainPhyBackDelayExpired(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
std::optional< Time > ns3::EmlsrManager::GetElapsedMediumSyncDelayTimer | ( | uint8_t | linkId | ) | const |
Check whether the MediumSyncDelay timer is running for the STA operating on the given link.
If so, returns the time elapsed since the timer started.
linkId | the ID of the given link |
Definition at line 311 of file emlsr-manager.cc.
References ns3::Simulator::GetDelayLeft(), m_mediumSyncDelayStatus, and m_mediumSyncDuration.
Referenced by ns3::AdvancedEmlsrManager::RequestMainPhyToSwitch().
|
protected |
Definition at line 1084 of file emlsr-manager.cc.
References ns3::MgtEmlOmn::EmlControl::emlsrMode, ns3::MgtEmlOmn::EmlControl::emlsrParamUpdateCtrl, ns3::MgtEmlOmn::m_emlControl, ns3::MgtEmlOmn::m_emlsrParamUpdate, NS_LOG_DEBUG, and ns3::MgtEmlOmn::SetLinkIdInBitmap().
const std::set< uint8_t > & ns3::EmlsrManager::GetEmlsrLinks | ( | ) | const |
Definition at line 293 of file emlsr-manager.cc.
References m_emlsrLinks.
Referenced by ns3::AdvancedEmlsrManager::NotifyEmlsrModeChanged().
|
protected |
Get whether channel access is expected to be granted on the given link within the given delay to an Access Category that has traffic to send on the given link.
linkId | the ID of the given link |
delay | the given delay |
Definition at line 1062 of file emlsr-manager.cc.
References NS_LOG_DEBUG, and ns3::wifiAcList.
Referenced by ns3::AdvancedEmlsrManager::CheckNavAndCcaLastPifs(), ns3::AdvancedEmlsrManager::InterruptSwitchMainPhyBackTimerIfNeeded(), ns3::AdvancedEmlsrManager::ReceivedMacHdr(), ns3::AdvancedEmlsrManager::SwitchMainPhyBackDelayExpired(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
bool ns3::EmlsrManager::GetInDeviceInterference | ( | ) | const |
Definition at line 287 of file emlsr-manager.cc.
References m_inDeviceInterference.
Referenced by GetTypeId().
|
protectedpure virtual |
Implemented in ns3::DefaultEmlsrManager.
uint8_t ns3::EmlsrManager::GetMainPhyId | ( | ) | const |
Definition at line 251 of file emlsr-manager.cc.
References m_mainPhyId.
Referenced by ns3::AdvancedEmlsrManager::CheckNavAndCcaLastPifs(), CheckPossiblyReceivingIcf(), ns3::AdvancedEmlsrManager::DoDispose(), ns3::AdvancedEmlsrManager::DoGetDelayUntilAccessRequest(), ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), ns3::AdvancedEmlsrManager::DoSetWifiMac(), GetTypeId(), ns3::AdvancedEmlsrManager::InterruptSwitchMainPhyBackTimerIfNeeded(), ns3::DefaultEmlsrManager::NotifyMainPhySwitch(), ns3::AdvancedEmlsrManager::ReceivedMacHdr(), and ns3::DefaultEmlsrManager::SwitchMainPhyBackToPreferredLink().
Time ns3::EmlsrManager::GetMediumSyncDuration | ( | ) | const |
Definition at line 342 of file emlsr-manager.cc.
References m_mediumSyncDuration.
Referenced by ns3::AdvancedEmlsrManager::RequestMainPhyToSwitch().
std::optional< uint8_t > ns3::EmlsrManager::GetMediumSyncMaxNTxops | ( | ) | const |
Definition at line 368 of file emlsr-manager.cc.
References m_msdMaxNTxops.
int8_t ns3::EmlsrManager::GetMediumSyncOfdmEdThreshold | ( | ) | const |
Definition at line 355 of file emlsr-manager.cc.
References m_msdOfdmEdThreshold.
|
protected |
Definition at line 299 of file emlsr-manager.cc.
References m_staMac.
Referenced by ns3::AdvancedEmlsrManager::CheckNavAndCcaLastPifs(), CheckPossiblyReceivingIcf(), ns3::AdvancedEmlsrManager::DoDispose(), ns3::AdvancedEmlsrManager::DoGetDelayUntilAccessRequest(), ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), ns3::DefaultEmlsrManager::DoNotifyTxopEnd(), ns3::AdvancedEmlsrManager::DoSetWifiMac(), ns3::AdvancedEmlsrManager::GetDelayUnlessMainPhyTakesOverUlTxop(), ns3::DefaultEmlsrManager::GetLinkToSendEmlOmn(), ns3::AdvancedEmlsrManager::InterruptSwitchMainPhyBackTimerIfNeeded(), ns3::AdvancedEmlsrManager::NotifyEmlsrModeChanged(), NotifyIcfReceived(), ns3::DefaultEmlsrManager::NotifyMainPhySwitch(), NotifyMgtFrameReceived(), ns3::AdvancedEmlsrManager::ReceivedMacHdr(), ns3::AdvancedEmlsrManager::RequestMainPhyToSwitch(), ns3::DefaultEmlsrManager::ResendNotification(), SetEmlsrLinks(), SwitchAuxPhy(), ns3::DefaultEmlsrManager::SwitchAuxPhyAfterMainPhy(), SwitchMainPhy(), ns3::AdvancedEmlsrManager::SwitchMainPhyBackDelayExpired(), ns3::DefaultEmlsrManager::SwitchMainPhyBackToPreferredLink(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
std::optional< Time > ns3::EmlsrManager::GetTransitionTimeout | ( | ) | const |
Definition at line 329 of file emlsr-manager.cc.
References m_emlsrTransitionTimeout.
Referenced by NotifyMgtFrameReceived(), and SetEmlsrLinks().
|
static |
Get the type ID.
Definition at line 34 of file emlsr-manager.cc.
References ns3::TypeId::ATTR_CONSTRUCT, ns3::TypeId::ATTR_GET, GetAuxPhyTxCapable(), GetCamStateReset(), GetInDeviceInterference(), GetMainPhyId(), m_auxPhyMaxModClass, m_auxPhyMaxWidth, m_auxPhyToSleep, m_emlsrPaddingDelay, m_emlsrTransitionDelay, m_mainPhySwitchTrace, m_useNotifiedMacHdr, ns3::MakeAttributeContainerAccessor(), ns3::MakeAttributeContainerChecker(), ns3::MakeBooleanAccessor(), ns3::MakeBooleanChecker(), ns3::MakeEnumAccessor(), ns3::MakeEnumChecker(), ns3::MakeTimeAccessor(), ns3::MakeTimeChecker(), ns3::MakeTraceSourceAccessor(), ns3::MakeUintegerAccessor(), ns3::MakeUintegerChecker(), ns3::MicroSeconds(), SetAuxPhyTxCapable(), SetCamStateReset(), SetEmlsrLinks(), SetInDeviceInterference(), SetMainPhyId(), ns3::TypeId::SetParent(), ns3::WIFI_MOD_CLASS_EHT, ns3::WIFI_MOD_CLASS_ERP_OFDM, ns3::WIFI_MOD_CLASS_HE, ns3::WIFI_MOD_CLASS_HR_DSSS, ns3::WIFI_MOD_CLASS_HT, ns3::WIFI_MOD_CLASS_OFDM, and ns3::WIFI_MOD_CLASS_VHT.
bool ns3::EmlsrManager::MediumSyncDelayNTxopsExceeded | ( | uint8_t | linkId | ) |
Return whether no more TXOP attempt is allowed on the given link.
This function must not be called when the MediumSyncDelay timer is not running on the given link.
linkId | the ID of the link on which a new TXOP attempt may be carried out |
Definition at line 1051 of file emlsr-manager.cc.
References NS_ASSERT, and NS_LOG_FUNCTION.
Referenced by ns3::AdvancedEmlsrManager::RequestMainPhyToSwitch().
|
private |
Take the appropriate actions when the MediumSyncDelay timer expires or is cancelled.
linkId | the ID of the link associated with the MediumSyncDelay timer to cancel |
Definition at line 994 of file emlsr-manager.cc.
References NS_ASSERT, NS_ASSERT_MSG, NS_LOG_DEBUG, and NS_LOG_FUNCTION.
|
privatepure virtual |
Notify subclass that EMLSR mode changed.
Implemented in ns3::AdvancedEmlsrManager, and ns3::DefaultEmlsrManager.
void ns3::EmlsrManager::NotifyIcfReceived | ( | uint8_t | linkId | ) |
Notify the reception of an initial Control frame on the given link.
linkId | the ID of the link on which the initial Control frame was received |
Definition at line 437 of file emlsr-manager.cc.
References DoNotifyIcfReceived(), DONT_REQUEST_ACCESS, GetStaMac(), m_auxPhyToSleep, m_mainPhyId, m_mainPhySwitchInfo, m_staMac, ns3::Simulator::Now(), NS_ASSERT, NS_LOG_FUNCTION, RESET_BACKOFF, SetSleepStateForAllAuxPhys(), ns3::SWITCHING, SwitchMainPhy(), ns3::EmlsrManager::MainPhySwitchInfo::to, and ns3::USING_OTHER_EMLSR_LINK.
|
virtual |
Notify that an STA affiliated with the EMLSR client is causing in-device interference for the given amount of time.
linkId | the ID of the link on which the STA is operating |
duration | the duration of the in-device interference |
Definition at line 748 of file emlsr-manager.cc.
References ns3::Time::As(), m_inDeviceInterference, m_staMac, MEDIUM_SYNC_THRESHOLD_USEC, ns3::MicroSeconds(), NS_ASSERT, NS_LOG_FUNCTION, ns3::Simulator::Schedule(), StartMediumSyncDelayTimer(), and ns3::Time::US.
|
privatepure virtual |
Notify subclass that the main PHY is switching channel to operate on another link.
currLinkId | the ID of the link on which the main PHY is operating (if any) |
nextLinkId | the ID of the link on which the main PHY will be operating |
auxPhy | the aux PHY operating on the link on which the main PHY will be operating |
duration | the channel switch duration |
Implemented in ns3::DefaultEmlsrManager.
Referenced by SwitchMainPhy().
Notify the reception of a management frame addressed to us.
mpdu | the received MPDU |
linkId | the ID of the link over which the MPDU was received |
Definition at line 397 of file emlsr-manager.cc.
References ns3::EventId::Cancel(), ComputeOperatingChannels(), DoNotifyMgtFrameReceived(), GetStaMac(), GetTransitionTimeout(), ns3::EventImpl::Invoke(), ns3::EventId::IsPending(), m_nextEmlsrLinks, m_staMac, m_transitionTimeoutEvent, NS_LOG_FUNCTION, ns3::WifiActionHeader::Peek(), ns3::EventId::PeekEventImpl(), ns3::WifiActionHeader::PROTECTED_EHT, ns3::WifiActionHeader::PROTECTED_EHT_EML_OPERATING_MODE_NOTIFICATION, and SendEmlOmn().
void ns3::EmlsrManager::NotifyProtectionCompleted | ( | uint8_t | linkId | ) |
Notify that protection (if required) is completed and data frame exchange can start on the given link.
linkId | the ID of the given link |
Definition at line 662 of file emlsr-manager.cc.
References m_auxPhyToSleep, m_mainPhyId, m_staMac, NS_LOG_FUNCTION, ns3::Simulator::Schedule(), and SetSleepStateForAllAuxPhys().
|
virtual |
Notify that RTS transmission is starting on the given link.
linkId | the ID of the given link |
rts | the RTS being transmitted |
txVector | the TXVECTOR used to transmit the RTS |
Reimplemented in ns3::DefaultEmlsrManager.
Definition at line 656 of file emlsr-manager.cc.
References NS_LOG_FUNCTION.
void ns3::EmlsrManager::NotifyTxopEnd | ( | uint8_t | linkId, |
bool | ulTxopNotStarted = false, | ||
bool | ongoingDlTxop = false ) |
Notify the end of a TXOP on the given link.
linkId | the ID of the given link |
ulTxopNotStarted | whether this is a notification of the end of an UL TXOP that did not even start (no frame transmitted) |
ongoingDlTxop | whether a DL TXOP is ongoing on the given link (if true, this is a notification of the end of an UL TXOP) |
Definition at line 686 of file emlsr-manager.cc.
References DoNotifyTxopEnd(), m_auxPhyToSleep, m_staMac, m_ulMainPhySwitch, NS_LOG_DEBUG, NS_LOG_FUNCTION, SetSleepStateForAllAuxPhys(), and ns3::USING_OTHER_EMLSR_LINK.
Referenced by ns3::AdvancedEmlsrManager::ReceivedMacHdr().
void ns3::EmlsrManager::NotifyUlTxopStart | ( | uint8_t | linkId | ) |
Notify the start of an UL TXOP on the given link.
linkId | the ID of the given link |
Definition at line 633 of file emlsr-manager.cc.
References DoNotifyUlTxopStart(), m_staMac, NS_LOG_DEBUG, NS_LOG_FUNCTION, and ns3::USING_OTHER_EMLSR_LINK.
Referenced by ns3::AdvancedEmlsrManager::CheckNavAndCcaLastPifs().
|
protectedpure virtual |
A previous EML Operating Mode Notification frame was dropped.
Ask the subclass whether the frame needs to be re-sent on the given link (if any).
mpdu | the dropped MPDU that includes the EML Operating Mode Notification frame |
Implemented in ns3::DefaultEmlsrManager.
void ns3::EmlsrManager::ResetMediumSyncDelayNTxops | ( | uint8_t | linkId | ) |
Reset the counter indicating the number of TXOP attempts left while the MediumSyncDelay timer is running, so as to remove the limit on the number of attempts that can be made while the MediumSyncDelay timer is running.
This function is normally called when a TXOP attempt is successful. This function must not be called when the MediumSyncDelay timer is not running on the given link.
linkId | the ID of the link for which the counter of the TXOP attempts is reset |
Definition at line 1040 of file emlsr-manager.cc.
References NS_ASSERT, and NS_LOG_FUNCTION.
|
private |
Send an EML Operating Mode Notification frame.
Definition at line 1127 of file emlsr-manager.cc.
References NS_ABORT_MSG_IF, NS_ASSERT_MSG, and NS_LOG_FUNCTION.
Referenced by NotifyMgtFrameReceived(), and SetEmlsrLinks().
void ns3::EmlsrManager::SetAuxPhyTxCapable | ( | bool | capable | ) |
Set the member variable indicating whether Aux PHYs are capable of transmitting PPDUs.
capable | whether Aux PHYs are capable of transmitting PPDUs |
Definition at line 269 of file emlsr-manager.cc.
References m_auxPhyTxCapable.
Referenced by GetTypeId().
void ns3::EmlsrManager::SetCamStateReset | ( | bool | enable | ) |
Set the member variable indicating whether the state of the CAM should be reset when the main PHY switches channel and operates on the link associated with the CAM.
enable | whether the CAM state should be reset |
Definition at line 257 of file emlsr-manager.cc.
References m_resetCamState.
Referenced by GetTypeId().
|
protected |
Set the CCA ED threshold (if needed) on the given PHY that is switching channel to operate on the given link.
phy | the given PHY |
linkId | the ID of the given link |
Definition at line 771 of file emlsr-manager.cc.
References m_mediumSyncDelayStatus, m_msdOfdmEdThreshold, m_prevCcaEdThreshold, NS_LOG_DEBUG, and NS_LOG_FUNCTION.
Referenced by ns3::DefaultEmlsrManager::NotifyMainPhySwitch(), and SwitchMainPhy().
void ns3::EmlsrManager::SetEmlsrLinks | ( | const std::set< uint8_t > & | linkIds | ) |
Take actions to enable EMLSR mode on the given set of links, if non-empty, or disable EMLSR mode, otherwise.
linkIds | the IDs of the links on which EMLSR mode should be enabled (empty to disable EMLSR mode) |
Definition at line 374 of file emlsr-manager.cc.
References GetStaMac(), GetTransitionTimeout(), ns3::LOG_FUNCTION, m_emlsrLinks, m_nextEmlsrLinks, NS_ABORT_MSG_IF, NS_LOG_FUNCTION, and SendEmlOmn().
Referenced by GetTypeId().
void ns3::EmlsrManager::SetInDeviceInterference | ( | bool | enable | ) |
Set the member variable indicating whether in-device interference is such that a PHY cannot decode anything and cannot decrease the backoff counter when another PHY is transmitting.
enable | whether in-device interference is such that a PHY cannot decode anything and cannot decrease the backoff counter when another PHY is transmitting |
Definition at line 281 of file emlsr-manager.cc.
References m_inDeviceInterference.
Referenced by GetTypeId().
|
private |
Set the ID of main PHY (position in the vector of PHYs held by WifiNetDevice).
This method cannot be called during or after initialization.
mainPhyId | the ID of the main PHY |
Definition at line 243 of file emlsr-manager.cc.
References ns3::Object::IsInitialized(), m_mainPhyId, NS_ABORT_MSG_IF, and NS_LOG_FUNCTION.
Referenced by GetTypeId().
void ns3::EmlsrManager::SetMediumSyncDuration | ( | Time | duration | ) |
Set the duration of the MediumSyncDelay timer.
duration | the duration of the MediumSyncDelay timer |
Definition at line 335 of file emlsr-manager.cc.
References ns3::Time::As(), m_mediumSyncDuration, NS_LOG_FUNCTION, and ns3::Time::US.
void ns3::EmlsrManager::SetMediumSyncMaxNTxops | ( | std::optional< uint8_t > | nTxops | ) |
Set the maximum number of TXOPs a non-AP STA is allowed to attempt to initiate while the MediumSyncDelay timer is running.
No value indicates no limit.
nTxops | the maximum number of TXOPs a non-AP STA is allowed to attempt to initiate while the MediumSyncDelay timer is running |
Definition at line 361 of file emlsr-manager.cc.
References m_msdMaxNTxops, and NS_LOG_FUNCTION.
void ns3::EmlsrManager::SetMediumSyncOfdmEdThreshold | ( | int8_t | threshold | ) |
Set the Medium Synchronization OFDM ED threshold (dBm) to use while the MediumSyncDelay timer is running.
threshold | the threshold in dBm (ranges from -72 to -62 dBm) |
Definition at line 348 of file emlsr-manager.cc.
References m_msdOfdmEdThreshold, and NS_LOG_FUNCTION.
|
protected |
Set sleep state or awake state for all aux PHYs.
sleep | set sleep state, if true, or awake state, otherwise |
Definition at line 1369 of file emlsr-manager.cc.
References ns3::MicroSeconds(), NS_ASSERT_MSG, NS_LOG_DEBUG, and NS_LOG_FUNCTION.
Referenced by NotifyIcfReceived(), NotifyProtectionCompleted(), and NotifyTxopEnd().
void ns3::EmlsrManager::SetTransitionTimeout | ( | Time | timeout | ) |
Set the Transition Timeout advertised by the associated AP with EMLSR activated.
timeout | the advertised Transition Timeout |
Definition at line 322 of file emlsr-manager.cc.
References ns3::Time::As(), m_emlsrTransitionTimeout, NS_LOG_FUNCTION, timeout, and ns3::Time::US.
void ns3::EmlsrManager::SetWifiMac | ( | Ptr< StaWifiMac > | mac | ) |
Set the wifi MAC.
Note that it must be the MAC of an EHT non-AP MLD.
mac | the wifi MAC |
Definition at line 180 of file emlsr-manager.cc.
References DoSetWifiMac(), EmlsrLinkSwitchCallback(), m_staMac, ns3::MakeCallback(), NS_ABORT_MSG_IF, NS_ASSERT, NS_LOG_FUNCTION, ns3::STA, TxDropped(), and TxOk().
|
private |
Start the MediumSyncDelay timer and take the appropriate actions.
linkId | the ID of the link on which medium synchronization was lost |
Definition at line 938 of file emlsr-manager.cc.
References NS_LOG_DEBUG, and NS_LOG_FUNCTION.
Referenced by EmlsrLinkSwitchCallback(), and NotifyInDeviceInterferenceStart().
|
protected |
Switch channel on the Aux PHY operating on the given current link so that it operates on the given next link.
auxPhy | the Aux PHY |
currLinkId | the ID of the link on which the aux PHY is currently operating |
nextLinkId | the ID of the link on which the aux PHY will be operating |
Definition at line 903 of file emlsr-manager.cc.
References GetChannelForAuxPhy(), GetStaMac(), m_staMac, ns3::MicroSeconds(), NS_LOG_DEBUG, NS_LOG_FUNCTION, and ns3::Simulator::Schedule().
Referenced by ns3::DefaultEmlsrManager::SwitchAuxPhyAfterMainPhy().
|
protected |
Switch channel on the Main PHY so that it operates on the given link.
linkId | the ID of the link on which the main PHY has to operate |
noSwitchDelay | whether switching delay should be zero |
resetBackoff | whether backoff should be reset on the link on which the main PHY is operating |
requestAccess | whether channel access should be requested on the link on which the main PHY is moving onto |
traceInfo | information to pass to the main PHY switch traced callback (the fromLinkId and toLinkId fields are set by this function) |
Definition at line 800 of file emlsr-manager.cc.
References ns3::Time::As(), ns3::Txop::CHECK_MEDIUM_BUSY, ns3::Txop::DIDNT_HAVE_FRAMES_TO_TRANSMIT, ns3::EmlsrManager::MainPhySwitchInfo::end, ns3::EmlsrManager::MainPhySwitchInfo::from, GetChannelForMainPhy(), GetStaMac(), m_lastAdvTransitionDelay, m_mainPhyId, m_mainPhySwitchInfo, m_mainPhySwitchTrace, m_staMac, ns3::MicroSeconds(), NotifyMainPhySwitch(), ns3::Simulator::Now(), NS_ASSERT_MSG, NS_LOG_DEBUG, NS_LOG_FUNCTION, ns3::Simulator::Schedule(), ns3::Seconds(), SetCcaEdThresholdOnLinkSwitch(), ns3::EmlsrManager::MainPhySwitchInfo::to, ns3::Time::US, and ns3::wifiAcList.
Referenced by ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), NotifyIcfReceived(), ns3::DefaultEmlsrManager::SwitchMainPhyBackToPreferredLink(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
|
protectedpure virtual |
Subclasses have to provide an implementation for this method, that is called by the base class when the given AC of the EMLSR client gets channel access on the given link, on which an aux PHY that is not TX capable is operating.
This method has to request the main PHY to switch to the given link to take over the TXOP, unless it is decided to give up the TXOP.
linkId | the ID of the given link |
aci | the index of the given AC |
Implemented in ns3::AdvancedEmlsrManager, and ns3::DefaultEmlsrManager.
Referenced by GetDelayUntilAccessRequest().
|
private |
Notify that the given MPDU has been discarded for the given reason.
reason | the reason why the MPDU was dropped |
mpdu | the dropped MPDU |
Definition at line 1185 of file emlsr-manager.cc.
References NS_LOG_FUNCTION.
Referenced by DoDispose(), and SetWifiMac().
Notify the acknowledgment of the given MPDU.
mpdu | the acknowledged MPDU |
Definition at line 1150 of file emlsr-manager.cc.
References NS_ASSERT_MSG, and NS_LOG_FUNCTION.
Referenced by DoDispose(), and SetWifiMac().
|
friend |
Allow test cases to access private members.
Definition at line 82 of file emlsr-manager.h.
|
staticconstexprprotected |
do not request channel access when PHY switch ends
Definition at line 417 of file emlsr-manager.h.
Referenced by NotifyIcfReceived(), EmlsrCcaBusyTest::StartTraffic(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
|
staticconstexprprotected |
do not reset backoff on main PHY switch
Definition at line 415 of file emlsr-manager.h.
Referenced by ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), EmlsrCcaBusyTest::StartTraffic(), and ns3::DefaultEmlsrManager::SwitchMainPhyBackToPreferredLink().
|
private |
link ID-indexed map of operating channels for the aux PHYs
Definition at line 699 of file emlsr-manager.h.
|
protected |
max modulation class supported by aux PHYs
Definition at line 524 of file emlsr-manager.h.
Referenced by GetTypeId().
|
protected |
max channel width supported by aux PHYs
Definition at line 523 of file emlsr-manager.h.
Referenced by GetTypeId().
|
protected |
whether Aux PHYs should be put into sleep mode while the Main PHY is carrying out a (DL or UL) TXOP
Definition at line 526 of file emlsr-manager.h.
Referenced by GetTypeId(), NotifyIcfReceived(), NotifyProtectionCompleted(), and NotifyTxopEnd().
|
protected |
PHY ID-indexed map of events scheduled to put an Aux PHY to sleep.
Definition at line 530 of file emlsr-manager.h.
|
protected |
whether Aux PHYs are capable of transmitting PPDUs
Definition at line 525 of file emlsr-manager.h.
Referenced by ns3::AdvancedEmlsrManager::DoGetDelayUntilAccessRequest(), GetAuxPhyTxCapable(), GetDelayUntilAccessRequest(), SetAuxPhyTxCapable(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
|
private |
ID of the EMLSR links (empty if EMLSR mode is disabled)
Definition at line 684 of file emlsr-manager.h.
Referenced by GetEmlsrLinks(), and SetEmlsrLinks().
|
protected |
|
protected |
|
private |
Transition timeout advertised by APs with EMLSR activated.
Definition at line 671 of file emlsr-manager.h.
Referenced by GetTransitionTimeout(), and SetTransitionTimeout().
|
private |
whether in-device interference is such that a PHY cannot decode anything and cannot decrease the backoff counter when another PHY is transmitting
Definition at line 693 of file emlsr-manager.h.
Referenced by GetInDeviceInterference(), NotifyInDeviceInterferenceStart(), and SetInDeviceInterference().
|
private |
last advertised padding delay
Definition at line 688 of file emlsr-manager.h.
|
private |
last advertised transition delay
Definition at line 689 of file emlsr-manager.h.
Referenced by SwitchMainPhy().
|
private |
link ID-indexed map of operating channels for the main PHY
Definition at line 697 of file emlsr-manager.h.
|
protected |
ID of main PHY (position in the vector of PHYs held by WifiNetDevice)
Definition at line 522 of file emlsr-manager.h.
Referenced by ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), ns3::DefaultEmlsrManager::DoNotifyTxopEnd(), ns3::AdvancedEmlsrManager::GetDelayUnlessMainPhyTakesOverUlTxop(), GetDelayUntilAccessRequest(), ns3::DefaultEmlsrManager::GetLinkToSendEmlOmn(), GetMainPhyId(), NotifyIcfReceived(), NotifyProtectionCompleted(), ns3::AdvancedEmlsrManager::RequestMainPhyToSwitch(), ns3::DefaultEmlsrManager::ResendNotification(), SetMainPhyId(), SwitchMainPhy(), ns3::DefaultEmlsrManager::SwitchMainPhyBackToPreferredLink(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().
|
protected |
main PHY switch info
Definition at line 536 of file emlsr-manager.h.
Referenced by ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), NotifyIcfReceived(), ns3::DefaultEmlsrManager::NotifyMainPhySwitch(), SwitchMainPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy().
|
private |
main PHY switch trace source
Definition at line 668 of file emlsr-manager.h.
Referenced by GetTypeId(), and SwitchMainPhy().
|
private |
the status of MediumSyncDelay timers (link ID-indexed)
Definition at line 678 of file emlsr-manager.h.
Referenced by DoDispose(), GetElapsedMediumSyncDelayTimer(), and SetCcaEdThresholdOnLinkSwitch().
|
private |
duration of the MediumSyncDelay timer
Definition at line 673 of file emlsr-manager.h.
Referenced by GetElapsedMediumSyncDelayTimer(), GetMediumSyncDuration(), and SetMediumSyncDuration().
|
private |
MediumSyncDelay max number of TXOPs.
Definition at line 675 of file emlsr-manager.h.
Referenced by GetMediumSyncMaxNTxops(), and SetMediumSyncMaxNTxops().
|
private |
MediumSyncDelay OFDM ED threshold.
Definition at line 674 of file emlsr-manager.h.
Referenced by GetMediumSyncOfdmEdThreshold(), SetCcaEdThresholdOnLinkSwitch(), and SetMediumSyncOfdmEdThreshold().
|
private |
ID of the links that will become the EMLSR links when the pending notification frame is acknowledged.
Definition at line 685 of file emlsr-manager.h.
Referenced by NotifyMgtFrameReceived(), and SetEmlsrLinks().
|
private |
link ID-indexed map of the time since no PHY is operating on the link
Definition at line 701 of file emlsr-manager.h.
Referenced by EmlsrLinkSwitchCallback().
the CCA sensitivity threshold to restore once the MediumSyncDelay timer expires or the PHY moves to a link on which the timer is not running
Definition at line 679 of file emlsr-manager.h.
Referenced by SetCcaEdThresholdOnLinkSwitch().
|
private |
whether to reset the state of CAM when main PHY switches channel
Definition at line 692 of file emlsr-manager.h.
Referenced by GetCamStateReset(), and SetCamStateReset().
|
private |
the MAC of the managed non-AP MLD
Definition at line 670 of file emlsr-manager.h.
Referenced by DoDispose(), GetDelayUntilAccessRequest(), GetEhtFem(), GetStaMac(), NotifyIcfReceived(), NotifyInDeviceInterferenceStart(), NotifyMgtFrameReceived(), NotifyProtectionCompleted(), NotifyTxopEnd(), NotifyUlTxopStart(), SetWifiMac(), SwitchAuxPhy(), and SwitchMainPhy().
|
protected |
PHY ID-indexed map of last time sleep mode started.
Definition at line 532 of file emlsr-manager.h.
|
private |
Timer started after the successful transmission of an EML Operating Mode Notification frame.
Definition at line 690 of file emlsr-manager.h.
Referenced by DoDispose(), and NotifyMgtFrameReceived().
|
protected |
link ID-indexed map of timers started when an aux PHY gains an UL TXOP and schedules a channel switch for the main PHY
Definition at line 533 of file emlsr-manager.h.
Referenced by NotifyTxopEnd().
|
protected |
whether to use the information about the MAC header of the MPDU being received (if notified by the PHY)
Definition at line 528 of file emlsr-manager.h.
Referenced by CheckPossiblyReceivingIcf(), GetTypeId(), and ns3::AdvancedEmlsrManager::ReceivedMacHdr().
|
staticconstexpr |
The aMediumSyncThreshold defined by Sec. 35.3.16.18.1 of 802.11be D4.0.
Definition at line 86 of file emlsr-manager.h.
Referenced by EmlsrLinkSwitchTest::CheckRtsFrame(), EmlsrLinkSwitchCallback(), NotifyInDeviceInterferenceStart(), and EmlsrOperationsTestBase::Transmit().
|
staticconstexprprotected |
request channel access when PHY switch ends
Definition at line 416 of file emlsr-manager.h.
Referenced by ns3::AdvancedEmlsrManager::DoNotifyTxopEnd(), and ns3::DefaultEmlsrManager::SwitchMainPhyBackToPreferredLink().
|
staticconstexprprotected |
reset backoff on main PHY switch
Definition at line 414 of file emlsr-manager.h.
Referenced by NotifyIcfReceived(), ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopGainedByAuxPhy(), and ns3::AdvancedEmlsrManager::SwitchMainPhyIfTxopToBeGainedByAuxPhy().