[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ns] Problems with LAN
I made a small tcl file with two nodes to check the LAN simulation.
the file is:
tmp.tcl:
#Create a simulator object
set ns [new Simulator]
set f [open trace.1 w]
$ns trace-all $f
proc finish {} {
global ns f
close $f
}
#Create two nodes
set n0 [$ns node]
set n1 [$ns node]
#Create a duplex link between the nodes
#$ns duplex-link $n0 $n1 1Mb 10ms DropTail
set lan[$ns make-lan "$n0 $n1" 1Mb 10ms LL Queue/DropTail Mac/Csma/Cd]
#Call the finish procedure after 5 seconds of simulation time
$ns at 5.0 "finish"
#Run the simulation
$ns run
I am getting compilation problems:
_o14: unable to dispatch method init-vars
while executing
"_o14 init-vars -bw 1Mb -delay 10ms -llType LL -ifqType Queue/DropTail
-macType Mac/Csma/Cd -chanType Channel"
("eval" body line 1)
invoked from within
"eval $self init-vars $args"
(procedure "_o14" line 2)
(LanNode init line 2)
invoked from within
"_o14 init _o3 -bw 1Mb -delay 10ms -llType LL -ifqType Queue/DropTail
-macType Mac/Csma/Cd -chanType Channel"
(Class create line 1)
invoked from within
"LanNode create _o14 _o3 -bw 1Mb -delay 10ms -llType LL -ifqType
Queue/DropTail -macType Mac/Csma/Cd -chanType Channel"
invoked from within
"catch "$className create $o $args" msg"
(procedure "new" line 3)
invoked from within
"new LanNode $self -bw $bw -delay $delay -llType $llType -ifqType
$ifqType -macType $macType -chanType $chanType"
(procedure "_o3" line 2)
(Simulator make-lan line 2)
invoked from within
"$ns make-lan "$n0 $n1" 1Mb 10ms LL Queue/DropTail Mac/Csma/Cd"
(file "tmp.tcl" line 25)
Even simple simulation is not able to run.
Will very much thankful if get the solution.
seema.
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
Ms. Seema T. Jadhav. |Phone:
Research Engg. |Driect line to IIT: 5782545
Department of Electrical Engg. |Information Networks Lab
IIT, Bombay |Ext: 5736,5738.
Powai, 400076. |Email: [email protected]
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------