22 #include "ns3/double.h"    24 #include "ns3/wifi-net-device.h"    25 #include "ns3/wifi-phy.h"    27 #include "ns3/wifi-utils.h"    39     .SetGroupName (
"Wifi")
    40     .AddAttribute (
"ObssPdLevel",
    41                    "The current OBSS PD level (dBm).",
    44                    MakeDoubleChecker<double> (-101, -62))
    45     .AddAttribute (
"ObssPdLevelMin",
    46                    "Minimum value (dBm) of OBSS PD level.",
    49                    MakeDoubleChecker<double> (-101, -62))
    50     .AddAttribute (
"ObssPdLevelMax",
    51                    "Maximum value (dBm) of OBSS PD level.",
    54                    MakeDoubleChecker<double> (-101, -62))
    55     .AddAttribute (
"TxPowerRefSiso",
    56                    "The SISO reference TX power level (dBm).",
    59                    MakeDoubleChecker<double> ())
    60     .AddAttribute (
"TxPowerRefMimo",
    61                    "The MIMO reference TX power level (dBm).",
    64                    MakeDoubleChecker<double> ())
    65     .AddTraceSource (
"Reset", 
"Trace CCA Reset event",
    67                      "ns3::ObssPdAlgorithm::ResetTracedCallback")
    89   double txPowerMaxSiso = 0;
    90   double txPowerMaxMimo = 0;
    91   bool powerRestricted = 
false;
    95   uint8_t bssColor = heConfiguration->GetBssColor ();
    96   NS_LOG_DEBUG (
"My BSS color " << (uint16_t) bssColor << 
" received frame " << (uint16_t) params.
bssColor);
   103       powerRestricted = 
true;
   106   phy->ResetCca (powerRestricted, txPowerMaxSiso, txPowerMaxMimo);
 double m_txPowerRefSiso
SISO reference TX power level (dBm) 
 
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by "...
 
Parameters for received HE-SIG-A for OBSS_PD based SR. 
 
void DoDispose(void) override
Destructor implementation. 
 
Ptr< HeConfiguration > GetHeConfiguration(void) const
 
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system. 
 
#define NS_ASSERT(condition)
At runtime, in debugging builds, if this condition is not true, the program prints the source file...
 
double m_txPowerRefMimo
MIMO reference TX power level (dBm) 
 
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name. 
 
static TypeId GetTypeId(void)
Get the type ID. 
 
uint8_t bssColor
BSS color. 
 
double m_obssPdLevelMin
Minimum OBSS PD level (dBm) 
 
double m_obssPdLevelMax
Maximum OBSS PD level (dBm) 
 
Ptr< const TraceSourceAccessor > MakeTraceSourceAccessor(T a)
Create a TraceSourceAccessor which will control access to the underlying trace source. 
 
double m_obssPdLevel
Current OBSS PD level (dBm) 
 
virtual void ConnectWifiNetDevice(const Ptr< WifiNetDevice > device)
Connect the WifiNetDevice and setup eventual callbacks. 
 
Ptr< WifiPhy > GetPhy(void) const
 
Ptr< WifiNetDevice > m_device
Pointer to the WifiNetDevice. 
 
Every class exported by the ns3 library is enclosed in the ns3 namespace. 
 
double WToDbm(double w)
Convert from Watts to dBm. 
 
Ptr< const AttributeAccessor > MakeDoubleAccessor(T1 a1)
 Create an AttributeAccessor for a class data member, or a lone class get functor or set method...
 
#define NS_LOG_DEBUG(msg)
Use NS_LOG to output a message of level LOG_DEBUG. 
 
A base class which provides memory management and object aggregation. 
 
TracedCallback< uint8_t, double, bool, double, double > m_resetEvent
TracedCallback signature for PHY reset events. 
 
Declaration of ns3::HePhy class and ns3::HeSigAParameters struct. 
 
This class can be used to hold variables of floating point type such as 'double' or 'float'...
 
a unique identifier for an interface. 
 
TypeId SetParent(TypeId tid)
Set the parent TypeId. 
 
void ResetPhy(HeSigAParameters params)
Reset PHY to IDLE.