----- Forwarded Message -----
From: itishi saxena <itish...@yahoo.com>
To: Durgesh Kshirsagar <durgeshpkshirsa...@gmail.com>; "ns-users@ISI.EDU" 
<ns-users@ISI.EDU> 
Sent: Tuesday, 14 August 2012 2:54 PM
Subject: [ns] [SOLVED] Re:  The results of your email commands
 

Thanks Durgesh, I found the answer.

Inside queue.cc, we have recv function, for each packet received....we can 
check either packet at the destination node by checking
if (ih->daddr()=ch->next_hop_)
then apply your mechanism to control over those packets.

Thanks to all



________________________________
From: Durgesh Kshirsagar <durgeshpkshirsa...@gmail.com>
To: itishi saxena <itish...@yahoo.com> 
Sent: Tuesday, 14 August 2012 2:42 PM
Subject: Re: [ns] The results of your email commands


Hello itishi, there is a variable named "index" you can make use of it to get 
current node. e.g suppose I want to that a node with id 1 should print 
statement "I am node 1" u can use

if(index==1)
fprintf(stderr, "I am node 1");


I am using fprintf because I don't know any other mehod.

I am also working on AODV currently. I will advice you to use Eclipse for 
development because u can easily debug and very fast development. 
Check out my blog for using eclipse
http://durgeshkshirsagar.blogspot.in/2012/06/how-to-set-eclipse-for-ns-2-234-in.html

All the best!

Reply via email to