[ns] How to calculate goodput

2007-04-12 Thread Yashesh Mankad

Hi,

I am running a few simulations on wireless networks having 3-4 nodes. I have an 
idea about throughput calculation, but how do I calculate the GOODPUT at a 
certain node??

If possible, please tell me the file that I am supposed to modify along with 
the modification.

Thanks.
Yashesh
   
-
 Check out what you're missing if you're not on Yahoo! Messenger 


Re: [ns] how to pass PHY layer information to upper layers?

2007-04-12 Thread Daniel Mahrenholz

sri_seeta_ram schrieb:
 I want to pass the Received Power of the packet from PHY layer to the
 protocol agent.
 how can i achieve this in ns2?

 I found the Received power in wirelessphy.cc and mac-802_11.cc i.e PHY and
 MAC layers.
 how can i pass this info to LL and then Routing agent...?
   
A Packet in ns2 contains all configured headers in parallel. So, if you 
can access information on one layer (e.g. PHY), you can also access it 
on other layers. If the information is not contained in a header you 
need to add a new header to the packet structure. In this header you can 
store your information and pass it around.

Daniel.

-- 
Dr.-Ing. Daniel Mahrenholz
rt-solutions.de GmbH
Oberländer Ufer 190a
D-50968 Köln

Web: www.rt-solutions.de

rt-solutions.de
networks you can trust.




[ns] problem with wireless communications

2007-04-12 Thread julien . thomas

Hi ns2 users.

I try to exchange data in wireless environnement.

However, I'm not able to use routing informations : nodes that are in  
antennas range are
able to exchange informations, but when I have the following scheme  
(for communication
range, I mean)
A - B
B - C (and not A -C), A and C are not able to exchange informations.

Does anyone knows how to exchange these informations ? As I use the  
same principle as in
the ping application (which means : using the send() function), I am  
supposed to think
that I do it on the right way, but maybe I'm wrong ?

I put here an extract of my tcl file (which the minimum lines ...)

Thanks.

Julien Thomas

# ==
# Define options
# ==
set opt(chan)   Channel/WirelessChannel  ;# channel type
set opt(prop)   Propagation/TwoRayGround ;# radio-propagation model
set opt(netif)  Phy/WirelessPhy  ;# network interface type
set opt(mac)Mac/802_11   ;# MAC type
set opt(ifq)Queue/DropTail/PriQueue  ;# interface queue type
set opt(ll) LL   ;# link layer type
set opt(ant)Antenna/OmniAntenna  ;# antenna model
set opt(ifqlen) 50   ;# max packet in ifq
set opt(nn) 3;# number of mobilenodes
set opt(adhocRouting)   OLSR ;# routing protocol
set opt(cp) ;  
#~/bin/ns-2/ns-2.31/tcl/mobility/scene/cbr-3-test  ; #
connection pattern file
set opt(sc) ;  
#~/bin/ns-2/ns-2.31/tcl/mobility/scene/scen-3-test ; # node
movement file.

set opt(x)  400  ;# x coordinate of topology
set opt(y)  600  ;# y coordinate of topology
set opt(seed)   0.0  ;# seed for random  
number gen.
set opt(stop)   1000   ;# time to stop  
simulation

# 

#
# check for random seed
#
if {$opt(seed)  0} {
 puts Seeding Random number generator with $opt(seed)\n
 ns-random $opt(seed)
}

#
# create simulator instance
#
set ns_ [new Simulator]

#
# define topology
#
$topo load_flatgrid $opt(x) $opt(y)

#
# create God
#
create-god $opt(nn)


set chan_1_ [new $opt(chan)]

#
# configure mobile nodes
#
$ns_ node-config -adhocRouting $opt(adhocRouting) \
  -llType $opt(ll) \
  -macType $opt(mac) \
  -ifqType $opt(ifq) \
  -ifqLen $opt(ifqlen) \
  -antType $opt(ant) \
  -propType $opt(prop) \
  -phyType $opt(netif) \
  -topoInstance $topo \
  -wiredRouting OFF \
  -agentTrace ON \
  -routerTrace ON \
  -macTrace OFF \
-channel $chan_1_
 #-channelType $opt(chan) \

#create nodes
#attach OLSRRep agents

for {set i 0} {$i  $opt(nn)} {incr i} {
 set node_($i) [$ns_ node]
 set olsrRAgent($i) [new Agent/OLSRRep]
 set udp_($i) [new Agent/UDP]
 $node_($i) random-motion 0 ;# disable random motion
 $ns_ attach-agent $node_($i)  $olsrRAgent($i)
}

#
# positions
#
$node_(0) set X_ 150.0
$node_(0) set Y_ 200.0
$node_(0) set Z_ 0.0

