How to get time of packet received by node

84 views
Skip to first unread message

deepak jeswani

unread,
Apr 6, 2010, 3:36:50 AM4/6/10
to ns-...@googlegroups.com
Hi,

I want to get time when a node receive a packet for first time. that is i have 2 nodes (wireless, not in range right now) in my simulator and they have TCP connection in between them. So i want to get time when my node 2 will get packet from node one.
Can anyone please tell me that.

Thanks

Regards
deepak

Mohit P. Tahiliani

unread,
Apr 8, 2010, 12:14:21 AM4/8/10
to Network Simulator - 2 (NS-2)
Hello Deepak,

To know about the receive time of a packet, you need to extract the
information from trace file.

This can be done by using either AWK Scripts or MATLAB or PERL
Scripts.

AWK scripts are available on my blog: www.mohittahiliani.blogspot.com

However you may not find an AWK script which gives you the exact
information regarding receive time of a packet.

You can use AWK script designed for average end-to-end delay because
we need send time and receive time to calculate delay.

If you have any doubts in understanding AWK script, please feel free
to mail me.

Hope it helps.

Regards,
Mohit P. Tahiliani

On Apr 6, 12:36 pm, deepak jeswani <jeswanideepak1...@gmail.com>
wrote:

deepak jeswani

unread,
Apr 8, 2010, 11:02:16 AM4/8/10
to ns-...@googlegroups.com
Sir,

NO actually i want that time while simulation is going on so that i can trigger other things on its basis. So what i want exactly is that when a mobile node (node 1) comes in range of a node (node 2) than that node (node 2) should send a packet to another node (node 3) that mobile node (node 1) is in my range (packet can be simple ftp over tcp just to act like it is telling other node this info). So please now help me out if you can. Please hurry. 

Thanks

--
You received this message because you are subscribed to the Google Groups "Network Simulator - 2 (NS-2)" group.
To post to this group, send an email to ns-...@googlegroups.com.
To unsubscribe from this group, send email to ns-user+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/ns-user?hl=en-GB.


Reply all
Reply to author
Forward
0 new messages