Hybrid wireless mesh protocol -- a routing protocol of IEEE 802.11s draft. More...
#include <hwmp-protocol.h>
Classes | |
struct | FailedDestination |
structure of unreachable destination - address and sequence number More... | |
struct | PathError |
Structure of path error: IePerr and list of receivers: interfaces and MAC address. More... | |
struct | QueuedPacket |
Packet waiting its routing information. More... | |
Public Member Functions | |
void | DoDispose () |
bool | RequestRoute (uint32_t sourceIface, const Mac48Address source, const Mac48Address destination, Ptr< const Packet > packet, uint16_t protocolType, RouteReplyCallback routeReply) |
Route request, inherited from MeshL2RoutingProtocol. | |
bool | RemoveRoutingStuff (uint32_t fromIface, const Mac48Address source, const Mac48Address destination, Ptr< Packet > packet, uint16_t &protocolType) |
Cleanup packet from all tags. | |
bool | Install (Ptr< MeshPointDevice >) |
Install HWMP on given mesh point. | |
void | SetNeighboursCallback (Callback< std::vector< Mac48Address >, uint32_t > cb) |
This callback is used to obtain active neighbours on a given interface. | |
void | Report (std::ostream &) const |
Statistics: | |
Proactive PREQ mechanism: | |
void | SetRoot () |
void | UnsetRoot () |
Static Public Member Functions | |
static TypeId | GetTypeId () |
This method returns the TypeId associated to ns3::dot11s::HwmpProtocol. | |
Private Member Functions | |
bool | ForwardUnicast (uint32_t sourceIface, const Mac48Address source, const Mac48Address destination, Ptr< Packet > packet, uint16_t protocolType, RouteReplyCallback routeReply, uint32_t ttl) |
Like RequestRoute, but for unicast packets. | |
Mac48Address | GetAddress () |
Interaction with HWMP MAC plugin | |
void | ReceivePreq (IePreq preq, Mac48Address from, uint32_t interface, Mac48Address fromMp, uint32_t metric) |
void | ReceivePrep (IePrep prep, Mac48Address from, uint32_t interface, Mac48Address fromMp, uint32_t metric) |
void | ReceivePerr (std::vector< FailedDestination >, Mac48Address from, uint32_t interface, Mac48Address fromMp) |
void | SendPrep (Mac48Address src, Mac48Address dst, Mac48Address retransmitter, uint32_t initMetric, uint32_t originatorDsn, uint32_t destinationSN, uint32_t lifetime, uint32_t interface) |
PathError | MakePathError (std::vector< FailedDestination > destinations) |
forms a path error information element when list of destination fails on a given interface | |
void | ForwardPathError (PathError perr) |
Forwards a received path error. | |
void | InitiatePathError (PathError perr) |
Pasess a selg-generated PERR to interface-plugin. | |
std::vector< std::pair < uint32_t, Mac48Address > > | GetPerrReceivers (std::vector< FailedDestination > failedDest) |
std::vector< Mac48Address > | GetPreqReceivers (uint32_t interface) |
std::vector< Mac48Address > | GetBroadcastReceivers (uint32_t interface) |
bool | DropDataFrame (uint32_t seqno, Mac48Address source) |
MAC-plugin asks whether the frame can be dropped. Protocol automatically updates seqno. | |
Methods related to Queue/Dequeue procedures | |
bool | QueuePacket (QueuedPacket packet) |
QueuedPacket | DequeueFirstPacketByDst (Mac48Address dst) |
QueuedPacket | DequeueFirstPacket () |
void | ReactivePathResolved (Mac48Address dst) |
void | ProactivePathResolved () |
Methods responsible for path discovery retry procedure: | |
bool | ShouldSendPreq (Mac48Address dst) |
checks when the last path discovery procedure was started for a given destination. | |
void | RetryPathDiscovery (Mac48Address dst, uint8_t numOfRetry) |
Generates PREQ retry when retry timeout has expired and route is still unresolved. | |
void | SendProactivePreq () |
Proactive Preq routines: | |
Methods needed by HwmpMacLugin to access protocol parameters: | |
bool | GetDoFlag () |
bool | GetRfFlag () |
Time | GetPreqMinInterval () |
Time | GetPerrMinInterval () |
uint8_t | GetMaxTtl () |
uint32_t | GetNextPreqId () |
uint32_t | GetNextHwmpSeqno () |
uint32_t | GetActivePathLifetime () |
uint8_t | GetUnicastPerrThreshold () |
Private Attributes | |
Ptr< HwmpRtable > | m_rtable |
Routing table. | |
std::vector< QueuedPacket > | m_rqueue |
Statistics: | |
Statistics | m_stats |
Sequence number filters | |
std::map< Mac48Address, uint32_t > | m_lastDataSeqno |
std::map< Mac48Address, uint32_t > | m_lastHwmpSeqno |
DSN databse. | |
std::map< Mac48Address, uint32_t > | m_lastHwmpMetric |
Metric database. | |
Timers: | |
std::map< Mac48Address, EventId > | m_preqTimeouts |
EventId | m_proactivePreqTimer |
Time | m_randomStart |
Random start in Proactive PREQ propagation. | |
HWMP-protocol parameters (attributes of GetTypeId) | |
uint16_t | m_maxQueueSize |
uint8_t | m_dot11MeshHWMPmaxPREQretries |
Time | m_dot11MeshHWMPnetDiameterTraversalTime |
Time | m_dot11MeshHWMPpreqMinInterval |
Time | m_dot11MeshHWMPperrMinInterval |
Time | m_dot11MeshHWMPactiveRootTimeout |
Time | m_dot11MeshHWMPactivePathTimeout |
Time | m_dot11MeshHWMPpathToRootInterval |
Time | m_dot11MeshHWMPrannInterval |
bool | m_isRoot |
uint8_t | m_maxTtl |
uint8_t | m_unicastPerrThreshold |
uint8_t | m_unicastPreqThreshold |
uint8_t | m_unicastDataThreshold |
bool | m_doFlag |
bool | m_rfFlag |
Hybrid wireless mesh protocol -- a routing protocol of IEEE 802.11s draft.
void ns3::dot11s::HwmpProtocol::DoDispose | ( | ) | [virtual] |
This method is called by Object::Dispose or by the object's destructor, whichever comes first.
Subclasses are expected to implement their real destruction code in an overriden 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.
Reimplemented from ns3::Object.
bool ns3::dot11s::HwmpProtocol::DropDataFrame | ( | uint32_t | seqno, | |
Mac48Address | source | |||
) | [private] |
MAC-plugin asks whether the frame can be dropped. Protocol automatically updates seqno.
seqno | is the sequence number of source | |
source | is the source address |
Mac48Address ns3::dot11s::HwmpProtocol::GetAddress | ( | ) | [private] |
std::vector<Mac48Address> ns3::dot11s::HwmpProtocol::GetBroadcastReceivers | ( | uint32_t | interface | ) | [private] |
std::vector<std::pair<uint32_t, Mac48Address> > ns3::dot11s::HwmpProtocol::GetPerrReceivers | ( | std::vector< FailedDestination > | failedDest | ) | [private] |
std::vector<Mac48Address> ns3::dot11s::HwmpProtocol::GetPreqReceivers | ( | uint32_t | interface | ) | [private] |
static TypeId ns3::dot11s::HwmpProtocol::GetTypeId | ( | void | ) | [static] |
This method returns the TypeId associated to ns3::dot11s::HwmpProtocol.
This object is accessible through the following paths with Config::Set and Config::Connect:
Attributes defined for this type:
No TraceSources defined for this type.
Reimplemented from ns3::MeshL2RoutingProtocol.
bool ns3::dot11s::HwmpProtocol::Install | ( | Ptr< MeshPointDevice > | ) |
Install HWMP on given mesh point.
Installing protocol cause installing its interface MAC plugins.
Also MP aggregates all installed protocols, HWMP protocol can be accessed via MeshPointDevice::GetObject<dot11s::HwmpProtocol>();
PathError ns3::dot11s::HwmpProtocol::MakePathError | ( | std::vector< FailedDestination > | destinations | ) | [private] |
forms a path error information element when list of destination fails on a given interface
void ns3::dot11s::HwmpProtocol::RetryPathDiscovery | ( | Mac48Address | dst, | |
uint8_t | numOfRetry | |||
) | [private] |
Generates PREQ retry when retry timeout has expired and route is still unresolved.
When PREQ retry has achieved the maximum level - retry mechanism should be canceled
void ns3::dot11s::HwmpProtocol::SetNeighboursCallback | ( | Callback< std::vector< Mac48Address >, uint32_t > | cb | ) |
This callback is used to obtain active neighbours on a given interface.
cb | is a callback, which returns a list of addresses on given interface (uint32_t) |
bool ns3::dot11s::HwmpProtocol::ShouldSendPreq | ( | Mac48Address | dst | ) | [private] |
checks when the last path discovery procedure was started for a given destination.
If the retry counter has not achieved the maximum level - preq should not be sent
std::vector<QueuedPacket> ns3::dot11s::HwmpProtocol::m_rqueue [private] |