Re: [ns] how listen the packets???

2008-11-19 Thread Mayur

Douglas Restrepo wrote:

  Hi ns-2 people
 
  Im parsing a simulation, and i can see that, when i.e: the node 0 send a 
  packet in broadcast mode, may be 2 or 3 neighbors listen this packet, but 
  not everyone.
 
  My question is, what happen whit the others nodes.
 
  Why the other nodes don't listen this packet??? what i have to do, to 
  receive this one???
 
 
 1
 
 
 2   3 

 0

45

 
 6
 
 
 
  Thank u
 
 

 

   
As it seems from your topology, all the receivers are within the Rx 
Range of node 0. So, the only reason for this could be : T*hose other 
nodes*' MAC is busy either in Tx or in Rx. So, it is logical and 
realistically correct too.

Mayur




[ns] PL files

2008-11-19 Thread Euna Ferreira

Hi everyone,

Someone knows .pl files in ns, how can i run this file in the simulator or 
convert to .tcl files?

Thanks,

Euna


  Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com

[ns] [NS]: How to change the nodes'Communication range for each node dynamically?

2008-11-19 Thread Renee Azhen

hi, all:
what I mean is that, when the simulator is aready running, but some nodes need 
to change their communication rage, so do you know how to implement this?
thanks
azhen

--- 08年11月20日,周四, Renee Azhen [EMAIL PROTECTED] 写道:
发件人: Renee Azhen [EMAIL PROTECTED]
主题: [NS]: How to change the nodes' RF power/Range when the NS has already 
started?
收件人: ns-users@isi.edu
日期: 2008,1120,周四,12:11上午

dear all,
I want to change some nodes' RF power/Range to minimum  level when the energy 
of these nodes' is low, could you tell me how to implement this??
thanks
azhen




好玩贺卡等你发,邮箱贺卡全新上线!


  ___ 
  好玩贺卡等你发,邮箱贺卡全新上线! 
http://card.mail.cn.yahoo.com/

[ns] help: UMTS EURANE segment fault

2008-11-19 Thread coralyu

?Dear all ns-users,
I've read the paper-Fwd: NS2 EURANE  Evalvid,and I'm tring to run a UMTS 
tcl script which contains the Rayleigh fading between UE and BS, but when I run 
it , I always get the error information: segment fault, I don't know why, and 
while I change Ray_3kmh-700m-200s-UEnr1 to idealtrace , it can run 
successfully. Can you help me? the code follows below. Thank you very much!   
##
global ns
remove-all-packet-headers
add-packet-header MPEG4 MAC_HS RLC LL Mac RTP TCP IP Common Flags

set ns [new Simulator]

set f [open out2ue.tr w]
#$ns trace-all $f


proc finish {} {
global ns
global f
$ns flush-trace
close $f
puts  Simulation ended.
exit 0
}

#$ns set debug_ 0

#$ns set hsdschEnabled_ 1
#$ns set hsdsch_rlc_set_ 0
#$ns set hsdsch_rlc_nif_ 0

$ns node-config -UmtsNodeType rnc

# Node address is 0.
set rnc [$ns create-Umtsnode]

$ns node-config -UmtsNodeType bs \
  -downlinkBW 32kbs \
  -downlinkTTI 10ms \
  -uplinkBW 32kbs \
  -uplinkTTI 10ms \
  -hs_downlinkTTI 2ms \
  -hs_downlinkBW 64kbs \

# Node address is 1.
set bs [$ns create-Umtsnode]

$ns setup-Iub $bs $rnc 622Mbit 622Mbit 15ms 15ms DummyDropTail 2000

$ns node-config -UmtsNodeType ue \
  -baseStation $bs \
  -radioNetworkController $rnc
  
$bs set X_ 100.0
$bs set Y_ 100.0
$bs set Z_ 0.0

# Node address for ue1 and ue2 is 2 and 3, respectively.
set ue1 [$ns create-Umtsnode]
set ue2 [$ns create-Umtsnode]

$ue1 set X_ 800.0
$ue1 set Y_ 100.0
$ue1 set Z_ 0.0

