[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ns] color prolem
Hi, dear all:
My problem is I can not set the color for packets correctly. I have
looked through ns-manual and some previous related questions, I still do
not know why it does not work correctly in my case. the below is a simple
example using centralized multicast:
$ns color 0 blue
$ns color 1 green
set udp [new Agent/UDP]
$ns attach-agent $n($startnode) $udp
set src [new Application/Traffic/CBR]
$src set packetSize_ 500
$src set interval_ 0.005
$src set packetSize_ 536
$src attach-agent $udp
$ns at 0.5 "$src start"
$udp set dst_addr_ $group
$udp set dst_port_ 1
$udp set fid_ 1
$n($startnode) color red
$n($startnode) shape square
there are also many receivers in this group. I saw all packets' color is
blue, but when a node drops packets, some of packets are blue, some are
green.
any suggestion?
thank you
Sencun