Tutorial Wireless Sensor Network Simulation
Tutorial Wireless Sensor Network Simulation
Documentation
by Tobias Doerffel
Contents
1 Introduction 3
1.1 The scenario . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2 QualNet overview 4
2.1 Components of QualNet . . . . . . . . . . . . . . . . . . . . . . . . 4
2.2 Installing QualNet on a recent Linux system . . . . . . . . . . . . . 4
2.3 Installing QualNet on Windows . . . . . . . . . . . . . . . . . . . . 5
6 Conclusion 16
2
1. Introduction
1 Introduction
Nowadays network applications – especially in the area of wireless networks – are
becoming more and more complex which makes the design and the testing almost
impossible without appropriate software. There’re a lot of different programs avail-
able to aid the user in simulating previously designed scenarios. This work covers
the implementation of a given scenario using the software QualNet by Scalable Net-
works in version 4.5.1.
QualNet is a commercial software that runs on all common platforms (Linux, Win-
dows, Solaris, OS X) and is specialized in simulating all kind of wireless applications.
It has a quite clear user interface compared to other solutions while also offering an
easy to use command line interface.
1
http://tools.ietf.org/html/rfc3561
2
http://mathstat.helsinki.fi/mathphys/EVERGROW/virtamo.pdf
3
http://www.eecs.harvard.edu/ mdw/course/cs263/papers/ftsp-sensys04.pdf
3
2. QualNet overview
2 QualNet overview
sudo su
cd / opt
tar xzf < download directory >/ qualnet -4.5.1 - evaluation . tar . gz
Next the QualNet core application has to be compiled. Since the provided source
code does not follow the official C++ standard (ISO/IEC 14882:1998) it can’t be
compiled without some small modifications. An according patch named fix-qualnet-
core-sources.diff can be found in the archive containing all files related to this work.
To apply it and compile everything run the following commands:
sudo su
cd / opt / qualnet /4.5/
patch - p2 < ...../ fix - qualnet - core - sources . diff
cd main
cp Makefile - linux - glibc -2.3 - gcc -4.0 Makefile
make
4
http://www.scalable-networks.com/products/qualnet/download.php
4
2.3 Installing QualNet on Windows
5
3. Designing the scenario
All properties of the scenario can be viewed and changed using the Inspector on the
left side. There’s an amazing amount of properties, subproperties and parameters
that can be altered although we only need to touch a very few of them.
For not having to change common properties for each node there’s a possibility to
set global properties below ConfigSettings. In particular only some of the items are
of interest in the following. The changes as listed below were made to configure the
nodes according to the requirements:
• Wireless Settings→Radio/Physical Layer →Radio Type: 802.15.4 Radio
• Wireless Settings→MAC Protocol →MAC Protocol : 802.15.4
• Network Protocols→Routing Protocol →Routing Policy→Routing Protocol for
IPv4 : AODV
6
3. Designing the scenario
7
3.1 Data sink
8
3.4 Traffic generators
9
3.4 Traffic generators
Finally the traffic generators have to be configured according to the scenario speci-
fications. For each traffic generator in the inspector change the following properties
below Connections→CBR XX-1 :
• Items to Send : 30
• Item Size (bytes): 2048
• End Time: 0
• Traffic type→Data Size→Fixed Size: 2048
As a last tweak the simulation time (ConfigSettings→General →Simulation Time)
should be altered to 300 seconds as per default the simulation runs faster than
realtime and thus would be finished just after a few seconds.
Now the scenario should be ready to run.
10
4. Running the scenario
The worst drawback of the QualNet animator is its extrem high CPU utilization
and its implementation in Java which makes it run very slowly on most machines.
11
4.2 QualNet 3D Visualizer
Figure 6: 3D Visualizer
12
4.3 Command line interface
If not specified differently, this will generate a file called Qualnet.stat which contains
all statistical data related to the simulation. It can be viewed using the QualNet
Analyzer as described in the next chapter.
13
5. Analyzing the results
14
5. Analyzing the results
15
6. Conclusion
6 Conclusion
Without having compared QualNet to other similiar solutions various advantages
became apparent while using it. The most important ones are:
• easy-to-use and clear UI
• wide range of possible applications (even WiMAX MAC layer is supported)
• support for multiprocessor systems and distributed computing
• sophisticated animation capabilities
• extensive possibilities for analyzing scenario
• shipped with a lot helpful documentation and tons of example scenarios
5
ftp://ftp.tik.ee.ethz.ch/pub/publications/TIK-Report-255.pdf, page 11
16