[ns] help..how to start ns?

2006-02-17 Thread Mohammed Fawaz Kamarudin

hi..
after installing and validate the ns 2allinone 2.18, by using ns lounch, it
had error that ns command not found..what should i do?i run in
mandrake 10.1platform...sorry for ur time..


--
Mohammed Fawaz Kamarudin


[ns] problem with tcl files

2006-03-09 Thread Mohammed Fawaz Kamarudin

hi,
when i try running my aodv.tcl files, some problem occur;

[EMAIL PROTECTED] host tclfiles] $ ns AODV1.tcl
num_nodes is set 50
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
INITIALIZE THE LIST xListHead
Loading connection pattern...
couldn't read file "cbr1": no such file or directory
   while executing
"source.orig cbr1"
   ("uplevel" body line 1)
   invoke from within
"uplevel source.orig [list $fileName]"
   invoke from withn
"if [$instance_is http_url $fileName] {
set buffer [$instance_read url $fileName]
uplevel eval $buffer
} else {
uplevel source.orig [list $fileName]
...
   (procedure "source" line 8)
   invoke from within
"source $opt(cp)"
   (file "AODV1.tcl" line 70)
[EMAIL PROTECTED] host tclfiles] $


the tcl files;


#
# Define options
# ==
set opt(chan)Channel/WirelessChannel
set opt(prop)Propagation/TwoRayGround
set opt(netif)Phy/WirelessPhy
set opt(mac)Mac/802_11
set opt(ifq)Queue/DropTail/PriQueue
set opt(ll)LL
set opt(ant)Antenna/OmniAntenna
set opt(x)1000   ;# X dimension of the topography
set opt(y)1000  ;# Y dimension of the topography
set opt(ifqlen)50  ;# max packet in ifq
set opt(seed)1.0
set opt(tr)traodv1.tr;# trace file
set opt(adhocRouting)   AODV
set opt(nn) 50   ;# how many nodes are simulated
set opt(cp)"cbr1"
set opt(sc)"scen1"
set opt(stop)250.0;# simulation time

#==
# Main Program
# ==
# Initialize Global Variables
# create simulator instance
set ns_[new Simulator]

# set wireless channel, radio-model and topography objects
set wtopo[new Topography]

# create trace object for ns and nam
set tracefd[open $opt(tr) w]
$ns_ trace-all $tracefd
# use new trace file format
#$ns_ use-newtrace

# define topology
$wtopo load_flatgrid $opt(x) $opt(y)

# Create God
set god_ [create-god $opt(nn)]

# define how node should be created
#global node setting
$ns_ node-config -adhocRouting $opt(adhocRouting) \
 -llType $opt(ll) \
 -macType $opt(mac) \
 -ifqType $opt(ifq) \
 -ifqLen $opt(ifqlen) \
 -antType $opt(ant) \
 -propType $opt(prop) \
 -phyType $opt(netif) \
 -channelType $opt(chan) \
 -topoInstance $wtopo \
 -agentTrace ON \
 -routerTrace OFF \
 -macTrace OFF

#  Create the specified number of nodes [$opt(nn)] and "attach" them
#  to the channel.
for {set i 0} {$i < $opt(nn) } {incr i} {
set node_($i) [$ns_ node]
$node_($i) random-motion 0;# disable random motion
}

# Define node movement model
puts "Loading connection pattern..."
source $opt(cp)

# Define traffic model
puts "Loading scenario file..."
source $opt(sc)

# Define node initial position in nam
for {set i 0} {$i < $opt(nn)} {incr i} {

# 20 defines the node size in nam, must adjust it according to your
scenario
# The function must be called after mobility model is defined
   $ns_ initial_node_pos $node_($i) 20
}

# Tell nodes when the simulation ends
for {set i 0} {$i < $opt(nn) } {incr i} {
$ns_ at $opt(stop).1 "$node_($i) reset";
}

# tell nam the simulation stop time
#$ns_ at  $opt(stop)"$ns_ nam-end-wireless $opt(stop)"
$ns_ at  $opt(stop).1 "puts \"NS EXITING...\" ; $ns_ halt"
puts "Starting Simulation..."
$ns_ run


please help me..thank you in advance..

--
Mohammed Fawaz Kamarudin


[ns] help in /ns-allinone-2.29/ns-2.29/indep-utils/cmu-scen-gen/setdest

2006-03-09 Thread Mohammed Fawaz Kamarudin




[ns] help on tora.cc

2006-03-10 Thread Mohammed Fawaz Kamarudin




[ns] Help me in trace files

2006-03-13 Thread Mohammed Fawaz Kamarudin




[ns] problem with .tr files

2006-03-15 Thread Mohammed Fawaz Kamarudin

hi,
my prob is, every time i run eg: xgraph aodv.tr it has many error in each
line and i cannot have the output graph. the error says like:

Error in file `aodv1.tr' at line 64368:
  Unknown line type
Error in file `aodv1.tr' at line 64369:
  Unknown line type
Error in file `aodv1.tr' at line 64370:
  Unknown line type
Problems found with input data.
[EMAIL PROTECTED] aodv1]$

whut should i do? here i attach my aodv.tr. please help me asap.thank you in
advance..

--
Mohammed Fawaz Kamarudin


[ns] Please tell me what the effect of these configuration in AODV simulations.

2006-03-22 Thread Mohammed Fawaz Kamarudin