hey,
you can generate scenario file with specified pause time and mobility and
can call that scenario file directly in your tcl script.
Follow the steps below:

  Steps for creating scenario files for mobility simulations :

1. Go to ns directory and run "configure" (you probably have done that
already while building ns). This creates a makefile for setdest.

2.Go to indep-utils/cmu-scen-gen/setdest. Run "make" , which first creates
a stand-alone object file for ~ns/rng.cc (the stand-alone version doesnot
use Tclcl libs) and then creates the executable setdest.

3. Run setdest with arguments as shown below: ./setdest [-v version of
setdest; 1 for original 1999 CMU version or 2 for modified 2003
U.Michigan version ] [-n num_of_nodes] [-p pausetime] [-s maxspeed]
[-t simtime] [-x maxx] [-y maxy] > [outdir/movement-file]

Example: ./setdest -v 1 -n 20 -p 2.0 -s 10.0 -t 200 -x 500 -y 500 >
scen-20-test
and the output will be written in a file called scen-20-test.

4a. OR run make-scen.csh to generate multiple scenario files.


On Fri, Jul 29, 2011 at 5:30 AM, <ns-users-requ...@isi.edu> wrote:

> Send Ns-users mailing list submissions to
>        ns-users@isi.edu
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://mailman.isi.edu/mailman/listinfo/ns-users
> or, via email, send a message with subject or body 'help' to
>        ns-users-requ...@isi.edu
>
> You can reach the person managing the list at
>        ns-users-ow...@isi.edu
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Ns-users digest..."
>
>
> Today's Topics:
>
>   1. awk fille for calculating pdr, avg end to end delay,      and
>      throughput (sumit singh)
>   2. How to to set the pause time of node in TCL script (Wei Zhang)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Thu, 28 Jul 2011 17:22:34 +0530
> From: sumit singh <tech.sumitsi...@gmail.com>
> Subject: [ns] awk fille for calculating pdr, avg end to end delay,      and
>        throughput
> To: ns-users@isi.edu
> Message-ID:
>        <CADZsg+PPx7ufrdvvgRMWeaHpb26rYy+3O_=jxpuootm5m3y...@mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> Hey, Please anybody send me the awk file for calculating average end to end
> delay, throughput and packet delivery ratio for analyzing dsr trace file.
> I have downloaded some awk files from internet but it show segmentation
> fault with dsr trace file. But it works fine with AODV trace file.
> thanxs  in advance.
>
> --
> best regards,
> Sumit Kumar Singh.
>
>
> ------------------------------
>
> Message: 2
> Date: Thu, 28 Jul 2011 14:08:00 +0100 (BST)
> From: Wei Zhang <weizhang...@yahoo.com>
> Subject: [ns] How to to set the pause time of node in TCL script
> To: ns-users@isi.edu
> Message-ID:
>        <1311858480.86385.yahoomailclas...@web29302.mail.ird.yahoo.com>
> Content-Type: text/plain; charset=utf-8
>
> Hello All,
>
>
>
> I would like you help me to set the pause time of node in TCL script.
>
>
>
>
>
> I try the following code but it has error: setdest ?n <num
> nodes> ?p <pause time> ?s <speed> ?t <Time> ?x
> <x> ?y <y>
>
>
>
>
>
> I can only set the speed and coordinate and it is ok:
>
>
>
>
>
> $ns_ at 10 "$node_(0) setdest? 300 680 5"
>
>
>
>
>
> Please help me soon.
>
>
>
>
>
> Thank you in advance.
>
>
>
>
>
> Wei
>
>
>
>
> ------------------------------
>
> _______________________________________________
> Ns-users mailing list
> Ns-users@isi.edu
> http://mailman.isi.edu/mailman/listinfo/ns-users
>
>
> End of Ns-users Digest, Vol 91, Issue 27
> ****************************************
>



-- 
with regards,
Sumit Kumar Singh.

Reply via email to