[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ns] Please help me
Hello, all:
Since no one answered my question, I hope this one will get some
responce from you guys. Thank you in advance!
I am doing simulation with SRM. The question is how I can dynamically
join or leave a multicast group using SRM agents. I ran the example:
/tcl/ex/srm-chain.tcl which is okay . some sentences are like below from
that file.
set srm($i) [new Agent/SRM/$srmSimType]
$srm($i) set dst_addr_ $group
$srm($i) set dst_port_ 0
$srm($i) set fid_ [incr fid]
$srm($i) trace $srmEvents
$srm($i) log $srmStats
$ns at 1.0 "$srm($i) start"
$ns attach-agent $n($i) $srm($i)
--------------------------------------
now the question is how a srm agent leave the group, and join again.
I tried:
$ns at 2.0 "$n(2) leave-group $srm(2) $group"
find srm(2) is still sending session message to the group after that.
so what is the graceful way to do that?
thank you for any hints
Sencun