Skip to main content

34 posts tagged with "OMNET++"

View All Tags

· One min read

From Tom Parker:

They are available by adding the following lines to your /etc/apt/sources.list

deb binary/ deb-src source/

and then running "apt-get update", followed by "apt-get install omnetpp-static". As the name suggests, the package only currently has static library versions of OMNeT++ not the shared versions, but I will be expanding this to include shared versions at a later date.

· 2 min read

修改模組就是由實際 class, procedure 到目標理想 class, procedure 的過程. 在動手修改模組之前必定先規劃好目標系統.


make (nmake) 的特性是只重編改動到的檔案,因此如果你一次只改動一兩個檔案, 並用上一個還行的 CPU (~1G), 就不用擔心重新編譯所需時間過長的問題.


當 然,你對模擬工具組成架構越清楚,在模擬工具程式架構清楚的情況下,你的目標理想 class, procedure 可能就會越接近實際 class, procedure. 為了修改模組順暢,適當參考相關模擬程式提供的架構是必要的。不然會遇到規劃出來的目標架構無法從模擬程式順利修改的窘境.

OMNeT++ 比起 NS2 很大的優勢就在此, 感謝 Andras 開發的 IPv6SuiteWithINET 模組,讓我們可以用很接近實作的 Code 來模擬. 另一個例子是 S. Dulman 開發的 NesCT, 可以用此模組在 OMNeT++ 上跑 TinyOS 程式.

· 2 min read

Q: INET framework without dynamic nedfile

A: Easiest way to switch from dynamic NED to compiled-in NED for INET is to remove the "-N" flag from OPTS at the top of the makemake script, then regenerate the makefiles (./makemake) and make. (And of course remove preload-ned-files lines from omnetpp.ini's.)

Q:I'll use an example from Omnet Documentation:

module RoutingTestNetwork
routingNodeType: string; // should hold the name
// of an existing module type
gates: //...
node1: routingNodeType like RoutingNode;
node2: routingNodeType like RoutingNode;
connections nocheck:
node1.out0 --> node2.in0;

What happens if I declare a routingNodeType in omnet.ini file which would be different from that declared in my .ned file? e.g. omnetpp.ini: *.node.routingNodeType = "Routingsomething"

Or perhaps I have to define this module in RoutingNode.ned and add some parameters in Routingsomething.ned if I want.

A:The setting in the NED file, if present, takes precedence over omnetpp.ini (basically, omnetpp.ini is only consulted if param is not set in the NED).

The module Routingsomething MUST have at least the parameters and gates RoutingNode has, but it can add new ones as well.

Q:I wish to create shared libs in each of the subdirectories then link them to an executable for each of the networks like the old IPv6Suite.

A: we haven't actually had this option available for the IPv6SuiteWithINET.

Currently, all c++ objects are statically linked into bin/INET. A batch file is provided in each network directory to run the executable, bin/INET and load omnetpp.ini (or -f <your_own_network_ini>) in the current network directory. (Eric)

Q:</your_own_network_ini> I've installed TCL/TK but while executing make command, it can't found them <your_own_network_ini>A:</your_own_network_ini> Go to the installing directory and edit configure.user. Specifiy the path to the TCL/TK header files. On my mashine tcl.h and tk.h are in /usr/include/:


4 -fwritable-strings" TK_LIBS="-L/usr/lib -ltk8.4 -ltcl8.4"

You should change the compiler flags if you want to debug your sessions:

CFLAGS='-gstabs+3 -Wall'