[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ns] Calculate link bandwidth in C++




Hi,

I want to get the bandwidth of some link in C++
however the following instproc failed.
(Called by evalf(), it always returns 1000.)
Would you like to tell me how to do that?
Thanks,

Lee

SimpleLink instproc bandwidth? {} {
	$self instvar bandwidth_
	if ![info exists bandwidth_] {
		set bandwidth_ 1000
	}
	set bandwidth_
}

Link is created using
$ns duplex-link $src $dst $bw $delay DropTail