A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
emlsr-manager.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2023 Universita' degli Studi di Napoli Federico II
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation;
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program; if not, write to the Free Software
15 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16 *
17 * Author: Stefano Avallone <stavallo@unina.it>
18 */
19
20#ifndef EMLSR_MANAGER_H
21#define EMLSR_MANAGER_H
22
23#include "ns3/ctrl-headers.h"
24#include "ns3/mac48-address.h"
25#include "ns3/object.h"
26#include "ns3/sta-wifi-mac.h"
27#include "ns3/wifi-phy-operating-channel.h"
28
29#include <map>
30#include <optional>
31#include <set>
32
33namespace ns3
34{
35
36class EhtFrameExchangeManager;
37class MgtEmlOmn;
38class WifiMpdu;
39
40/**
41 * \ingroup wifi
42 *
43 * EmlsrManager is an abstract base class defining the API that EHT non-AP MLDs
44 * with EMLSR activated can use to handle the operations on the EMLSR links
45 */
46class EmlsrManager : public Object
47{
48 public:
49 /**
50 * \brief Get the type ID.
51 * \return the object TypeId
52 */
53 static TypeId GetTypeId();
55 ~EmlsrManager() override;
56
57 /**
58 * Set the wifi MAC. Note that it must be the MAC of an EHT non-AP MLD.
59 *
60 * \param mac the wifi MAC
61 */
63
64 /**
65 * Set the Transition Timeout advertised by the associated AP with EMLSR activated.
66 *
67 * \param timeout the advertised Transition Timeout
68 */
70
71 /**
72 * \return the Transition Timeout, if advertised by the associated AP
73 */
74 std::optional<Time> GetTransitionTimeout() const;
75
76 /**
77 * Set the duration of the MediumSyncDelay timer.
78 *
79 * \param duration the duration of the MediumSyncDelay timer
80 */
81 void SetMediumSyncDuration(Time duration);
82
83 /**
84 * \return the duration of the MediumSyncDelay timer
85 */
87
88 /**
89 * Set the Medium Synchronization OFDM ED threshold (dBm) to use while the MediumSyncDelay
90 * timer is running.
91 *
92 * \param threshold the threshold in dBm (ranges from -72 to -62 dBm)
93 */
95
96 /**
97 * \return the Medium Synchronization OFDM ED threshold (dBm) to use while the MediumSyncDelay
98 * timer is running.
99 */
101
102 /**
103 * Set the maximum number of TXOPs a non-AP STA is allowed to attempt to initiate while
104 * the MediumSyncDelay timer is running. No value indicates no limit.
105 *
106 * \param nTxops the maximum number of TXOPs a non-AP STA is allowed to attempt to
107 * initiate while the MediumSyncDelay timer is running
108 */
109 void SetMediumSyncMaxNTxops(std::optional<uint8_t> nTxops);
110
111 /**
112 * \return the maximum number of TXOPs a non-AP STA is allowed to attempt to initiate while
113 * the MediumSyncDelay timer is running. No value indicates no limit.
114 */
115 std::optional<uint8_t> GetMediumSyncMaxNTxops() const;
116
117 /**
118 * \return the ID of main PHY (position in the vector of PHYs held by WifiNetDevice)
119 */
120 uint8_t GetMainPhyId() const;
121
122 /**
123 * Take actions to enable EMLSR mode on the given set of links, if non-empty, or
124 * disable EMLSR mode, otherwise.
125 *
126 * \param linkIds the IDs of the links on which EMLSR mode should be enabled
127 * (empty to disable EMLSR mode)
128 */
129 void SetEmlsrLinks(const std::set<uint8_t>& linkIds);
130
131 /**
132 * \return the set of links on which EMLSR mode is enabled
133 */
134 const std::set<uint8_t>& GetEmlsrLinks() const;
135
136 /**
137 * Set the member variable indicating whether the state of the CAM should be reset when
138 * the main PHY switches channel and operates on the link associated with the CAM.
139 *
140 * \param enable whether the CAM state should be reset
141 */
142 void SetCamStateReset(bool enable);
143
144 /**
145 * \return the value of the member variable indicating whether the state of the CAM should be
146 * reset when the main PHY switches channel and operates on the link associated with the CAM.
147 */
148 bool GetCamStateReset() const;
149
150 /**
151 * Set the member variable indicating whether Aux PHYs are capable of transmitting PPDUs.
152 *
153 * \param capable whether Aux PHYs are capable of transmitting PPDUs
154 */
155 void SetAuxPhyTxCapable(bool capable);
156
157 /**
158 * \return whether Aux PHYs are capable of transmitting PPDUs
159 */
160 bool GetAuxPhyTxCapable() const;
161
162 /**
163 * Notify the reception of a management frame addressed to us.
164 *
165 * \param mpdu the received MPDU
166 * \param linkId the ID of the link over which the MPDU was received
167 */
168 void NotifyMgtFrameReceived(Ptr<const WifiMpdu> mpdu, uint8_t linkId);
169
170 /**
171 * Notify the reception of an initial Control frame on the given link.
172 *
173 * \param linkId the ID of the link on which the initial Control frame was received
174 */
175 void NotifyIcfReceived(uint8_t linkId);
176
177 /**
178 * Notify the start of an UL TXOP on the given link
179 *
180 * \param linkId the ID of the given link
181 * \param timeToCtsEnd time remaining to the end of CTS reception, in case the UL TXOP is
182 * started by an aux PHY
183 */
184 void NotifyUlTxopStart(uint8_t linkId, std::optional<Time> timeToCtsEnd);
185
186 /**
187 * Notify the end of a TXOP on the given link.
188 *
189 * \param linkId the ID of the given link
190 * \param ulTxopNotStarted whether this is a notification of the end of an UL TXOP that did
191 * not even start (no frame transmitted)
192 * \param ongoingDlTxop whether a DL TXOP is ongoing on the given link (if true, this is
193 * a notification of the end of an UL TXOP)
194 */
195 void NotifyTxopEnd(uint8_t linkId, bool ulTxopNotStarted = false, bool ongoingDlTxop = false);
196
197 /**
198 * Check whether the MediumSyncDelay timer is running for the STA operating on the given link.
199 * If so, returns the time elapsed since the timer started.
200 *
201 * \param linkId the ID of the given link
202 * \return the time elapsed since the MediumSyncDelay timer started, if this timer is running
203 * for the STA operating on the given link
204 */
205 std::optional<Time> GetElapsedMediumSyncDelayTimer(uint8_t linkId) const;
206
207 /**
208 * Cancel the MediumSyncDelay timer associated with the given link and take the appropriate
209 * actions. This function must not be called when the MediumSyncDelay timer is not running
210 * on the given link.
211 *
212 * \param linkId the ID of the link associated with the MediumSyncDelay timer to cancel
213 */
214 void CancelMediumSyncDelayTimer(uint8_t linkId);
215
216 /**
217 * Decrement the counter indicating the number of TXOP attempts left while the MediumSyncDelay
218 * timer is running. This function must not be called when the MediumSyncDelay timer is not
219 * running on the given link.
220 *
221 * \param linkId the ID of the link on which a new TXOP attempt may be carried out
222 */
223 void DecrementMediumSyncDelayNTxops(uint8_t linkId);
224
225 /**
226 * Reset the counter indicating the number of TXOP attempts left while the MediumSyncDelay
227 * timer is running, so as to remove the limit on the number of attempts that can be made
228 * while the MediumSyncDelay timer is running. This function is normally called when a TXOP
229 * attempt is successful. This function must not be called when the MediumSyncDelay timer is
230 * not running on the given link.
231 *
232 * \param linkId the ID of the link for which the counter of the TXOP attempts is reset
233 */
234 void ResetMediumSyncDelayNTxops(uint8_t linkId);
235
236 /**
237 * Return whether no more TXOP attempt is allowed on the given link. This function must not
238 * be called when the MediumSyncDelay timer is not running on the given link.
239 *
240 * \param linkId the ID of the link on which a new TXOP attempt may be carried out
241 * \return whether no more TXOP attempt on the given link is allowed
242 */
243 bool MediumSyncDelayNTxopsExceeded(uint8_t linkId);
244
245 protected:
246 void DoDispose() override;
247
248 /**
249 * \return the MAC of the non-AP MLD managed by this EMLSR Manager.
250 */
252
253 /**
254 * \param linkId the ID of the given link
255 * \return the EHT FrameExchangeManager attached to the non-AP STA operating on the given link
256 */
257 Ptr<EhtFrameExchangeManager> GetEhtFem(uint8_t linkId) const;
258
259 /**
260 * \return the ID of the link on which the EML Operating Mode Notification frame has to be sent
261 */
262 virtual uint8_t GetLinkToSendEmlOmn() = 0;
263
264 /**
265 * A previous EML Operating Mode Notification frame was dropped. Ask the subclass whether
266 * the frame needs to be re-sent on the given link (if any).
267 *
268 * \param mpdu the dropped MPDU that includes the EML Operating Mode Notification frame
269 * \return the ID of the link over which to re-send the frame, if needed
270 */
271 virtual std::optional<uint8_t> ResendNotification(Ptr<const WifiMpdu> mpdu) = 0;
272
273 /**
274 * \param linkId the ID of the given link
275 * \return the operating channel the main PHY must switch to in order to operate
276 * on the given link
277 */
278 const WifiPhyOperatingChannel& GetChannelForMainPhy(uint8_t linkId) const;
279
280 /**
281 * \param linkId the ID of the given link
282 * \return the operating channel an aux PHY must switch to in order to operate
283 * on the given link
284 */
285 const WifiPhyOperatingChannel& GetChannelForAuxPhy(uint8_t linkId) const;
286
287 /**
288 * Switch channel on the Main PHY so that it operates on the given link.
289 *
290 * \param linkId the ID of the link on which the main PHY has to operate
291 * \param noSwitchDelay whether switching delay should be zero
292 * \param resetBackoff whether backoff should be reset on the link on which the main PHY
293 * is operating
294 * \param requestAccess whether channel access should be requested on the link on which the
295 * main PHY is moving onto
296 */
297 void SwitchMainPhy(uint8_t linkId, bool noSwitchDelay, bool resetBackoff, bool requestAccess);
298
299 static constexpr bool RESET_BACKOFF = true; //!< reset backoff on main PHY switch
300 static constexpr bool DONT_RESET_BACKOFF = false; //!< do not reset backoff on main PHY switch
301 static constexpr bool REQUEST_ACCESS = true; //!< request channel access when PHY switch ends
302 static constexpr bool DONT_REQUEST_ACCESS =
303 false; //!< do not request channel access when PHY switch ends
304
305 /**
306 * Switch channel on the Aux PHY operating on the given current link so that it operates
307 * on the given next link.
308 *
309 * \param currLinkId the ID of the link on which the aux PHY is currently operating
310 * \param nextLinkId the ID of the link on which the aux PHY will be operating
311 */
312 void SwitchAuxPhy(uint8_t currLinkId, uint8_t nextLinkId);
313
314 /**
315 * Set the CCA ED threshold (if needed) on the given PHY that is switching channel to
316 * operate on the given link.
317 *
318 * \param phy the given PHY
319 * \param linkId the ID of the given link
320 */
321 void SetCcaEdThresholdOnLinkSwitch(Ptr<WifiPhy> phy, uint8_t linkId);
322
323 /**
324 * \return the EML Operating Mode Notification to send
325 */
327
328 Time m_emlsrPaddingDelay; //!< EMLSR Padding delay
329 Time m_emlsrTransitionDelay; //!< EMLSR Transition delay
330 uint8_t m_mainPhyId; //!< ID of main PHY (position in the vector of PHYs held by WifiNetDevice)
331 uint16_t m_auxPhyMaxWidth; //!< max channel width (MHz) supported by aux PHYs
332 WifiModulationClass m_auxPhyMaxModClass; //!< max modulation class supported by aux PHYs
333 bool m_auxPhyTxCapable; //!< whether Aux PHYs are capable of transmitting PPDUs
334
335 private:
336 /**
337 * Set the ID of main PHY (position in the vector of PHYs held by WifiNetDevice). This
338 * method cannot be called during or after initialization.
339 *
340 * \param mainPhyId the ID of the main PHY
341 */
342 void SetMainPhyId(uint8_t mainPhyId);
343
344 /**
345 * Compute the operating channels that the main PHY and the aux PHY(s) must switch to in order
346 * to operate on each of the setup links. The operating channels may be different due to
347 * limited channel width capabilities of the aux PHY(s). This method shall be called upon
348 * completion of ML setup.
349 */
351
352 /**
353 * Send an EML Operating Mode Notification frame.
354 */
355 void SendEmlOmn();
356
357 /**
358 * Start the MediumSyncDelay timer and take the appropriate actions, if the timer is not
359 * already running.
360 *
361 * \param linkId the ID of the link on which a TXOP was carried out that caused the STAs
362 * operating on other links to lose medium synchronization
363 */
364 void StartMediumSyncDelayTimer(uint8_t linkId);
365
366 /**
367 * Take the appropriate actions when the MediumSyncDelay timer expires or is cancelled.
368 *
369 * \param linkId the ID of the link associated with the MediumSyncDelay timer to cancel
370 */
371 void MediumSyncDelayTimerExpired(uint8_t linkId);
372
373 /**
374 * Notify the subclass of the reception of a management frame addressed to us.
375 *
376 * \param mpdu the received MPDU
377 * \param linkId the ID of the link over which the MPDU was received
378 */
379 virtual void DoNotifyMgtFrameReceived(Ptr<const WifiMpdu> mpdu, uint8_t linkId) = 0;
380
381 /**
382 * Notify the subclass of the reception of an initial Control frame on the given link.
383 *
384 * \param linkId the ID of the link on which the initial Control frame was received
385 */
386 virtual void DoNotifyIcfReceived(uint8_t linkId) = 0;
387
388 /**
389 * Notify the subclass of the start of an UL TXOP on the given link
390 *
391 * \param linkId the ID of the given link
392 */
393 virtual void DoNotifyUlTxopStart(uint8_t linkId) = 0;
394
395 /**
396 * Notify the subclass of the end of a TXOP on the given link.
397 *
398 * \param linkId the ID of the given link
399 */
400 virtual void DoNotifyTxopEnd(uint8_t linkId) = 0;
401
402 /**
403 * Notify the acknowledgment of the given MPDU.
404 *
405 * \param mpdu the acknowledged MPDU
406 */
407 void TxOk(Ptr<const WifiMpdu> mpdu);
408
409 /**
410 * Notify that the given MPDU has been discarded for the given reason.
411 *
412 * \param reason the reason why the MPDU was dropped
413 * \param mpdu the dropped MPDU
414 */
416
417 /**
418 * This method is called to make an EMLSR mode change effective after the transition
419 * delay has elapsed or a notification response has been received from the AP.
420 */
421 void ChangeEmlsrMode();
422
423 /**
424 * Adjust the operating channel of all the aux PHYs to meet the constraint on the maximum
425 * channel width supported by aux PHYs.
426 */
428
429 /**
430 * Notify subclass that EMLSR mode changed.
431 */
432 virtual void NotifyEmlsrModeChanged() = 0;
433
434 /**
435 * Notify subclass that the main PHY is switching channel to operate on another link.
436 *
437 * \param currLinkId the ID of the link on which the main PHY is operating
438 * \param nextLinkId the ID of the link on which the main PHY will be operating
439 */
440 virtual void NotifyMainPhySwitch(uint8_t currLinkId, uint8_t nextLinkId) = 0;
441
442 /**
443 * Information about the status of the MediumSyncDelay timer associated with a link.
444 */
446 {
447 EventId timer; //!< the MediumSyncDelay timer
448 std::optional<uint8_t> msdNTxopsLeft; //!< number of TXOP attempts left while the
449 //!< MediumSyncDelay timer is running
450 };
451
452 Ptr<StaWifiMac> m_staMac; //!< the MAC of the managed non-AP MLD
453 std::optional<Time> m_emlsrTransitionTimeout; /**< Transition timeout advertised by APs with
454 EMLSR activated */
455 Time m_mediumSyncDuration; //!< duration of the MediumSyncDelay timer
456 int8_t m_msdOfdmEdThreshold; //!< MediumSyncDelay OFDM ED threshold
457 std::optional<uint8_t> m_msdMaxNTxops; //!< MediumSyncDelay max number of TXOPs
458
459 std::map<uint8_t, MediumSyncDelayStatus>
460 m_mediumSyncDelayStatus; //!< the status of MediumSyncDelay timers (link ID-indexed)
461 std::map<Ptr<WifiPhy>, double> m_prevCcaEdThreshold; //!< the CCA sensitivity threshold (dBm)
462 //!< to restore once the MediumSyncDelay
463 //!< timer expires or the PHY moves to a
464 //!< link on which the timer is not running
465
466 std::set<uint8_t> m_emlsrLinks; //!< ID of the EMLSR links (empty if EMLSR mode is disabled)
467 std::optional<std::set<uint8_t>> m_nextEmlsrLinks; /**< ID of the links that will become the
468 EMLSR links when the pending
469 notification frame is acknowledged */
470 Time m_lastAdvPaddingDelay; //!< last advertised padding delay
471 Time m_lastAdvTransitionDelay; //!< last advertised transition delay
472 EventId m_transitionTimeoutEvent; /**< Timer started after the successful transmission of an
473 EML Operating Mode Notification frame */
474 bool m_resetCamState; //!< whether to reset the state of CAM when main PHY switches channel
475 std::map<uint8_t, WifiPhyOperatingChannel>
476 m_mainPhyChannels; //!< link ID-indexed map of operating channels for the main PHY
477 std::map<uint8_t, WifiPhyOperatingChannel>
478 m_auxPhyChannels; //!< link ID-indexed map of operating channels for the aux PHYs
479 std::map<uint8_t, EventId> m_ulMainPhySwitch; //!< link ID-indexed map of timers started when
480 //!< an aux PHY gains an UL TXOP and schedules
481 //!< a channel switch for the main PHY
482};
483
484} // namespace ns3
485
486#endif /* EMLSR_MANAGER_H */
EmlsrManager is an abstract base class defining the API that EHT non-AP MLDs with EMLSR activated can...
Definition: emlsr-manager.h:47
void SendEmlOmn()
Send an EML Operating Mode Notification frame.
Time GetMediumSyncDuration() const
void ComputeOperatingChannels()
Compute the operating channels that the main PHY and the aux PHY(s) must switch to in order to operat...
void SetTransitionTimeout(Time timeout)
Set the Transition Timeout advertised by the associated AP with EMLSR activated.
void CancelMediumSyncDelayTimer(uint8_t linkId)
Cancel the MediumSyncDelay timer associated with the given link and take the appropriate actions.
bool m_auxPhyTxCapable
whether Aux PHYs are capable of transmitting PPDUs
bool MediumSyncDelayNTxopsExceeded(uint8_t linkId)
Return whether no more TXOP attempt is allowed on the given link.
std::optional< Time > GetTransitionTimeout() const
void ChangeEmlsrMode()
This method is called to make an EMLSR mode change effective after the transition delay has elapsed o...
Ptr< EhtFrameExchangeManager > GetEhtFem(uint8_t linkId) const
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.
virtual void NotifyMainPhySwitch(uint8_t currLinkId, uint8_t nextLinkId)=0
Notify subclass that the main PHY is switching channel to operate on another link.
void MediumSyncDelayTimerExpired(uint8_t linkId)
Take the appropriate actions when the MediumSyncDelay timer expires or is cancelled.
void NotifyTxopEnd(uint8_t linkId, bool ulTxopNotStarted=false, bool ongoingDlTxop=false)
Notify the end of a TXOP on the given link.
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...
void SwitchMainPhy(uint8_t linkId, bool noSwitchDelay, bool resetBackoff, bool requestAccess)
Switch channel on the Main PHY so that it operates on the given link.
bool GetCamStateReset() const
void NotifyUlTxopStart(uint8_t linkId, std::optional< Time > timeToCtsEnd)
Notify the start of an UL TXOP on the given link.
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,...
void SetMediumSyncOfdmEdThreshold(int8_t threshold)
Set the Medium Synchronization OFDM ED threshold (dBm) to use while the MediumSyncDelay timer is runn...
uint8_t m_mainPhyId
ID of main PHY (position in the vector of PHYs held by WifiNetDevice)
int8_t GetMediumSyncOfdmEdThreshold() const
void NotifyIcfReceived(uint8_t linkId)
Notify the reception of an initial Control frame on the given link.
std::map< uint8_t, MediumSyncDelayStatus > m_mediumSyncDelayStatus
the status of MediumSyncDelay timers (link ID-indexed)
void NotifyMgtFrameReceived(Ptr< const WifiMpdu > mpdu, uint8_t linkId)
Notify the reception of a management frame addressed to us.
virtual uint8_t GetLinkToSendEmlOmn()=0
std::map< uint8_t, WifiPhyOperatingChannel > m_auxPhyChannels
link ID-indexed map of operating channels for the aux PHYs
virtual void DoNotifyUlTxopStart(uint8_t linkId)=0
Notify the subclass of the start of an UL TXOP on the given link.
Ptr< StaWifiMac > m_staMac
the MAC of the managed non-AP MLD
virtual void DoNotifyMgtFrameReceived(Ptr< const WifiMpdu > mpdu, uint8_t linkId)=0
Notify the subclass of the reception of a management frame addressed to us.
Time m_emlsrPaddingDelay
EMLSR Padding delay.
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 MediumSyncDe...
Time m_emlsrTransitionDelay
EMLSR Transition delay.
void SetWifiMac(Ptr< StaWifiMac > mac)
Set the wifi MAC.
void DecrementMediumSyncDelayNTxops(uint8_t linkId)
Decrement the counter indicating the number of TXOP attempts left while the MediumSyncDelay timer is ...
bool GetAuxPhyTxCapable() const
const std::set< uint8_t > & GetEmlsrLinks() const
Time m_mediumSyncDuration
duration of the MediumSyncDelay timer
std::optional< Time > m_emlsrTransitionTimeout
Transition timeout advertised by APs with EMLSR activated.
void ResetMediumSyncDelayNTxops(uint8_t linkId)
Reset the counter indicating the number of TXOP attempts left while the MediumSyncDelay timer is runn...
std::optional< Time > GetElapsedMediumSyncDelayTimer(uint8_t linkId) const
Check whether the MediumSyncDelay timer is running for the STA operating on the given link.
virtual void DoNotifyTxopEnd(uint8_t linkId)=0
Notify the subclass of the end of a TXOP on the given link.
std::map< Ptr< WifiPhy >, double > m_prevCcaEdThreshold
the CCA sensitivity threshold (dBm) to restore once the MediumSyncDelay timer expires or the PHY move...
void SetAuxPhyTxCapable(bool capable)
Set the member variable indicating whether Aux PHYs are capable of transmitting PPDUs.
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.
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 giv...
virtual void NotifyEmlsrModeChanged()=0
Notify subclass that EMLSR mode changed.
void SetMainPhyId(uint8_t mainPhyId)
Set the ID of main PHY (position in the vector of PHYs held by WifiNetDevice).
const WifiPhyOperatingChannel & GetChannelForMainPhy(uint8_t linkId) const
~EmlsrManager() override
void ApplyMaxChannelWidthAndModClassOnAuxPhys()
Adjust the operating channel of all the aux PHYs to meet the constraint on the maximum channel width ...
void SetMediumSyncDuration(Time duration)
Set the duration of the MediumSyncDelay timer.
static constexpr bool RESET_BACKOFF
reset backoff on main PHY switch
Time m_lastAdvTransitionDelay
last advertised transition delay
static constexpr bool REQUEST_ACCESS
request channel access when PHY switch ends
static constexpr bool DONT_REQUEST_ACCESS
do not request channel access when PHY switch ends
void DoDispose() override
Destructor implementation.
void StartMediumSyncDelayTimer(uint8_t linkId)
Start the MediumSyncDelay timer and take the appropriate actions, if the timer is not already running...
int8_t m_msdOfdmEdThreshold
MediumSyncDelay OFDM ED threshold.
std::map< uint8_t, WifiPhyOperatingChannel > m_mainPhyChannels
link ID-indexed map of operating channels for the main PHY
std::optional< uint8_t > m_msdMaxNTxops
MediumSyncDelay max number of TXOPs.
virtual std::optional< uint8_t > ResendNotification(Ptr< const WifiMpdu > mpdu)=0
A previous EML Operating Mode Notification frame was dropped.
Ptr< StaWifiMac > GetStaMac() const
Time m_lastAdvPaddingDelay
last advertised padding delay
WifiModulationClass m_auxPhyMaxModClass
max modulation class supported by aux PHYs
void SwitchAuxPhy(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 ne...
uint8_t GetMainPhyId() const
std::optional< uint8_t > GetMediumSyncMaxNTxops() const
void SetCamStateReset(bool enable)
Set the member variable indicating whether the state of the CAM should be reset when the main PHY swi...
EventId m_transitionTimeoutEvent
Timer started after the successful transmission of an EML Operating Mode Notification frame.
uint16_t m_auxPhyMaxWidth
max channel width (MHz) supported by aux PHYs
virtual void DoNotifyIcfReceived(uint8_t linkId)=0
Notify the subclass of the reception of an initial Control frame on the given link.
const WifiPhyOperatingChannel & GetChannelForAuxPhy(uint8_t linkId) const
bool m_resetCamState
whether to reset the state of CAM when main PHY switches channel
static TypeId GetTypeId()
Get the type ID.
std::set< uint8_t > m_emlsrLinks
ID of the EMLSR links (empty if EMLSR mode is disabled)
static constexpr bool DONT_RESET_BACKOFF
do not reset backoff on main PHY switch
MgtEmlOmn GetEmlOmn()
An identifier for simulation events.
Definition: event-id.h:56
Implement the header for Action frames of type EML Operating Mode Notification.
A base class which provides memory management and object aggregation.
Definition: object.h:89
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:77
Simulation virtual time values and global simulation resolution.
Definition: nstime.h:105
a unique identifier for an interface.
Definition: type-id.h:59
Class that keeps track of all information about the current PHY operating channel.
WifiMacDropReason
The reason why an MPDU was dropped.
Definition: wifi-mac.h:80
WifiModulationClass
This enumeration defines the modulation classes per (Table 10-6 "Modulation classes"; IEEE 802....
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::Time timeout
Information about the status of the MediumSyncDelay timer associated with a link.
std::optional< uint8_t > msdNTxopsLeft
number of TXOP attempts left while the MediumSyncDelay timer is running
EventId timer
the MediumSyncDelay timer