[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ns] nodeid of packet
Hi all,
I want to count the number of packets that originate from a particular
node or a set of nodes in a WAN that I have created. I would like to do
this at the TCPSink as I am running TCP based simulations. The pointer
to a packet does not contain this information as far as I know.
I have tried adding a variable to the Packet class in packet.h and tried
to assign the nodeid from the arriving packet at various places (ip.cc,
mac.cc, channel.cc ...) but am not able to do so.
When I try printing the variable in the ns script it always prints the
default value that I have given in ns-default.tcl
How can I find the node from which a particular packet has originated
???
Thanks ,
Nandkishore.