A Discrete-Event Network Simulator
API
ns3::WifiPhyListener Class Referenceabstract

receive notifications about PHY events. More...

#include "wifi-phy-listener.h"

+ Inheritance diagram for ns3::WifiPhyListener:

Public Member Functions

virtual ~WifiPhyListener ()
 
virtual void NotifyMaybeCcaBusyStart (Time duration)=0
 
virtual void NotifyOff (void)=0
 Notify listeners that we went to switch off. More...
 
virtual void NotifyOn (void)=0
 Notify listeners that we went to switch on. More...
 
virtual void NotifyRxEndError (void)=0
 We have received the last bit of a packet for which NotifyRxStart was invoked first and, the packet has not been successfully received. More...
 
virtual void NotifyRxEndOk (void)=0
 We have received the last bit of a packet for which NotifyRxStart was invoked first and, the packet has been successfully received. More...
 
virtual void NotifyRxStart (Time duration)=0
 
virtual void NotifySleep (void)=0
 Notify listeners that we went to sleep. More...
 
virtual void NotifySwitchingStart (Time duration)=0
 
virtual void NotifyTxStart (Time duration, double txPowerDbm)=0
 
virtual void NotifyWakeup (void)=0
 Notify listeners that we woke up. More...
 

Detailed Description

receive notifications about PHY events.

Definition at line 32 of file wifi-phy-listener.h.

Constructor & Destructor Documentation

◆ ~WifiPhyListener()

virtual ns3::WifiPhyListener::~WifiPhyListener ( )
inlinevirtual

Definition at line 39 of file wifi-phy-listener.h.

Member Function Documentation

◆ NotifyMaybeCcaBusyStart()

virtual void ns3::WifiPhyListener::NotifyMaybeCcaBusyStart ( Time  duration)
pure virtual
Parameters
durationthe expected busy duration.

This method does not really report a real state change as opposed to the other methods in this class. It merely reports that, unless the medium is reported busy through NotifyTxStart or NotifyRxStart/End, it will be busy as defined by the currently selected CCA mode.

Typical client code which wants to have a clear picture of the CCA state will need to keep track of the time at which the last NotifyCcaBusyStart method is called and what duration it reported.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifyOff()

virtual void ns3::WifiPhyListener::NotifyOff ( void  )
pure virtual

Notify listeners that we went to switch off.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifyOn()

virtual void ns3::WifiPhyListener::NotifyOn ( void  )
pure virtual

Notify listeners that we went to switch on.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifyRxEndError()

virtual void ns3::WifiPhyListener::NotifyRxEndError ( void  )
pure virtual

We have received the last bit of a packet for which NotifyRxStart was invoked first and, the packet has not been successfully received.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifyRxEndOk()

virtual void ns3::WifiPhyListener::NotifyRxEndOk ( void  )
pure virtual

We have received the last bit of a packet for which NotifyRxStart was invoked first and, the packet has been successfully received.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifyRxStart()

virtual void ns3::WifiPhyListener::NotifyRxStart ( Time  duration)
pure virtual
Parameters
durationthe expected duration of the packet reception.

We have received the first bit of a packet. We decided that we could synchronize on this packet. It does not mean we will be able to successfully receive completely the whole packet. It means that we will report a BUSY status until one of the following happens:

  • NotifyRxEndOk
  • NotifyRxEndError
  • NotifyTxStart

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifySleep()

virtual void ns3::WifiPhyListener::NotifySleep ( void  )
pure virtual

Notify listeners that we went to sleep.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifySwitchingStart()

virtual void ns3::WifiPhyListener::NotifySwitchingStart ( Time  duration)
pure virtual
Parameters
durationthe expected channel switching duration.

We do not send any event to notify the end of channel switching. Listeners should assume that the channel implicitly reverts to the idle or busy states.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifyTxStart()

virtual void ns3::WifiPhyListener::NotifyTxStart ( Time  duration,
double  txPowerDbm 
)
pure virtual
Parameters
durationthe expected transmission duration.
txPowerDbmthe nominal TX power in dBm

We are about to send the first bit of the packet. We do not send any event to notify the end of transmission. Listeners should assume that the channel implicitly reverts to the idle state unless they have received a CCA busy report.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.

◆ NotifyWakeup()

virtual void ns3::WifiPhyListener::NotifyWakeup ( void  )
pure virtual

Notify listeners that we woke up.

Implemented in TestPhyListener, ns3::WifiRadioEnergyModelPhyListener, and ns3::PhyListener.


The documentation for this class was generated from the following file: