diff --git a/src/routing/aodv/aodv-routing-protocol.cc b/src/routing/aodv/aodv-routing-protocol.cc index d0a2c0234..6be930a69 100644 --- a/src/routing/aodv/aodv-routing-protocol.cc +++ b/src/routing/aodv/aodv-routing-protocol.cc @@ -104,14 +104,45 @@ RoutingProtocol::GetTypeId (void) TimeValue (MilliSeconds (40)), MakeTimeAccessor (&RoutingProtocol::NodeTraversalTime), MakeTimeChecker ()) + .AddAttribute ("NextHopWait", "Period of our waiting for the neighbour's RREP_ACK = 10 ms + NodeTraversalTime", + TimeValue (MilliSeconds (50)), + MakeTimeAccessor (&RoutingProtocol::NextHopWait), + MakeTimeChecker ()) .AddAttribute ("ActiveRouteTimeout", "Period of time during which the route is considered to be valid", TimeValue (Seconds (3)), MakeTimeAccessor (&RoutingProtocol::ActiveRouteTimeout), MakeTimeChecker ()) + .AddAttribute ("MyRouteTimeout", "Value of lifetime field in RREP generating by this node = 2 * max(ActiveRouteTimeout, PathDiscoveryTime)", + TimeValue (Seconds (11.2)), + MakeTimeAccessor (&RoutingProtocol::MyRouteTimeout), + MakeTimeChecker ()) + .AddAttribute ("BlackListTimeout", "Time for which the node is put into the blacklist = RreqRetries * NetTraversalTime", + TimeValue (Seconds (5.6)), + MakeTimeAccessor (&RoutingProtocol::BlackListTimeout), + MakeTimeChecker ()) + .AddAttribute ("DeletePeriod", "DeletePeriod is intended to provide an upper bound on the time for which an upstream node A " + "can have a neighbor B as an active next hop for destination D, while B has invalidated the route to D." + " = 5 * max (HelloInterval, ActiveRouteTimeout)", + TimeValue (Seconds (15)), + MakeTimeAccessor (&RoutingProtocol::DeletePeriod), + MakeTimeChecker ()) + .AddAttribute ("TimeoutBuffer", "Its purpose is to provide a buffer for the timeout so that if the RREP is delayed" + " due to congestion, a timeout is less likely to occur while the RREP is still en route back to the source.", + UintegerValue (2), + MakeUintegerAccessor (&RoutingProtocol::TimeoutBuffer), + MakeUintegerChecker ()) .AddAttribute ("NetDiameter", "Net diameter measures the maximum possible number of hops between two nodes in the network", UintegerValue (35), MakeUintegerAccessor (&RoutingProtocol::NetDiameter), MakeUintegerChecker ()) + .AddAttribute ("NetTraversalTime", "Estimate of the average net traversal time = 2 * NodeTraversalTime * NetDiameter", + TimeValue (Seconds (2.8)), + MakeTimeAccessor (&RoutingProtocol::NetTraversalTime), + MakeTimeChecker ()) + .AddAttribute ("PathDiscoveryTime", "Estimate of maximum time needed to find route in network = 2 * NetTraversalTime", + TimeValue (Seconds (5.6)), + MakeTimeAccessor (&RoutingProtocol::PathDiscoveryTime), + MakeTimeChecker ()) .AddAttribute ("MaxQueueLen", "Maximum number of packets that we allow a routing protocol to buffer.", UintegerValue (64), MakeUintegerAccessor (&RoutingProtocol::MaxQueueLen), diff --git a/src/routing/aodv/aodv-routing-protocol.h b/src/routing/aodv/aodv-routing-protocol.h index 2c83cd01e..5ff281bb0 100644 --- a/src/routing/aodv/aodv-routing-protocol.h +++ b/src/routing/aodv/aodv-routing-protocol.h @@ -87,7 +87,7 @@ private: //\{ uint32_t RreqRetries; ///< Maximum number of retransmissions of RREQ with TTL = NetDiameter to discover a route uint16_t RreqRateLimit; ///< Maximum number of RREQ per second. - Time ActiveRouteTimeout; ///< Minimal lifetime for active route. + Time ActiveRouteTimeout; ///< Period of time during which the route is considered to be valid. uint32_t NetDiameter; ///< Net diameter measures the maximum possible number of hops between two nodes in the network /** * NodeTraversalTime is a conservative estimate of the average one hop traversal time for packets @@ -95,8 +95,8 @@ private: */ Time NodeTraversalTime; Time NetTraversalTime; ///< Estimate of the average net traversal time. - Time PathDiscoveryTime; ///< Estimate of maximum time needed to find route in network - Time MyRouteTimeout; ///< Value of lifetime field in RREP generating by this node + Time PathDiscoveryTime; ///< Estimate of maximum time needed to find route in network. + Time MyRouteTimeout; ///< Value of lifetime field in RREP generating by this node. /** * Every HelloInterval the node checks whether it has sent a broadcast within the last HelloInterval. * If it has not, it MAY broadcast a Hello message