$ue2 set X_ 100.0
$ue2 set Y_ 400.0
$ue2 set Z_ 0.0

# Node address for sgsn0 and ggsn0 is 4 and 5, respectively.
set sgsn0 [$ns node]
set ggsn0 [$ns node]

# Node address for node1 and node2 is 6 and 7, respectively.
set node1 [$ns node]
set node2 [$ns node]

$ns duplex-link $rnc $sgsn0 622Mbit 0.4ms DropTail 1000
$ns duplex-link $sgsn0 $ggsn0 622MBit 10ms DropTail 1000
$ns duplex-link $ggsn0 $node1 10MBit 15ms DropTail 1000
$ns duplex-link $node1 $node2 10MBit 35ms DropTail 1000
#Routing gateway
$rnc add-gateway $sgsn0

#Agent set-up for ue1
set tcp0 [new Agent/TCP]
#$tcp0 set windowInit_ 10
#$tcp0 set window_ 16
#$tcp0 set packetSize_ 512 
$tcp0 set fid_ 0
$tcp0 set prio_ 2

#Agent set-up for ue2
set tcp1 [new Agent/TCP]
$tcp1 set fid_ 1
$tcp1 set prio_ 2

#$ns attach agent to a commonfixed node
$ns attach-agent $node2 $tcp0
$ns attach-agent $node2 $tcp1

#Create and connet two applications to their agent
set ftp0 [new Application/FTP]
$ftp0 attach-agent $tcp0

set ftp1 [new Application/FTP]
$ftp1 attach-agent $tcp1

#Create and attach sinks
set sink0 [new Agent/TCPSink]
$sink0 set fid_ 0
$ns attach-agent $ue1 $sink0

set sink1 [new Agent/TCPSink]
$sink1 set fid_ 1
$ns attach-agent $ue2 $sink1

#Connect sinks to TCP agents
$ns connect $tcp0 $sink0
$ns connect $tcp1 $sink1

$ns node-config -llType UMTS/RLC/AM \
  -downlinkBW 64kbs \
  -uplinkBW 64kbs \
  -downlinkTTI 20ms \
  -uplinkTTI 20ms \
  -hs_downlinkTTI 2ms \
  -hs_downlinkBW 64kbs

#$ns create-hsdsch $ue1 $sink0

#Create HS-DSCH and attach TCP agent for ue1
$ns create-hsdsch $ue1 $sink0

#Attach TCP agent for ue2 to existing HS-DSCH
$ns attach-hsdsch $ue2 $sink1

#Loads input tracefiles for each UE, identified by its fid_
#$bs setErrorTrace 0 UE1 trace file
#$bs setErrorTrace 1 UE2 trace file

#$bs setErrorTrace 0 idealtrace
#$bs setErrorTrace 1 idealtrace

$bs setErrorTrace 0 Ray_3kmh-700m-200s-UEnr1
$bs setErrorTrace 1 Ray_3kmh-300m-200s-UEnr1
$bs loadSnrBlerMatrix SNRBLERMatrix

#set dch0 [$ns create-dch $ue1 $sink0]

#Tracing for all HSDPA traffc in downtarget
$rnc trace-inlink-tcp $f 0
$bs trace-outlink $f 2

#UE1 Tracing 
$ue1 trace-inlink $f 2
$ue1 trace-outlink $f 3
$bs trace-inlink $f 3
$ue1 trace-inlink-tcp $f 2

#UE2 Tracing 
$ue2 trace-inlink $f 2
$ue2 trace-outlink $f 3
$bs trace-inlink $f 4
$ue2 trace-inlink-tcp $f 2

# sample the bottleneck queue every 0.1 sec. store the trace in qm.out
#set qmon [$ns monitor-queue $rnc $bs [open qwire.out w] 0.1];
#[$ns link $rnc $bs] queue-sample-timeout; # [$ns link $n2 $n3] start-tracing

$ns at 0.0 $ftp0 start
$ns at 0.002 $ftp1 start
$ns at 10.1 $ftp0 stop
$ns at 10.102 $ftp1 stop
$ns at 10.201 finish

puts  Simulation is running ... please wait ...
$ns run