run-span.pl
来自「ns 2.28 下 SPAN节能协议源码」· PL 代码 · 共 19 行
PL
19 行
#!/usr/bin/perl$nsdir = "$ENV{HOME}/ns-allinone-2.28/ns-2.28";$scen = $ARGV[0];shift @ARGV;$args = join(" ", @ARGV);$tag = join("-", @ARGV);$ns = "$nsdir/ns";$rs = "$nsdir/tcl/ex/run-2Mb.tcl";$md = "$nsdir/tcl/mobility/span.tcl";# Can't get the $scen stuff to work right, just hardcoding the names for now# system("tcsh -c \"cd $nsdir > /dev/null; ($ns $rs -sc $scen -rp $md -usepsm 1 -spanopt 0 -usespan 0 -tr /tmp/$scen$tag-psm.tr $args >! /tmp/$scen$tag-psm.stdout)>&! /tmp/$scen$tag-psm.out\"");system("tcsh -c \"cd $nsdir > /dev/null; ($ns $rs -sc $scen -rp $md -usepsm 1 -spanopt 0 -usespan 1 -tr /tmp/span.tr $args >! /tmp/span.stdout)>&! /tmp/span.out\"");
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?