$node_(1) set X_ 320.0
$node_(1) set Y_ 200.0
$node_(1) set Z_ 0.0

$node_(2) set X_ 500.0
$node_(2) set Y_ 200.0
$node_(2) set Z_ 0.0

for {set i 0} {$i  $opt(nn)} {incr i} {
   $ns_ at $opt(stop).0001  $olsrRAgent($i) finaldisplay
}

#
# NS-2 management
#
for {set i 0} {$i  $opt(nn) } {incr i} {

 $ns_ at $opt(stop).0 $node_($i) reset;
}

puts Starting Simulation...
$ns_ run
Supprimer | Répondre | Répondre à tous | Transfert | Rediriger | Voir  
les Enfilades | Sou




[ns] About DSR Packets

2007-04-12 Thread Jezabel Miriam Molina Gil

Hi,
Someone Know where are created the DSR packets which are represented
by a wave around the nodes at the begining of sending DSR packets?

Thanks a lot

-- 
Saludos
Jezabel M. Molina Gil



[ns] problem with promiscuous mode

2007-04-12 Thread [EMAIL PROTECTED]

Hi All

I have taken a look to the link:
http://www.cse.msu.edu/~wangbo1/ns2/nshowto1.html

where is explained how to use Promiscuous mode in AODV, but 
I can't understand what I must put in the section:

void
AODV::tap(const Packet *p) {

// put your code here

} 

I must monitoring RREP forwarding. 
Can someone of you help me please?

Best regards,

G 


--
Leggi GRATIS le tue mail con il telefonino i-mode™ di Wind
http://i-mode.wind.it/





[ns] Annotation in Nam from C++

2007-04-12 Thread Jezabel Miriam Molina Gil

Hello,
Someon know how Can I annotate something from C++ to NAM?
I know that for trace it is trace(comething); but what about nam?

thanks

-- 
Saludos
Jezabel M. Molina Gil



[ns] How to find th enumber of RRER packets

2007-04-12 Thread Satish B

Hii everyone,
I want to know how to count
-- number of RRER packets on DATA path
-- number of RRER packets on ACK path.
Thank you.


[ns] do anyone have the perl file to calculate the end to end delay on UE?

2007-04-12 Thread john unkle

DEAR ALL
do anyone have the perl file to calculate the end to end delay on UE?
can anyone help me?
thank you
_
Messenger 的 PC - to - PC 直接對話功能,跟海外親友免費講長途電話,慳錢方便 — Messenger PC - to - PC 直接對話 
http://get.live.com/messenger/features 

Re: [ns] queue connection

2007-04-12 Thread Song Luo

Because I have been coding for an aodv-based module for a while, I think I
can answer your question regarding aodv.

There are two queues can store packets: routing queue, and interface queue.
After an application generates a packet, it will be sent to routing agent
(aodv here). If the routing agent finds a route for this packet, it is
passed to the interface queue immediately. If the interface queue is full
now, it will be dropped and written to the trace file. On the other hand, if
the routing agent cannot find a route for this packet, it will store it in
the routing queue temporarily. If the routing queue is full (because your
application is generating packets too fast), the packet will be dropped and
written to the trace file. The packets in routing queue may have two
different results: if a route if finally found, the packet goes to the
interface queue; if the route cannot be found for a specific time, the
packet gets aged and finally purged (removed from routing queue). In this
case, no trace will be written.

Check files in ./queue and ./mac for detail implementation of routing queues
and mac interface queue. Please correct me if I am wrong.

Song Luo

On 4/11/07, suhaib obeidat [EMAIL PROTECTED] wrote:


 Dear All,

 When a source is generating traffic faster than they can be transmitted.
 Where are these packets stored ? Is it in the LL or somewhere else. To
 make
 my question more specific, I would like to constantly know the fill level
 of
 this buffer/queue.

 Please, do not spare typing couple of sentences if you know, I really need
 this.

 Thanks



[ns] include file error

2007-04-12 Thread juan manuel gomez garcia

hi ns-users:

It is very simple: Before doing anything, everything works well.
Later I only do: #include wpan/p802_15_4mac.h  in aodv.h file. And when I 
do make clean, make, I obtain the errors:

In file included from wpan/p802_15_4phy.h:58,
 from wpan/p802_15_4mac.h:57,
 from zaodv/zigbee.cc:9:
mac/wireless-phy.h:129: error: syntax error before 'r'
mac/wireless-phy.h:129: error: missing ';' before right brace
mac/wireless-phy.h: In member function `bool WirelessPhy::Is_node_on()':
mac/wireless-phy.h:97: error: `node_on_' undeclared (first use this 
function)
mac/wireless-phy.h:97: error: (Each undeclared identifier is reported only 
once
   for each function it appears in.)
