omnet++ (2)-2
DESCRIPTION
oTRANSCRIPT
![Page 1: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/1.jpg)
OMNetOMNet++++
By: Fatemeh SaremiBy: Fatemeh SaremiBy: Fatemeh SaremiBy: Fatemeh Saremi
Modeling and Analysis of Computer Networks CourseModeling and Analysis of Computer Networks Course
Prof. A. MovagharProf. A. Movaghar
Sharif University of TechnologySharif University of Technology
Computer Engineering DepartmentComputer Engineering Department
Spring Spring 20092009
![Page 2: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/2.jpg)
OverviewOverview
� OMNeT++?
� Installation
� Simulation
ModelsModels
� TicToc
Tutorial
� NED, Tkenv,
GNED, Plove,
and Scalars
� AdHocSim 2
![Page 3: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/3.jpg)
What is OMNeT++?What is OMNeT++?
� An object-oriented modular discrete event network
simulator
� traffic modeling of telecommunication networks
� protocol modeling
� modeling queuing networks � modeling queuing networks
� modeling multiprocessors and other distributed hardware
systems
� validating hardware architectures
� evaluating performance aspects of complex software
systems
� ... modeling any other system where the discrete event
approach is suitable. 3
![Page 4: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/4.jpg)
The Simulation System The Simulation System --
ComponentsComponents� Simulation kernel
� Contains the code that manages the simulation
� Library
� Written in C++, compiled and put together to form a library� Written in C++, compiled and put together to form a library
� User interfaces
� Used in simulation execution, to facilitate debugging,
demonstration, or batch execution of simulations. There are
several user interfaces, written in C++, compiled and put
together into libraries
4
![Page 5: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/5.jpg)
OMNetOMNet++++
� Portability
� Working on Windows and several Unix platforms
using various C++ compilers
5
![Page 6: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/6.jpg)
Linux, Solaris and Linux, Solaris and
other Unixother Unix--like Systemslike Systems
� Download the source tgz archive (omnetpp-
<version>-src.tgz).
� Extract it into your home directory:� Extract it into your home directory:
(tar xvfz omnetpp-2.3-src.tgz )
� You'll find a Readme.Unix file in its doc/
subdirectory -- just follow the instructions
described there.
6
![Page 7: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/7.jpg)
WindowsWindows
� You need to have NT4.0, Win2000 or XP.
Win95/98/ME won't work.
� Install OMNeT++ into a directory that doesn't
have space in its name, e.g. don't install in have space in its name, e.g. don't install in
under C:\Program files\ (Otherwise you'll have
problems with the makefiles.)
� Windows/Microsoft Visual C++ 6.0 or 7.0 (.NET)
� Windows/MSVC - building from sources
� Windows/Cygwin
� Windows/MinGW 7
![Page 8: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/8.jpg)
Simulation Models Simulation Models
� An OMNeT++ model consists of the following parts:
� NED language topology description (.ned files) which describe the module structure with parameters, gates etc.
� Message definitions, we can define various message types and add data fields to them.and add data fields to them.
� OMNeT++ will translate message definitions into full-fledged C++ classes.
� Simple modules sources. They are C++ files, with .h/.cc suffix.
8
![Page 9: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/9.jpg)
Simulation Simulation Models (Models (Cont.)Cont.)
� INET Framework
� AdHocSim
� Antnet
� Mobility Framework � Mobility Framework
� IPv6Suite
� VideoInterface
� Ethernet
� P2P Swarming Protocol Simulation
� Centralized Network model based on Hiperlan/2 9
![Page 10: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/10.jpg)
Simulation Models (Cont.)Simulation Models (Cont.)
� SimSANs
� Queues
� SCSI Bus
� Personal Communication Services (PCS) � Personal Communication Services (PCS)
� File System Simulation
10
![Page 11: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/11.jpg)
TicTocTicToc Tutorial for OMNeT++Tutorial for OMNeT++
� This short tutorial to OMNeT++ guides you
through an example of modeling and
simulation, showing you along the way some
of the commonly used OMNeT++ features.of the commonly used OMNeT++ features.
11
![Page 12: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/12.jpg)
Steps for applicationSteps for application
� Create a working directory called tictoc.
� Describe your example network by creating a
topology file (*.ned).
12
![Page 13: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/13.jpg)
ModulesModules
� Hierarchically nested modules
� The NED (NEtwork Description) Language
� Facilitates the modular description of a network
� Reuse in another network description
� Message passing
13
![Page 14: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/14.jpg)
Modules: ExampleModules: Example
14
![Page 15: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/15.jpg)
Steps for application (Cont.)Steps for application (Cont.)
� We now need to implement the functionality of the simple
module (*.cc).
15
![Page 16: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/16.jpg)
TxcTxc11.cc (Cont.).cc (Cont.)
16
![Page 17: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/17.jpg)
Steps for application (Cont.)Steps for application (Cont.)
� You have to create one omnetpp.ini that tells the simulation
program which network you want to simulate
17
![Page 18: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/18.jpg)
Steps for application (Cont.)Steps for application (Cont.)
� We now create the Makefile which will help us to compile and
link our program to create the executable tictoc:
$ opp_makemake
� Compile and link our very first simulation by making
command: command:
$ make
� Once you complete the above steps, you launch the simulation
by issuing this command:
$ ./tictoc
18
![Page 19: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/19.jpg)
TicTocTicToc
19
![Page 20: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/20.jpg)
TkenvTkenv
� Tkenv is a portable graphical windowing user
interface.
� Tkenv supports interactive execution of the
simulation, tracing and debugging.
20
![Page 21: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/21.jpg)
GNEDGNED
� Graphical editor for OMNeT++ models
21
![Page 22: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/22.jpg)
PlovePlove
� A handy tool for plotting and analyzing OMNeT++
simulation results
22
![Page 23: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/23.jpg)
PlovePlove (Cont.)(Cont.)
23
![Page 24: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/24.jpg)
ScalarsScalars
� A handy tool for creating bar charts and x-y plots
from OMNeT++ output scalar files (omnetpp.sca by
default)
24
![Page 25: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/25.jpg)
AdHocSimAdHocSim (Assignment)(Assignment)
25
![Page 26: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/26.jpg)
LessmannLessmann, J., , J., JanacikJanacik, P., , P., LachevLachev, L., , L., OrfanusOrfanus, D., , D.,
“Comparative Study of Wireless Network Simulators”, “Comparative Study of Wireless Network Simulators”, Seventh International Conference on Networking, Seventh International Conference on Networking, 2008 2008 (IEEE (IEEE
ICN ICN 20082008))
26
![Page 27: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/27.jpg)
27
![Page 28: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/28.jpg)
ReferenceReference
� http://www.omnetpp.org/
� OMNet++ User Manual
� TicToc Tutorial for OMNet++
28
![Page 29: OMNet++ (2)-2](https://reader030.vdocuments.mx/reader030/viewer/2022012317/5493d13fac7959092e8b49a7/html5/thumbnails/29.jpg)
Thank you for your attention.Thank you for your attention.
Questions, Comments, …?
29