>Date: Wed, 11 May 2011 13:47:44 -0700 (PDT)
>From: s s <[email protected]>
>Subject: [ns] dont understand some codes
>To: ns <[email protected]>
>Message-ID: <[email protected]>
>Content-Type: text/plain; charset=us-ascii

>In the name of God
>Hi Dear Friends

>I read some script and i face to some new codes that i have not any idea about 
>them can u help me:
>$sensoragent_($i) is-source
>$sensoragent_($i) data-start-time [ $rng uniform 0.0 1.0]
>$sensoragent_($i) data-interval $val(datainterval)
>$sensoragent_($i) hello-period $val(helloperiod)
>$sensoragent_($i) upstream-update-period $val(upstreamupdateperiod)

>Best Regards
>sarah


The codes above show that sensoragent_($i) is calling 5 different functions in 
Tcl script and passing argument to that function.....

You should check that in the ns-2 Tcl script regarding 

sensoragent instproc is-source
sensoragent instproc data-start-time {args}
sensoragent instproc data-interval {args}
sensoragent instproc hello-period {args}
sensoragent instproc upstream-update-period {args}

[ $rng uniform 0.0 1.0] means that it will generate random number using uniform 
distribution..... the square braces [ ] means that its a command Tcl line...

I think the $val(args) is a constant variable in your script....you can check 
that too....

Reply via email to