mac/wireless-phy.h: In member function `bool WirelessPhy::Is_sleeping()':
mac/wireless-phy.h:98: error: `status_' undeclared (first use this function)
mac/wireless-phy.h: At global scope:
mac/wireless-phy.h:130: error: `bool node_on_' used prior to declaration
mac/wireless-phy.h:131: error: no matching function for call to 
`Sleep_Timer::
   Sleep_Timer()'
mac/wireless-phy.h:56: error: candidates are: Sleep_Timer::Sleep_Timer(const
   Sleep_Timer)
mac/wireless-phy.h:58: error:
   Sleep_Timer::Sleep_Timer(WirelessPhy*)
mac/wireless-phy.h:132: error: `int status_' used prior to declaration
mac/wireless-phy.h:134: error: syntax error before `private'
mac/wireless-phy.h: In function `EnergyModel* em()':
mac/wireless-phy.h:142: error: `node' undeclared (first use this function)
mac/wireless-phy.h: At global scope:
mac/wireless-phy.h:144: error: `friend' can only be specified inside a class
mac/wireless-phy.h:146: error: syntax error before `}' token
make: *** [aodv/aodv.o] Error 1

Why??. I have not modified anything anymore. Please, help me.
Thank you.

_
Descubre la descarga digital con MSN Music. Más de un millón de canciones. 
http://music.msn.es/



Re: [ns] include file error

2007-04-12 Thread Stefano Busanelli

Il giorno gio, 12/04/2007 alle 16.39 +0200, juan manuel gomez garcia ha
scritto:
 hi ns-users:
 
 It is very simple: Before doing anything, everything works well.
 Later I only do: #include wpan/p802_15_4mac.h  in aodv.h file. And when I 
 do make clean, make, I obtain the errors:
 
 In file included from wpan/p802_15_4phy.h:58,
  from wpan/p802_15_4mac.h:57,
  from zaodv/zigbee.cc:9:
 mac/wireless-phy.h:129: error: syntax error before 'r'
 mac/wireless-phy.h:129: error: missing ';' before right brace
 mac/wireless-phy.h: In member function `bool WirelessPhy::Is_node_on()':
 mac/wireless-phy.h:97: error: `node_on_' undeclared (first use this 
 function)
 mac/wireless-phy.h:97: error: (Each undeclared identifier is reported only 
 once
for each function it appears in.)
 mac/wireless-phy.h: In member function `bool WirelessPhy::Is_sleeping()':
 mac/wireless-phy.h:98: error: `status_' undeclared (first use this function)
 mac/wireless-phy.h: At global scope:
 mac/wireless-phy.h:130: error: `bool node_on_' used prior to declaration
 mac/wireless-phy.h:131: error: no matching function for call to 
 `Sleep_Timer::
Sleep_Timer()'
 mac/wireless-phy.h:56: error: candidates are: Sleep_Timer::Sleep_Timer(const
Sleep_Timer)
 mac/wireless-phy.h:58: error:
Sleep_Timer::Sleep_Timer(WirelessPhy*)
 mac/wireless-phy.h:132: error: `int status_' used prior to declaration
 mac/wireless-phy.h:134: error: syntax error before `private'
 mac/wireless-phy.h: In function `EnergyModel* em()':
 mac/wireless-phy.h:142: error: `node' undeclared (first use this function)
 mac/wireless-phy.h: At global scope:
 mac/wireless-phy.h:144: error: `friend' can only be specified inside a class
 mac/wireless-phy.h:146: error: syntax error before `}' token
 make: *** [aodv/aodv.o] Error 1
 
 Why??. I have not modified anything anymore. Please, help me.
 Thank you.
 
 _
 Descubre la descarga digital con MSN Music. Más de un millón de canciones. 
 http://music.msn.es/
 



[ns] R: Help in simulating Bianchi's results

2007-04-12 Thread Marco Fiore


Hi Riz,

1. I am not sure about how to generate a scenario where all 
the
nodes are contending as in my case of 10 nodes only 0 2 4 6 8 are
contending and the other 1 3 5 7 9 are the sink or them so how can I
come with a scenario where all nodes are coteding as in Bianchi's 
paper

attach one traffic source and one traffic sink to each node.

2. whether cbr interval 0.005 can meet the saturation requirement

you 
are in saturation conditions when each node generates
more traffic than 
it can send. Broadly, it depends on the bandwidth
you are using and one 
the number of contending nodes, but you
can choose a very high value, 
so that even a single source would
saturate the channel (e.g. if you 
are using 11Mbps as MAC datarate,
you can set the CBR rate to 11Mbps, 
and you're sure your nodes
are backlogged).

3. I cannot see any RTS 
and CTS in the trace file why?

