OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models...

41
OMNeT++

Transcript of OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models...

Page 1: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

OMNeT++

Page 2: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Outline

What is OMNeT++?InstallationTicToc Tutorial for OMNeT++Simulation modelsVisualizing the results with Plove and Scal

ars Reference

Page 3: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

What is OMNeT++?

Page 4: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

What is OMNeT++? OMNeT++ is a public-source, component-based, modula

r and open-architecture simulation environment with strong GUI support and an embeddable simulation kernel.

OMNeT++ provides a component architecture for models. Components (modules) are programmed in C++, then assembled into larger components and models using a high-level language (NED).

OMNeT++ is free for academic and non-profit use; commercial users must obtain a license from Omnest Global Inc.

Page 5: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 6: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 7: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Installation

Page 8: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Platforms

OMNeT++ runs well on Linux most other Unix-like systems Win32 platforms (NT4.0, Window 2000, XP).

Third party software C++ compilerTcl/TkPerlGraphVizGhostscriptUnxUtilsLibXML/LibXSLT

Page 9: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Linux, Solaris and other Unix-like systems

download the source tgz archive (omnetpp-<version>-src.tgz).

Extract it into your home directory:

(tar xvfz omnetpp-2.3-src.tgz )You'll find a Readme.Unix file in its doc/ su

bdirectory -- just follow the instructions described there.

Page 10: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Windows

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 under C:\Program files\ (Otherwise you'll have problems with the makefiles.)

Page 11: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Windows/Microsoft Visual C++ 6.0 or 7.0 (.NET)

Windows/MSVC - building from sourcesWindows/CygwinWindows/MinGW

Page 12: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Install OMNeT++ on Windows with the Cygwin platform

1. install Cygwin

2. download X11inc.zip from the OMNeT++ site then extract it to /usr/include/X11

3. install OMNeT++

4. add omnetpp/bin to the PATH

5. make sure nedtool, gned, opp_makemake and the sample simulations work

Page 13: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Install Cygwin When selection packages to install, be sure to include th

e following ones: gcc g++、make、 tcl/tk…

It is a good idea to create a .bash_profile for each user who will use Cygwin. This should be stored in each users home directory (i.e. /home/<you>).For example, an initial .bash_profile may contain:

alias ls='ls -aF'export TCL_LIBRARY=c:/cygwin/usr/share/tcl8.3

TCL_LIBRARY is necessary to allow tcl/tk to operate correctly.

Page 14: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Install Cygwin

Cygwin misses X11 headers that are normally required to build programs with Tcl/Tk. Extract it to /usr/include/X11. If you're getting compilation errors like /usr/include/tk.h:77: X11/Xlib.h: No such file or directory while building Tkenv.

The BLT Tcl/Tk extension package is needed to run OMNeT++ 3.x on Cygwin. The Cygwin distribution doesn't contain BLT. and download the BLT source, build (./configure;make) and install (make install) it.

Page 15: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Install OMNeT++

Download the omnetpp source code.tar zxvf omnetpp.tgz./configuremakeYou should now add the following lines to

your startup file .bash_profile:

export PATH=$PATH:~/omnetpp/bin

Page 16: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Test OMNeT++

make sure nedtool, gned, opp_makemake and the sample simulations work

cd ~/omnetpp/samples/dyna ./dyna

Page 17: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Tkenv

Tkenv is a portable graphical windowing user interface.

Tkenv supports interactive execution of the simulation, tracing and debugging.

Page 18: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 19: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Simulation models INET Framework

The INET Framework is the successor of the IPSuite package. It provides TCP, IP, Ethernet, MPLS and other protocols.

AdHocSim Nicola Concer's simulator for ad-hoc networks. Implements AODV protocol and several mobility models.

Antnet The model implements an Ant-based routing algorithms (AntNet-CL and AntNet-CO) proposed by G. Di Caro and M. Dorigo.

Page 20: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Simulation models Mobility Framework

Supports wireless and mobile simulations within OMNeT++. The core framework implements the support for node mobility, dynamic connection management and a wireless channel model.

IPv6Suite IPv6Suite is an OMNeT++ model suite for accurate simulation of IPv6 protocols and networks.

VideoInterface

Page 21: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Simulation models Ethernet

Ethernet, Fast Ethernet and Gigabit Ethernet model. Includes MAC, LLC, switch, hub and bus models.

P2P Swarming Protocol Simulation The first release of a swarming P2P protocol simulation.

Centralized Network model based on Hiperlan/2 SimSANs

A development toolkit for designing, modeling, simulating, and evaluating SANs (Storage Area Networks).

Page 22: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Simulation models Queues

Queues is a queueing network tutorial and basic queueing library for OMNeT++.

SCSI Bus SCSI bus model

Personal Communication Services (PCS)

File System Simulation A simulation of the components involved in a file system implementation.

Page 23: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

OMNEST Demo

OMNEST 3.0 Demo for Windows (installer) Contains executable demo simulations for several model frameworks written for OMNEST/OMNeT++

Page 24: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

TicToc Tutorial for OMNeT++

Page 25: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

TicToc 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.

Page 26: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Steps for application

1. Create a working directory called tictoc.2. Describe your example network by creating a topology file(*.ned).

3. We now need to implement the functionality of the simple modul

e(*.cc).4. We now create the Makefile which will help us to compile and lin

k our program to create the executable tictoc:$ opp_makemake

5. Compile and link our very first simulation by making command: $ make

6.you have to create one. omnetpp.ini tells the simulation program which network you want to simulate

7. Once you complete the above steps, you launch the simulation by issuing this command:

Page 27: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

tictoc1.ned

Page 28: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

NED language overview

NED (NEtwork Description) is the topology description language of OMNeT++. It has a simple syntax yet, but it is very powerful in defining topologies.

Page 29: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

GNED - Graphical Network Editor

GNED is a graphical editor for OMNeT++ models. Some features: fully two-way tool: switch back and forth betw

een graphics and corresponding NED representation

multiple files, multiple editing windows drag & drop submodule creation syntax highlighted NED editor

Page 30: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 32: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 33: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 34: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Visualizing the results with Plove and Scalars

Page 35: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Plove - Overview

Plove is a handy tool for plotting and analysing OMNeT++ simulation results. Plove works with output vector files; they are files OMNeT++ saves simulation results into. Output vector files contain several output vectors. An output vector contains a time series: several values with timestamps.

Plove can plot output vectors, one or more in a graph. You can specify the drawing style (lines, dots etc) for each vector. You can set axis bounds, scaling, titles and labels, etc.

You can save the graphs to files in various formats (EPS, GIF, etc) or (on Windows) copy them to the clipboard.

Page 36: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 37: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 38: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Scalars - Overview

Scalars is a handy tool for creating bar charts and x-y plots from OMNeT++ output scalar files (omnetpp.sca by default).

You can save the graphs to files in various formats (EPS, GIF, etc) or (on Windows) copy them to the clipboard.

Page 39: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.
Page 40: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Reference

http://www.omnetpp.org/http://www.omnest.com/

Page 41: OMNeT++. Outline What is OMNeT++? Installation TicToc Tutorial for OMNeT++ Simulation models Visualizing the results with Plove and Scalars Reference.

Thanks

林志昇[email protected]