

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


================================================================ set val(chan) Channel/WirelessChannel ;# channel type set val(prop) Propagation/TwoRayGround ;# radio-propagation model set val(netif) Phy/WirelessPhy ;# network interface type set val(mac) Mac/802_11 ;# MAC type set val(ifq) Queue/DropTail/PriQueue ;# interface queue type set val(ll) LL ;# link layer type set val(ant) Antenna/OmniAntenna ;# antenna model set val(ifqlen) 50 ;# max packet in ifq set val(nn) 20 ;# number of mobilenodes set val(rp) DSDV ;# routing protocol set val(x) 500 ;# Size of topology in X axis set val(y) 500 ;# Size of topology in Y axis set val(scenario) "tao-20" ;# Scenario file
………………..
set udp1 [new Agent/UDP] $ns_ attach-agent $node_(1) $udp $udp1 set class_ 2 $udp1 set fid_ 2 set cbr1 [new Application/Traffic/CBR] $cbr1 attach-agent $udp $cbr1 set packetSize_ 1000 $cbr1 set interval_ 0.
set mon1 [new Agent/LossMonitor] $ns_ attach-agent $node_(10) $mon $ns_ connect $udp1 $mon