because they are off. RTSthreshold_ 
controls the RTS/CTS
(frames smaller than this value go without 
RTS/CTS, frames
bigger require RTS/CTS, defualt is 3000 - i.e. never 
use it),
so the try adding the line
$val(mac) set RTSthreshold_ 0

bye,

Marco


Messaggio originale
Da: [EMAIL PROTECTED]
Data: 11-apr-2007 10.27 AM
A: isi[EMAIL PROTECTED]
Ogg: [ns] Help 
in simulating Bianchi#39;s results


Hi,
 
I am new to Ns and am 
trying to simulate the results for the paper:
 
G. Bianchi, 
Performance Analysis of the IEEE 802.11 Distributed
Coordination 
Function,IEEE JSAC, vol. 18, no. 3, March 2000 
 
My script is given 
below when I am running it with DumbAgent as the
routing protocol I 
don't see any activity in the trace file and the
throughput is zero 
but with a routing protocol I can get some throughput
and I understand 
why this is happening but I don't get why my script
with dumbagent is 
not working. I am using the parameters from Bainchi's
paper
 
I have 
a few questions:
 
1. I am not sure about how to generate a scenario 
where all the
nodes are contending as in my case of 10 nodes only 0 2 
4 6 8 are
contending and the other 1 3 5 7 9 are the sink or them so 
how can I
come with a scenario where all nodes are coteding as in 
Bianchi's paper
2. whether cbr interval 0.005 can meet the saturation 
requirement
3. I cannot see any RTS and CTS in the trace file why?
 
 
# Script to reproduce the results of Bianchi's paper
# 
==
# Define options
# 
==
set val(chan)   Channel/WirelessChannel;# channel type
set val(prop)Propagation/FreeSpace  ;# 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)  10  ;# 
default number
of mobilenodes
set val(rp)   
DumbAgent ;# routing protocol
DumbAgent
set val
(x)   100.0   ;
set val
(y)   100.0   ;
set val
(simtime)  30.0; #sim time 600
 
# 
==
# Main Program
# 
==
set ns_ [new Simulator]
set tracefd [open bianchi.tr 
w]
$ns_ trace-all $tracefd
 
set namtrace [open bianchi.nam 
w]   ;# for nam tracing
$ns_ namtrace-all-wireless $namtrace 
$val(x) $val(y)
#$ns_ use-newtrace
 
#
# set up topography object
#
 
set topo   [new Topography]
$topo load_flatgrid $val(x) $val
(y)
 
#
# Create God
#
 
set god_ [ create-god $val(nn) ]
 
# 
Parameters for 802.11
$val(mac) set SlotTime_ 0.50
$val(mac) set 
SIFS_ 0.28
$val(mac) set PreambleLength_ 0
$val(mac) set 
PLCPHeaderLength_ 128
$val(mac) set PLCPDataRate_ 1.0e6
$val(mac) set 
DIFS_ 0.000128
$val(mac) set dataRate_ 1.0e6
$val(mac) set basicRate_ 
1.0e6
$val(mac) set CWMin_ 31
$val(mac) set CWMax_ 255
#$val(mac) 
set RTShreshold_ 3000
 
set chan_1_ [new $val(chan)]
 
set rng [new 
RNG]
$rng seed 1
set rand1 [new 
RandomVariable/Uniform]
$rand1 use-rng $rng
$rand1 
set min_ -50.0
$rand1 set max_ 50.0
 
#
#  Create the 
specified number of nodes 
#  configure node
 
 
$ns_ node-
config -adhocRouting $val(rp) \
 -
llType $val(ll) \
 -macType $val
(mac) \
 -ifqType $val(ifq) \
 -ifqLen $val(ifqlen) \
  

[ns] Problem Installing ns-allinone-2.1b9a

2007-04-12 Thread manpreet grewal


hello Sir/Madam,
  I am following Nicolas Christin's instructions to install 
ns-allinone-2.1b9a.
Everything goes fine until  ns-allinone-2.1b9a/install gets to 
Build OTcl-1.0a8... and
The error that I received is given below:
checking for libtcl8.3... -L../lib -ltcl8.3
checking for init.tcl... ../lib/tcl8.3
checking for tclsh8.3.2... no
checking for tclsh8.3... ../bin/tclsh8.3
checking for tk.h... -I../include
checking for libtk8.3... -L../lib -ltk8.3
checking for tk.tcl... ../lib/tk8.3
checking for X11 header files
checking for X11 library archive
checking for XOpenDisplay in -lX11... no
can't find X library
otcl-1.0a8 configuration failed! Exiting ...


Please help me...its urgent...

Best Regards,
Manpreet.



Re: [ns] I need to determine values for parameters of the energy

