[ns] An extension of AODV in ns-2.31
Kiraneet sharma
kiraneet.sharma at gmail.com
Sat Mar 21 07:18:25 PDT 2009
Respected brothers/sisters,
I am a begineer in ns-2.
Currently I am working over a mini project where I am implemeting the paper
"A Semi-Proactive AODV Routing Protocol for Wireless Networks",
(2008 International Conference on Advanced Computer Theory and Engineering)
I had to make quite a few changes in AODV protocol,but I have got stuck over
some
1. I have added a counter field, min_thr(threshold) and max_thr in
class aodv_rt_entry {
friend class aodv_rtable;
friend class AODV;
...
...
double rt_expire; // when entry expires
u_int8_t rt_flags;
int counter;
int minthr;
int maxthr;
...
...
}
Now these have to be initialized as
min_threshold=no of neighbors
max_threshold=2*min_threshold.
Q: How do I use the AODV_Neighbor class/nb_list to initialize these values
?
2. Whenever a node receives a RERR message for each unreachable destination
included in the
packet, the node determines whether the source node forwarding the RERR
packet is the next hop used to
reach that destination. It then checks the Counter value for this entry
is above
Min_Threshold, if so, the node will initiate a RREQ with the
value one.
So it updates it's table only, and forward it to find a new route
to that destination.other
intermediate nodes receive this RREQ, they will not
increment the Counter value for this entry in their and just reply
back with an available route to this destination
For this I have made changes in aodv.cc
void AODV::rt_resolve(Packet *p) {
struct hdr_cmn *ch = HDR_CMN(p);
struct hdr_ip *ih = HDR_IP(p);
aodv_rt_entry *rt;
...
...
/*
* I am trying to forward a packet for someone else to which
* I don't have a route.
*/
else {
Packet *rerr = Packet::alloc();
struct hdr_aodv_error *re = HDR_AODV_ERROR(rerr);
/*
* For now, drop the packet and send error upstream.
* Now the route errors are broadcast to upstream
* neighbors - Mahesh 09/11/99
*/
if(rt->counter>rt->minthr)
{
sendRequest(rt->rt_dst,1);
}
else
{
assert (rt->rt_flags == RTF_DOWN);
re->DestCount = 0;
...
...
}
}
Is this the correct function to be changed for this purpose?
I have changed the prototype and definition od sendRequest function too.
3. The Counter field of the route entry is checked before deletion(i.e.
after it has
crossed it's LIFETIME period).
If the Counter<MinTH, the node will delete the route entry, otherwise,
the node will decrement the Counter value by one and update the Lifetime
for the route table entry to the
current time plus ACTIVE_ROUTE_TIMEOUT
For this where do I have to make the changes
Is it void AODV::rt_purge() in aodv.cc
If yes where exactly?
Thanks a ton for devotion precious moments of your life
over my problem.
Expcting your co=operation and timely reply.
Loads of wishes
Kiraneet.
More information about the Ns-users
mailing list