Simple Module Period

Package: core4inet.scheduler.period
File: src/core4inet/scheduler/period/Period.ned

C++ definition

Period Module: Periods define the cycles for events

Author: Till Steinbach

Period

Usage diagram:

The following diagram shows usage relationships between types. Unresolved types are missing from the diagram. Click here to see the full picture.

Inheritance diagram:

The following diagram shows inheritance relationships for this type. Unresolved types are missing from the diagram. Click here to see the full picture.

Used in compound modules:

Name Type Description
Scheduler compound module

The Scheduler provides timing events for other modules.

Parameters:

Name Type Default value Description
cycle_ticks int 37500tick

Number of ticks for one cycle

offset_ticks int 0tick

Number of ticks offset

Properties:

Name Value Description
display i=block/table

Gates:

Name Direction Size Description
out output

Output to the timer module (currently unused)

schedulerIn input

Input gate for the incoming SchedulerActionTimeEvent messages

Signals:

Name Type Unit
newCycle

Statistics:

Name Title Source Record Unit Interpolation Mode
newCycle Start of cycle vector? none
numberOfCycles Number of cycle newCycle count none

Source code:

//
// Period Module: Periods define the cycles for events
//
// @author Till Steinbach
//
simple Period
{
    parameters:
        @display("i=block/table");

        //Signal emitted when a new cycle starts
        @signal[newCycle]();
        //Statistic of the beginning of a new cycle
        @statistic[newCycle](title="Start of cycle"; record=vector?; interpolationmode=none);
        //Statistic of the number of cycles 
        @statistic[numberOfCycles](title="Number of cycle"; source=newCycle; record=count; interpolationmode=none);

        // Number of ticks for one cycle
        int cycle_ticks @unit(tick) = default(37500tick);
        // Number of ticks offset
        int offset_ticks @unit(tick) = default(0tick);

    gates:
        //Output to the timer module (currently unused)
        output out;
        //Input gate for the incoming SchedulerActionTimeEvent messages
        input schedulerIn @directIn @label(SchedulerMessage);
}