2007-04-12 Thread h sh

hi
   
  Thank you very much for your reply
   
  Is these values for parameters of energy valid 
   
  -rxPower 0.01\
  -txPower 0.03\
  -initialEnergy 10 
   
  please help me 
   
thanks




Paramasivam [EMAIL PROTECTED] wrote:this mainly depends on your 
application, if yours is a battery operated device then the initial energy is 
in the range of 2 Joules and the Transmitting and Recieving power will be in 
the range of micro or pico watts.
   
  i think that for your application, you may use an initial battery of 10 
Joules and the transmitting and receiveing power can be in milli watts.

-- 
-
With Regards,
M.E.Paramasivam ,
Researcher,
Sona College of Technology,
Salem - 636 005,
Tamil Nadu,
INDIA.
GSM - +91 9442604410 
   
  
Hi All,
Could someone help me . I need to determine values for parameters of the 
energy model. P_rx, P_tx, and initialenergy.

 
  -energyModel $energymodel \
  -rxPower $p_rx \
  -txPower $p_tx \
  -initialEnergy $initialenergy

 

I use mobile node and traffic model of the VoIP session considered 

employed G.729 codec for which the payload is 10 Bytes and 

packet rate is 50 packets per second (UDP protocol). 

Simulation time 300 sec.

 

Please help me.

 

Thanks a lot.



   
-
Don't get soaked.  Take a quick peak at the forecast 
 with theYahoo! Search weather shortcut.


[ns] MIP traffic

2007-04-12 Thread Ramzi Tka

Hi all,
How could we recognise the MIP packet in the trace file? Or, at least, how
could we be sure that the MIP messages are being well exchanged?
thanks
kind regards,
 ramzi


[ns] trace interpretation

2007-04-12 Thread Ramzi Tka

Hi all,
could somebody explain to me the following trace line :

D 0.160155230 _13_ MAC  NCO 1 udp 128 [0  4 800] ---
[16779265:0 -1:0 32 0] 

especially the NCO in the 5th field.
Thanks in advance
Ramzi


[ns] Some questions regarding Flow monitor and Maximum window size in ns2

2007-04-12 Thread Narayana

Hello,

I am new to ns2 software.

While doing a simulation on TCP/Reno, I was required to change the
Maximum window size for two different flows through a bottleneck link.

Is the window_ parameter to be set in the code or is their something
else that I am missing..?? While reading the online manual, I came
across the statement that the MWS is a constant. Then how do I change
it, if it is a constant.

I wonder that window_ represents the same. Can someone clear my
understanding and point me into the right direction.

Similarly, I needed to use a flow monitor to measure the average
throughput for two different flows. However the pseudo code given in
the ns manual is a bit confusing. Does someone have a snippet of code
to create a flow monitor to dump the flow data to a flow..??
TIA,


-- 
Best regards,
Narayana  mailto:[EMAIL PROTECTED]
India




[ns] question on installation NS-2.29 on Linux Ubuntu

2007-04-12 Thread Celina Wang

Dear all:
I am installing ns-2.29 in Linux Ubuntu 6.06 version.
After modified settings of all of configure files, new
problem occurs that linker is not working properly.

in the directory ns-2.29/ , ./configure successfully

passed, but make failed due to following errors:
(thousands of lines complaint undefined references)
Anyone can give suggestions? Thanks in advanced.



g++  -o ns \
common/tclAppInit.o  tools/random.o

tools/rng.o tools/ranvar.o common/misc.o
common/timer-handler.o common/scheduler.o
common/object.o common/packet.o
comm$common/tclAppInit.o: In function
`Tcl_AppInit':
tclAppInit.cc http://tclappinit.cc/:(.text+0xef): undefined
reference to `Tcl::init(Tcl_Interp*, char const*)'
:tclAppInit.cc http://tclappinit.cc/:(.text+0x100): undefined reference to

`EmbeddedTcl::load()'
:tclAppInit.cc http://tclappinit.cc/:(.text+0x10c): undefined reference to
`EmbeddedTcl::load common/tclAppInit.o: In function
`abort':
tclAppInit.cc http://tclappinit.cc/:(.text+0x13d): undefined
reference to `Tcl::evalc(char const*)'
common/tclAppInit.o: In function
`Tcl::instance()':
tclAppInit.cc 
http://tclappinit.cc/:(.gnu.linkonce.t._ZN3Tcl8instanceEv[Tcl::instance()]+0x4):
undefined reference to `Tcl::instance_'
tools/rng.o: In function
`RNG::RNG(long)':
rng.cc:(.text+0xdcc): undefined
reference to `TclObject::TclObject()'
:rng.cc:(.text+0xe06): undefined reference to

