Simple Module BonnMotionMobility

Package: inet.mobility
File: src/mobility/BonnMotionMobility.ned

C++ definition

Uses the native file format of BonnMotion (http://www.cs.uni-bonn.de/IV/BonnMotion/).

The file is a plain text file, where every line describes the motion of one host. A line consists of one or more (t, x, y) triplets of real numbers, like:

t1 x1 y1 t2 x2 y2 t3 x3 y3 t4 x4 y4 ...

The meaning is that the given node gets to (xk,yk) at tk. There's no separate notation for wait, so x and y coordinates will be repeated there.

Author: Andras Varga

BonnMotionMobility

Usage diagram:

The following diagram shows usage relationships between types. Unresolved types are missing from the diagram.

Inheritance diagram:

The following diagram shows inheritance relationships for this type. Unresolved types are missing from the diagram.

Parameters:

Name Type Default value Description
debug bool false

debug switch

traceFile string

the BonnMotion trace file

nodeId int

selects line in trace file; -1 gets substituted to parent module's index

updateInterval double 100ms

time interval to update the hosts position

Properties:

Name Value Description
display i=block/cogwheel_s

Source code:

//
// Uses the native file format of BonnMotion (http://www.cs.uni-bonn.de/IV/BonnMotion/).
//
// The file is a plain text file, where every line describes the motion
// of one host. A line consists of one or more (t, x, y) triplets of real
// numbers, like:
//
// t1 x1 y1 t2 x2 y2 t3 x3 y3 t4 x4 y4 ...
//
// The meaning is that the given node gets to (xk,yk) at tk. There's no
// separate notation for wait, so x and y coordinates will be repeated there.
//
// @author Andras Varga
//
simple BonnMotionMobility like BasicMobility
{
    parameters:
        bool debug = default(false); // debug switch
        string traceFile; // the BonnMotion trace file
        int nodeId; // selects line in trace file; -1 gets substituted to parent module's index
        double updateInterval @unit("s") = default(100ms); // time interval to update the hosts position
        @display("i=block/cogwheel_s");
}