1 / 17

Introduction to OMNeT++

Introduction to OMNeT++. Nailah Shokre Al Madi nsalmadi06@cit.just.edu.jo. Outline. What is OMNeT++? Installing OMNeT++ OMNeT++ Main Components Simple Example WSN Routing Algorithms (ex: LEACH, PEGASIS) WSN Example. What is OMNeT++?.

anson
Download Presentation

Introduction to OMNeT++

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to OMNeT++ NailahShokre Al Madi nsalmadi06@cit.just.edu.jo

  2. Outline What is OMNeT++? Installing OMNeT++ OMNeT++ Main Components Simple Example WSN Routing Algorithms (ex: LEACH, PEGASIS) WSN Example nsalmadi06@cit.just.edu.jo

  3. What is OMNeT++? OMNeT++ is a C++-based discrete event simulator for modeling communication networks, multiprocessors and other distributed systems. A new simulator for wireless sensor networks. Its results are very close to real world results. www.Omnetpp.org nsalmadi06@cit.just.edu.jo

  4. Installing OMNeT++ To install OMNeT++: Install Microsoft Visual C++. Install OMNeT++ 3.3 (binary release) for windows. OMNET++ version 4, released in November 2008. OMNET++ Mailing List; you can send a message to the mailing list nsalmadi06@cit.just.edu.jo

  5. nsalmadi06@cit.just.edu.jo

  6. OMNET++ Main Components Your simulation must have 4 files: omnetpp.ini Specify: network, simulation speed, output-scalar-file, network area (x,y),number of nodes, other parameters, module. ned Defines the network and the modules in side it, and each module ( its gates and other parameters).   module.cc , module.h Define the functionality of each module, mainly include: initialize() handleMessage(cMessage * msg) finish() nsalmadi06@cit.just.edu.jo

  7. Simple Example After creating the files ( .ned, .cc, .h, and omnetpp.ini) Open cmd console and go to your algorithm folder: Important: make sure that your path doesn’t contain any spaces. OR it will not run. Write these : opp_nmakemake -f nmake -f makefile.vc depend nmake -f makefile.vc Algo.exe will result Algo.  lets go toTicTocexample nsalmadi06@cit.just.edu.jo

  8. WSN Routing Algorithms Wireless Sensor Network- WSN: a collection of a large number of sensors without the support of pre-existing infrastructure, distributed to be close to the phenomena being monitored. WSN main drawback is limited energy supported in sensors. (limited rechargeable, un-replaceable batteries) Main factor of energy consumption is communication: Transmitting, Receiving (consumes less). Routing algorithms control communication. nsalmadi06@cit.just.edu.jo

  9. WSN Routing Algorithms Cluster based routing algorithms: routing algorithms based on the idea of creating clusters to collect the data and route it from the sensors to the sink (BS). It is efficient because it: Reduces energy consumption within the cluster, Performs data aggregation, which: reduces the amount of data. reduces the number of packets to send to the sink. nsalmadi06@cit.just.edu.jo

  10. WSN Routing Algorithms LEACH - Low Energy Adaptive Clustering Hierarchy PEGASIS - Power–Efficient Gathering in Sensor Information System nsalmadi06@cit.just.edu.jo

  11. Low Energy Adaptive Clustering Hierarchy LEACH Random < p/(1- p*(r mod 1/p) )? Steady-state Phase b a Setup Phase 1. Advertisement Phase 2. Cluster Setup Phase 3. Schedule creation d c BS nsalmadi06@cit.just.edu.jo

  12. LEACH Advantages: • Energy savings due to combining lossy compression with the data routing. • It distributes energy-usage among the nodes; nodes die randomly and at the same rate. Disadvantage • Doesn’t ensure that CH’s are uniformly placed across the whole sensor field, • CH’s transmit data directly to the distant BS, while members sends to a close CH. nsalmadi06@cit.just.edu.jo

  13. Power–Efficient Gathering in Sensor IS PEGASIS Chain Construction Phase Data Aggregation Phase BS Id= Round/N nsalmadi06@cit.just.edu.jo

  14. PEGASIS Advantages: • Saving energy by minimizing: • The transmission distance • The number of transmissions and receives for each node • Each node will be the leader once every 100 rounds (for 100 nodes network). Disadvantages • Main: long chain and the very high delay probability; • Nodes may have distant neighbours along the chain. • Increasing neighbour distances will have a significant effect on PEGASIS performance nsalmadi06@cit.just.edu.jo

  15. WSN Example Lets see Solar Leach Example ( you can download it from www.omnetpp.org) nsalmadi06@cit.just.edu.jo

  16. Statistics - Scalars To test a value through the simulation and create a graph of its behavior. Use this in the .cpp files: recordScalar(“ValName", Value); ex: recordScalar("Rounds", this->rdone); recordScalar(" Dead Nodes", this->deadnodes); In omnetpp.sca file : The recorded values. Creating the graphs for values nsalmadi06@cit.just.edu.jo

  17. Resources OMNeT++ Folder Documentation Tutorial Samples OMNeT++ website: omnetpp.org Other WSN simulators: Castalia,  NesCT, Jsim, NS2. nsalmadi06@cit.just.edu.jo

More Related