`TclObject::~TclObject()'
tools/rng.o: In function
`RNG::RNG(long)':rng.cc:(.text+0xe2c): undefined
reference to `TclObject::TclObject()'



Thanks so lot.


[ns] Simulation with real payload

2007-04-12 Thread Anand PG

Hi,

Can anyone please tell me if it is possible with NS2 to give an input file as
real payload for the simulation traffic like video files?

Thanks,
Anand



[ns] Need iNSpect tool

2007-04-12 Thread Mohammed Abu Hajar

hello sir,
 
 I want  iNSpect tool for my research, how can I get it?
 
 
 Regards

   
-
Don't get soaked.  Take a quick peak at the forecast 
 with theYahoo! Search weather shortcut.


[ns] some error about CBQ

2007-04-12 Thread cmxhr


hi,everyone
I am a new user to ns-2,I simulation the CBQ with the following script,but 
produce error,I do not konw why,who can help me ?thank you in advance!
 
this is my script:
 set ns [new Simulator]
set tf [open cbq.tr w]$ns trace-all $tf
 
proc finish {} {global ns tf nf$ns flush-traceclose $tf 
   close $nf   }
set n0 [$ns node]set n1 [$ns node]
$ns duplex-link $n0 $n1 1.0Mb 0ms CBQ/WRR
#set cbqlink [$ns link $n0 $n1]
Simulator  instproc make_queue { cl qlim } { $self instvar cbq_qtype_ set q 
[new Queue/$cbq_qtype_] $q set limit_ $qlim $cl install-queue $q }
Simulator instproc create_flat { audborrowok audxdelay} { $self instvar 
topclass_ vidclass_ audioclass_ dataclass_ $self instvar cbq_qtype_
 set qlim 20 set cbq_qtype_ DropTail
 set topclass_ [new CBQClass] # (topclass_ doesn't have a queue) $topclass_ 
setparams none 0 0.98 auto 8 2 0
  set vidclass_ [new CBQClass] $self make_queue $vidclass_ $qlim $vidclass_ 
setparams $topclass_ true 0.32 auto 1 1 0
 set audioclass_ [new CBQClass] $self make_queue $audioclass_ $qlim 
$audioclass_ setparams $topclass_ $audborrowok 0.03 auto 1 1 $audxdelay
 set dataclass_ [new CBQClass] $self make_queue $dataclass_ $qlim $dataclass_ 
setparams $topclass_ true 0.65 auto 2 1 0}
Simulator instproc insert_flat cbqlink { $self instvar topclass_ vidclass_ 
audioclass_ dataclass_
 
  $cbqlink insert $topclass_ $cbqlink insert $vidclass_  $cbqlink insert 
$audioclass_$cbqlink insert $dataclass_
 $cbqlink bind $vidclass_ 1;# fid 1  $cbqlink bind $audioclass_ 2;# fid 2 
$cbqlink bind $dataclass_ 3; # fid 3}
 
# Create three CBR connections.
set udp1 [new Agent/UDP]
$ns attach-agent $n0 $udp1
set sink1 [new Agent/LossMonitor]
$ns attach-agent $n1 $sink1
$ns connect $udp1 $sink1 
$udp1 set fid_ 1 
 
set cbr1 [new Application/Traffic/CBR]
$cbr1 attach-agent $udp1
$cbr1 set packet_size_ 190
$cbr1 set rate_  1.52Mb
set udp2 [new Agent/UDP]
$ns attach-agent $n0 $udp2
set sink2 [new Agent/LossMonitor]
$ns attach-agent $n1 $sink2
$ns connect $udp2 $sink2 
$udp1 set fid_ 2 
 
set cbr2 [new Application/Traffic/CBR]
$cbr2 attach-agent $udp2
$cbr2 set packet_size_ 500
$cbr1 set rate_ 2Mb
set udp3 [new Agent/UDP]
$ns attach-agent $n0 $udp3
set sink3 [new Agent/LossMonitor]
$ns attach-agent $n1 $sink3
$ns connect $udp1 $sink3
$udp1 set fid_ 3 
 
set cbr3 [new Application/Traffic/CBR]
$cbr3 attach-agent $udp3
$cbr3 set packet_size_ 1000
$cbr3 set rate_ 1.6Mb
$ns at 0.5 $cbr1 start; $cbr2 start; $cbr3 start$ns at 2.0 $cbr1 stop; $cbr2 
stop; $cbr3 stop
$ns at 2.0 finish$ns run
the error:
 
ns:_o17 unknow-flow 0 1 3:   _o17 cmd line 1  invoked from within_o17 cmd 
unknow-flow 0 1 3 invoked from within catch $self cmd $args ret invoked 
from withinif [catch $self cmd $args ret] { set cls [$self info class] 
global errorInfo set savedInfo $errorInfoerror error when calling class 
$cls:$args $... procedure _o17 line 2 SplitObject unknown line 2 
invoked from within_o17 unknown-flow 0 1 3
 
I do konm the meaning of this error
 
Thank you  very much 

---
上海车展开幕在即,热点新车抢先揭秘( 
http://ad4.sina.com.cn/sina/limeng3/mail_zhuiyu/2007/mail_zhuiyu_20070410.html )

===
注册新浪2G免费邮箱( http://mail.sina.com.cn/chooseMode.html )

Re: [ns] Help in simulating Bianchi's results

2007-04-12 Thread Rizwan Ahmad

Hi Marco,

Thanks for your reply and suggestions. I have tried what you have
suggested but the problem still remains as I don't get any throughput
still.
 
I have a feeling that I am not doing it right. I have added the script
to attach one traffic source and one traffic sink to each node but it is
not helping. I will be grateful if you can check the way I am trying to
do this in the script below. 

I am using the old trace. If I reduce it to two nodes I can see the RTS
and CTS being send even without setting the RTSthreshold to 0. I have
set the values of CWmin to 31 and Cwmax to 255 and want to get the
saturation throughput when all nodes are contending.
For saturation I am generating the packets at 0.005 sec and also set the
CBR rate to 1Mbps as suggested by you.

I have doubt at places:

1. The way I generate the topology using random number generator and
making connections i.e. attaching udp and sink to each of the nodes is
wrong. I have seen people using cbrgen.tcl for this but I am not
familiar with tha. I want to generate this for 10, 20 ,30 40 and 50
nodes so because of this scaling I cannot do the connections for all
individually. If you can tell me some other way to generate the topology
for higher no. of nodes and making connections?

2. The other issue is that I am using a packet size of 1024 bytes but
the trace file shows it broken into two i.e. one packet 1000 and the
other 24 and that is because of fragmentation I tried to set the udp
packet size to 2000 but I am not sure if this is the right way to
counter this as it is not working. How to fix this?

3. This same script works if I use any routing protocol instead of
DumbAgent ? but I want to make it work with DumbAgent first and then see
what routing can bring up

4. I cannot see any data being transmitted in the trace file? where as
all other events are taking place i.e. at RTR and AGT level and even MAC
but it either collides or is dropped at the queue.

Looking forward for your help. Thanking you in advance.

Best Regards,
Riz

# Script to reproduce the results of Bianchi's paper
# ==
# Define options
# ==
set val(chan)  Channel/WirelessChannel;# channel type
set val(prop)  Propagation/FreeSpace  ;# radio-propagationmodel
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)10  ;# default number of
mobilenodes
set val(rp)DumbAgent ;# routing protocol
DumbAgent
set val(x)  100.0  ;
set val(y)  100.0  ;
set val(simtime)30.0   ; #sim time 600

# ==
# Main Program
# ==
set ns_ [new Simulator]
set tracefd [open bianchi.tr w]
$ns_ trace-all $tracefd

set namtrace [open bianchi.nam w]   ;# for nam tracing
$ns_ namtrace-all-wireless $namtrace $val(x) $val(y)

# set up topography object
set topo   [new Topography]
$topo load_flatgrid $val(x) $val(y)

#
# Create God
#

set god_ [ create-god $val(nn) ]

$val(mac) set SlotTime_ 0.50
$val(mac) set SIFS_ 0.28
$val(mac) set PreambleLength_ 0
$val(mac) set PLCPHeaderLength_ 128
$val(mac) set PLCPDataRate_ 1.0e6
$val(mac) set DIFS_ 0.000128
$val(mac) set dataRate_ 1.0e6
$val(mac) set basicRate_ 1.0e6
$val(mac) set CWMin_ 31
$val(mac) set CWMax_ 255
$val(mac) set RTShreshold_ 0

set chan_1_ [new $val(chan)]
$chan_1_ set delay_ 1us

set rng [new RNG]
$rng seed 0
set rand1 [new RandomVariable/Uniform]
$rand1 use-rng $rng
$rand1 set min_ -50.0
$rand1 set max_ 50.0

#
#  Create the specified number of mobilenodes [$val(nn)] and attach
them
#  to the channel.
# configure node


$ns_ node-config -adhocRouting $val(rp) \
 -llType $val(ll) \
 -macType $val(mac) \
 -ifqType $val(ifq) \
 -ifqLen $val(ifqlen) \
 -antType $val(ant) \
 -propType $val(prop) \
 -phyType $val(netif) \
 -channel $chan_1_ \
 -topoInstance $topo \
 -agentTrace ON \
 -routerTrace ON \
 -macTrace ON \
 -movementTrace OFF

for {set i 0} {$i  $val(nn) } {incr i} {

[ns] question on installation NS-2.29 on Linux Ubuntu

2007-04-12 Thread Celina Wang

Dear all:
I am installing ns-2.29 in Linux Ubuntu 6.06 version.
After modified settings of all of configure files, new
problem occurs that linker is not working properly.

in the directory ns-2.29/ , ./configure successfully

passed, but make failed due to following errors:
(thousands of lines complaint undefined references)
Anyone can give suggestions? Thanks in advanced.



g++  -o ns \
common/tclAppInit.o  tools/random.o

tools/rng.o tools/ranvar.o common/misc.o
common/timer-handler.o common/scheduler.o
common/object.o common/packet.o
comm$common/tclAppInit.o: In function
`Tcl_AppInit':
tclAppInit.cc http://tclappinit.cc/:(.text+0xef): undefined
reference to `Tcl::init(Tcl_Interp*, char const*)'
:tclAppInit.cc http://tclappinit.cc/:(.text+0x100): undefined reference to

`EmbeddedTcl::load()'
:tclAppInit.cc http://tclappinit.cc/:(.text+0x10c): undefined reference to
`EmbeddedTcl::load common/tclAppInit.o: In function
`abort':
tclAppInit.cc http://tclappinit.cc/:(.text+0x13d): undefined
reference to `Tcl::evalc(char const*)'
common/tclAppInit.o: In function
`Tcl::instance()':
tclAppInit.cc 
http://tclappinit.cc/:(.gnu.linkonce.t._ZN3Tcl8instanceEv[Tcl::instance()]+0x4):
undefined reference to `Tcl::instance_'
tools/rng.o: In function
`RNG::RNG(long)':
rng.cc:(.text+0xdcc): undefined
reference to `TclObject::TclObject()'
:rng.cc
:(.text+0xe06): undefined reference to

`TclObject::~TclObject()'
tools/rng.o: In function
`RNG::RNG(long)':rng.cc:(.text+0xe2c): undefined
reference to `TclObject::TclObject()'



