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

[ns] [Q] About SRMErrorModel



Dear NS-users

I have two simple question about SRM.
First.. about SRMErrorModel
In ns 2.1b5, this code below works well but why didn't it work in ns 2.1b6??
I just wanted to make 2 congestion link.. but, it only drops the packets between node 6 and node 7.
Is anything wrong in this code??

i#############
set loss_module [new SRMErrorModel]  
$loss_module drop-packet 2 7 5   
$loss_module drop-target [$ns set nullAgent_] 
$ns at 1.5 "$ns lossmodel $loss_module $n(6) $n(7)"

#set loss_module1 [new SRMErrorModel]
#$loss_module1 drop-packet 2 11 5 
#$loss_module1 drop-target [$ns set nullAgent_]
#$ns at 2.0 "$ns lossmodel $loss_module1 $n(27) $n(37)"
##############

Second, I thought I can change the TTL value of the packet
by using the variable defttl_. 
So, I assigned 5 to defttl_, but the packet is still transmitted to the whole group.
Is there any way to change the TTL value??

Thanks in advance..