Subject: Re: [manet] How to change de Active Route Timeout in AODV

From: Manel Guerrero <[email-masked]>
Date: Thu, 14 Oct 2004 12:24:21 +0200

Hi Xavier :)

Xavier M. wrote:

 > Hi all,
 >
 > I would like to know how to change the ACTIVE ROUTE TIMEOUT parameter in the tcl script for using it in a ns-2 simulation. I am using the AODV routing protocol. What is the default value? is it 3? what other values can be set?

In the file 'ns-2.27/aodv/aodv.h'
     line 79 you have the '#define':

8<--------
#define ACTIVE_ROUTE_TIMEOUT    10                // 50 seconds
-------->8

So the default value is 10 seconds (ignore the comment at the end of the line).

You can set a different value just by replacing the '10' for whatever number
of seconds you preffer. (And then recompile the thing).

I don't know if there is a way to do it without changing the source code.
A fast search sugests that there is no other way:

8<--------
foobar/ns-2.27/aodv$ fgrep "ACTIVE_ROUTE_TIMEOUT" *
aodv.cc:     // Set expiry time to CURRENT_TIME + ACTIVE_ROUTE_TIMEOUT
aodv.cc:       rt0->rt_expire = CURRENT_TIME + ACTIVE_ROUTE_TIMEOUT;
aodv.cc:   rt->rt_expire = CURRENT_TIME + ACTIVE_ROUTE_TIMEOUT;
aodv.h:#define ACTIVE_ROUTE_TIMEOUT    10                               // 50 seconds
foobar/ns-2.27/aodv$
-------->8

Hope this helps ;)

     Manel

P.D.: I didn't know telefonica was working on this ;)

 > I am using the ns-allinone2.27 package and I don't know whether it can be done directly with tcl or not.
 >
 >
 >
 > thank you for your help
 >
 > Xavier M.
 >
 > _______________________________________________
 > manet mailing list
 > [email-masked]
 > https://www1.ietf.org/mailman/listinfo/manet

_______________________________________________
manet mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/manet

---

From: [email-masked]
Date: Thu, 14 Oct 2004 09:29:16 -0700 (MST)

Hi,

You can change it in the tcl script too.
In AODV.cc, bind the variable using   
bind("actrttout",&ACTIVE_ROUTE_TIMEOUT);
and in the tcl file use

Agent/AODV set actrttout $opt(val)

where $opt(val) is the actual value.

Hope this helps

Thanks
Kiran Vadde

>      line 79 you have the '#define':

Kiran Vadde
Graduate Research Associate
Dept. of Computer Science and Eng.
Arizona State University

---

From: "Xavier Marchador" <[email-masked]>
Date: Fri, 15 Oct 2004 00:02:25 +0200

Hi all,

I'll try this too. By the way, what is bind? it's a function? a C++ command?
I've never used it before.

thanks

Xavi

----- Original Message ----- 
From: <[email-masked]>
To: "Manel Guerrero" <[email-masked]>
Cc: <[email-masked]>
Sent: Thursday, October 14, 2004 6:29 PM
Subject: Re: [manet] How to change de Active Route Timeout in AODV

> >  > I would like to know how to change the ACTIVE ROUTE TIMEOUT parameter
in the tcl script for using it in a ns-2 simulation. I am using the AODV
routing protocol. What is the default value? is it 3? what other values can
be set?