Thanks so lot.


[ns] Query about errors during running make command

2007-04-12 Thread Anuradha Sehgal

hello everyone

I am using ns-allinone-2.31 that i installed on cygwin.
I am trying to add encryption and decryption in ns2.
The encryption and decryption code that i am trying to put in
../ns-2.31/common/packet.h running well when i use gcc, CC or g++. I
mean it do not complain for any thing. But the problem is when i run
the make command to recompile ns2, it gives three strange errors and a
lots of warnings.
The three errors are:

error:expected primary-expression before int.
error:expected ; before int
error::non-lvalue in assignment

why these errors are occuring??
I checked the code, but there is no problem, moreover its compiling
and running sucessfully if i use gcc, CC, g++(and in turbo c also).
Is make comamnd is using some older compiler? If so how can i remove
these errors?

its urgent, please reply soon

Thanks in advance,

Anuradha Sehgal


[ns] adding encryption/decryption in ns2

2007-04-12 Thread Anuradha Sehgal

hello everyone

I am using ns-allinone-2.31 that i installed on cygwin.
I am trying to add encryption and decryption in ns2.
The encryption and decryption code that i am trying to put in
../ns-2.31/common/packet.h running well when i use gcc, CC or g++. I
mean it do not complain for any thing. But the problem is when i run
the make command to recompile ns2, it gives three strange errors and a
lots of warnings.
The three errors are:

error:expected primary-expression before int.
error:expected ; before int
error::non-lvalue in assignment

why these errors are occuring??
I checked the code, but there is no problem, moreover its compiling
and running sucessfully if i use gcc, CC, g++(and in turbo c also).
Is make comamnd is using some older compiler? If so how can i remove
these errors?

its urgent, please reply soon

Thanks in advance,

Anuradha Sehgal


[ns] problems during running make command

2007-04-12 Thread Anuradha Sehgal

Hello everone

I am using ns-allinone-2.31 that i installed on cygwin.
I am trying to add encryption and decryption in ns2.
The encryption and decryption code that i am trying to put in
../ns-2.31/common/packet.h running well when i use gcc, CC or g++. I
mean it do not complain for any thing. But the problem is when i run
the make command to recompile ns2, it gives three strange errors and a
lots of warnings.
The three errors are:

error:expected primary-expression before int.
error:expected ; before int
error::non-lvalue in assignment

why these errors are occuring??
I checked the code, but there is no problem, moreover its compiling
and running sucessfully if i use gcc, CC, g++(and in turbo c also).
Is make comamnd is using some older compiler? If so how can i remove
these errors?

its urgent, please reply soon

Thanks in advance,

-- 
Anuradha Sehgal