#include <yans-wifi-phy-state-helper.h>
Definition at line 30 of file yans-wifi-phy-state-helper.h.
typedef std::vector<WifiPhyListener *> ns3::YansWifiPhyStateHelper::Listeners [private] |
Definition at line 60 of file yans-wifi-phy-state-helper.h.
ns3::YansWifiPhyStateHelper::YansWifiPhyStateHelper | ( | ) |
Definition at line 52 of file yans-wifi-phy-state-helper.cc.
References NS_LOG_FUNCTION.
void ns3::YansWifiPhyStateHelper::CallRxErrorTrace | ( | Ptr< const Packet > | packet, | |
WifiPhy::RxErrorReason | rxErrorReason | |||
) |
Definition at line 347 of file yans-wifi-phy-state-helper.cc.
References m_rxErrorTrace.
void ns3::YansWifiPhyStateHelper::DoSwitchFromRx | ( | void | ) | [private] |
Definition at line 311 of file yans-wifi-phy-state-helper.cc.
References IsStateCcaBusy(), IsStateIdle(), IsStateRx(), m_previousStateChangeTime, m_rxing, m_startRx, m_stateLogger, ns3::Now(), NS_ASSERT, and ns3::WifiPhy::RX.
Referenced by SwitchFromRxEndError(), and SwitchFromRxEndOk().
Time ns3::YansWifiPhyStateHelper::GetDelayUntilIdle | ( | void | ) |
Definition at line 120 of file yans-wifi-phy-state-helper.cc.
References ns3::WifiPhy::CCA_BUSY, GetState(), ns3::WifiPhy::IDLE, m_endCcaBusy, m_endRx, m_endTx, ns3::Max(), ns3::Now(), NS_ASSERT, ns3::WifiPhy::RX, ns3::Seconds(), and ns3::WifiPhy::TX.
Time ns3::YansWifiPhyStateHelper::GetLastRxStartTime | ( | void | ) | const |
Definition at line 148 of file yans-wifi-phy-state-helper.cc.
References m_startRx.
enum WifiPhy::State ns3::YansWifiPhyStateHelper::GetState | ( | void | ) |
Definition at line 154 of file yans-wifi-phy-state-helper.cc.
References ns3::WifiPhy::CCA_BUSY, ns3::WifiPhy::IDLE, m_endCcaBusy, m_endTx, m_rxing, ns3::Simulator::Now(), ns3::WifiPhy::RX, and ns3::WifiPhy::TX.
Referenced by GetDelayUntilIdle(), IsStateBusy(), IsStateCcaBusy(), IsStateIdle(), IsStateRx(), IsStateSyncing(), IsStateTx(), SwitchMaybeToCcaBusy(), SwitchToRx(), and SwitchToTx().
Time ns3::YansWifiPhyStateHelper::GetStateDuration | ( | void | ) |
Definition at line 114 of file yans-wifi-phy-state-helper.cc.
References m_previousStateChangeTime, and ns3::Now().
TypeId ns3::YansWifiPhyStateHelper::GetTypeId | ( | void | ) | [static] |
This method returns the TypeId associated to ns3::YansWifiPhyStateHelper.
This object is accessible through the following paths with Config::Set and Config::Connect:
No Attributes defined for this type.
TraceSources defined for this type:
Reimplemented from ns3::Object.
Definition at line 32 of file yans-wifi-phy-state-helper.cc.
References ns3::TypeId::AddTraceSource(), m_rxErrorTrace, m_rxOkTrace, m_stateLogger, m_txTrace, ns3::MakeTraceSourceAccessor(), and ns3::TypeId::SetParent().
bool ns3::YansWifiPhyStateHelper::IsStateBusy | ( | void | ) |
Definition at line 93 of file yans-wifi-phy-state-helper.cc.
References GetState(), and ns3::WifiPhy::IDLE.
bool ns3::YansWifiPhyStateHelper::IsStateCcaBusy | ( | void | ) |
Definition at line 82 of file yans-wifi-phy-state-helper.cc.
References ns3::WifiPhy::CCA_BUSY, and GetState().
Referenced by DoSwitchFromRx(), and SwitchToRx().
bool ns3::YansWifiPhyStateHelper::IsStateIdle | ( | void | ) |
Definition at line 88 of file yans-wifi-phy-state-helper.cc.
References GetState(), and ns3::WifiPhy::IDLE.
Referenced by DoSwitchFromRx(), and SwitchToRx().
bool ns3::YansWifiPhyStateHelper::IsStateRx | ( | void | ) |
Definition at line 103 of file yans-wifi-phy-state-helper.cc.
References GetState(), and ns3::WifiPhy::RX.
Referenced by DoSwitchFromRx(), and SwitchToRx().
bool ns3::YansWifiPhyStateHelper::IsStateSyncing | ( | void | ) |
Definition at line 98 of file yans-wifi-phy-state-helper.cc.
References GetState(), and ns3::WifiPhy::SYNCING.
bool ns3::YansWifiPhyStateHelper::IsStateTx | ( | void | ) |
Definition at line 108 of file yans-wifi-phy-state-helper.cc.
References GetState(), and ns3::WifiPhy::TX.
void ns3::YansWifiPhyStateHelper::LogPreviousIdleAndCcaBusyStates | ( | void | ) | [private] |
Definition at line 212 of file yans-wifi-phy-state-helper.cc.
References ns3::WifiPhy::CCA_BUSY, ns3::WifiPhy::IDLE, m_endCcaBusy, m_endRx, m_endTx, m_startCcaBusy, m_stateLogger, ns3::Max(), ns3::Now(), and NS_ASSERT.
Referenced by SwitchMaybeToCcaBusy(), SwitchToRx(), and SwitchToTx().
void ns3::YansWifiPhyStateHelper::NotifyMaybeCcaBusyStart | ( | Time | duration | ) | [private] |
Definition at line 204 of file yans-wifi-phy-state-helper.cc.
References m_listeners.
Referenced by SwitchMaybeToCcaBusy().
void ns3::YansWifiPhyStateHelper::NotifyRxEndError | ( | void | ) | [private] |
Definition at line 197 of file yans-wifi-phy-state-helper.cc.
References m_listeners.
Referenced by SwitchFromRxEndError().
void ns3::YansWifiPhyStateHelper::NotifyRxEndOk | ( | void | ) | [private] |
Definition at line 190 of file yans-wifi-phy-state-helper.cc.
References m_listeners.
Referenced by SwitchFromRxEndOk().
void ns3::YansWifiPhyStateHelper::NotifyRxStart | ( | Time | duration | ) | [private] |
Definition at line 183 of file yans-wifi-phy-state-helper.cc.
References m_listeners.
Referenced by SwitchToRx().
void ns3::YansWifiPhyStateHelper::NotifyTxStart | ( | Time | duration | ) | [private] |
Definition at line 176 of file yans-wifi-phy-state-helper.cc.
References m_listeners.
Referenced by SwitchToTx().
void ns3::YansWifiPhyStateHelper::NotifyWakeup | ( | void | ) | [private] |
void ns3::YansWifiPhyStateHelper::RegisterListener | ( | WifiPhyListener * | listener | ) |
Definition at line 76 of file yans-wifi-phy-state-helper.cc.
References m_listeners.
void ns3::YansWifiPhyStateHelper::SetReceiveErrorCallback | ( | WifiPhy::RxErrorCallback | callback | ) |
Definition at line 71 of file yans-wifi-phy-state-helper.cc.
References m_rxErrorCallback.
void ns3::YansWifiPhyStateHelper::SetReceiveOkCallback | ( | WifiPhy::RxOkCallback | callback | ) |
Definition at line 66 of file yans-wifi-phy-state-helper.cc.
References m_rxOkCallback.
Definition at line 299 of file yans-wifi-phy-state-helper.cc.
References DoSwitchFromRx(), ns3::Callback< R, T1, T2, T3, T4, T5, T6, T7, T8, T9 >::IsNull(), m_rxErrorCallback, m_rxErrorTrace, NotifyRxEndError(), and ns3::WifiPhy::RXERROR_BAD_SIGNAL.
Definition at line 288 of file yans-wifi-phy-state-helper.cc.
References DoSwitchFromRx(), ns3::Callback< R, T1, T2, T3, T4, T5, T6, T7, T8, T9 >::IsNull(), m_rxOkCallback, m_rxOkTrace, and NotifyRxEndOk().
void ns3::YansWifiPhyStateHelper::SwitchMaybeToCcaBusy | ( | Time | duration | ) |
Definition at line 324 of file yans-wifi-phy-state-helper.cc.
References ns3::WifiPhy::CCA_BUSY, GetState(), ns3::WifiPhy::IDLE, LogPreviousIdleAndCcaBusyStates(), m_endCcaBusy, m_startCcaBusy, NotifyMaybeCcaBusyStart(), ns3::Now(), NS_ASSERT, ns3::WifiPhy::RX, and ns3::WifiPhy::TX.
void ns3::YansWifiPhyStateHelper::SwitchToRx | ( | Time | rxDuration | ) |
Definition at line 260 of file yans-wifi-phy-state-helper.cc.
References ns3::WifiPhy::CCA_BUSY, GetState(), ns3::WifiPhy::IDLE, IsStateCcaBusy(), IsStateIdle(), IsStateRx(), LogPreviousIdleAndCcaBusyStates(), m_endRx, m_endTx, m_previousStateChangeTime, m_rxing, m_startCcaBusy, m_startRx, m_stateLogger, ns3::Max(), NotifyRxStart(), ns3::Now(), NS_ASSERT, ns3::WifiPhy::RX, and ns3::WifiPhy::TX.
Definition at line 228 of file yans-wifi-phy-state-helper.cc.
References ns3::WifiPhy::CCA_BUSY, GetState(), ns3::WifiPhy::IDLE, LogPreviousIdleAndCcaBusyStates(), m_endRx, m_endTx, m_previousStateChangeTime, m_rxing, m_startCcaBusy, m_startRx, m_startTx, m_stateLogger, m_txTrace, ns3::Max(), NotifyTxStart(), ns3::Now(), NS_ASSERT, ns3::WifiPhy::RX, and ns3::WifiPhy::TX.
Definition at line 75 of file yans-wifi-phy-state-helper.h.
Referenced by GetDelayUntilIdle(), GetState(), LogPreviousIdleAndCcaBusyStates(), and SwitchMaybeToCcaBusy().
Time ns3::YansWifiPhyStateHelper::m_endRx [private] |
Definition at line 74 of file yans-wifi-phy-state-helper.h.
Referenced by GetDelayUntilIdle(), LogPreviousIdleAndCcaBusyStates(), SwitchToRx(), and SwitchToTx().
Time ns3::YansWifiPhyStateHelper::m_endTx [private] |
Definition at line 73 of file yans-wifi-phy-state-helper.h.
Referenced by GetDelayUntilIdle(), GetState(), LogPreviousIdleAndCcaBusyStates(), SwitchToRx(), and SwitchToTx().
Definition at line 81 of file yans-wifi-phy-state-helper.h.
Referenced by NotifyMaybeCcaBusyStart(), NotifyRxEndError(), NotifyRxEndOk(), NotifyRxStart(), NotifyTxStart(), and RegisterListener().
Definition at line 79 of file yans-wifi-phy-state-helper.h.
Referenced by DoSwitchFromRx(), GetStateDuration(), SwitchToRx(), and SwitchToTx().
Definition at line 87 of file yans-wifi-phy-state-helper.h.
Referenced by SetReceiveErrorCallback(), and SwitchFromRxEndError().
TracedCallback< Ptr<const Packet>, WifiPhy::RxErrorReason > ns3::YansWifiPhyStateHelper::m_rxErrorTrace [private] |
Definition at line 84 of file yans-wifi-phy-state-helper.h.
Referenced by CallRxErrorTrace(), GetTypeId(), and SwitchFromRxEndError().
bool ns3::YansWifiPhyStateHelper::m_rxing [private] |
Definition at line 72 of file yans-wifi-phy-state-helper.h.
Referenced by DoSwitchFromRx(), GetState(), SwitchToRx(), and SwitchToTx().
Definition at line 86 of file yans-wifi-phy-state-helper.h.
Referenced by SetReceiveOkCallback(), and SwitchFromRxEndOk().
TracedCallback< Ptr<const Packet> > ns3::YansWifiPhyStateHelper::m_rxOkTrace [private] |
Definition at line 83 of file yans-wifi-phy-state-helper.h.
Referenced by GetTypeId(), and SwitchFromRxEndOk().
Definition at line 78 of file yans-wifi-phy-state-helper.h.
Referenced by LogPreviousIdleAndCcaBusyStates(), SwitchMaybeToCcaBusy(), SwitchToRx(), and SwitchToTx().
Time ns3::YansWifiPhyStateHelper::m_startRx [private] |
Definition at line 77 of file yans-wifi-phy-state-helper.h.
Referenced by DoSwitchFromRx(), GetLastRxStartTime(), SwitchToRx(), and SwitchToTx().
Time ns3::YansWifiPhyStateHelper::m_startTx [private] |
Definition at line 76 of file yans-wifi-phy-state-helper.h.
Referenced by SwitchToTx().
TracedCallback< Time, Time, enum WifiPhy::State > ns3::YansWifiPhyStateHelper::m_stateLogger [private] |
Definition at line 82 of file yans-wifi-phy-state-helper.h.
Referenced by DoSwitchFromRx(), GetTypeId(), LogPreviousIdleAndCcaBusyStates(), SwitchToRx(), and SwitchToTx().
TracedCallback< Ptr<const Packet> > ns3::YansWifiPhyStateHelper::m_txTrace [private] |
Definition at line 85 of file yans-wifi-phy-state-helper.h.
Referenced by GetTypeId(), and SwitchToTx().