Compound Module TTEEtherHost

Package: ttethernet.nodes.ethernet
File: src/nodes/ethernet/TTEEtherHost.ned

Module for a TTEthernet Host. Contains a EtherLLC for best-effort traffic, a TTEPHYPort module as physical port, sync module (Sync) and a TTEScheduler module. The Host is configured by the provided TTEthernet XML network configuration (network_configuration parameter) and uses the device_name parameter to find its config. The configuration is done by the BufferManager that deletes itself at runtime.

TODO: Ports for redundancy!

TODO: Documentation for Applications!

See also: EtherLLC, TTEPHYPort, Sync, TTEScheduler, BufferManager

Author: Till Steinbach

TTEPHYPort EtherLLC EtherAppCli EtherAppSrv IConfigurationManager ISync TTEScheduler ITTEApplication BGQueueBuffer BGQueueBuffer BGTrafficHandle

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.

Known subclasses:

Name Type Description
Unit1 compound module

unit1: configuration in unit1.ini.

Unit2 compound module

unit2: configuration in unit2.ini.

Unit3 compound module

unit3: configuration in unit3.ini.

Parameters:

Name Type Default value Description
numApps int 0
numPorts int 1
hardware_delay double 0us

Properties:

Name Value Description
display bgb=894,314;i=device/device

Gates:

Name Direction Size Description
ethg inout

Physical port of the host

Unassigned submodule parameters:

Name Type Default value Description
phy.tteOutput.tt_buffers string ""

Comma seperated list of TTBuffers that send messages to this port

phy.tteInput.ct_marker int 0

Critical traffic marker of the buffer

phy.tteInput.ct_mask int 0

Critical traffic mask of the buffer

phy.tteInput.incomings string ""

Comma seperated list of ctc modules the input uses

phy.mac.address string "auto"

MAC address as hex string (12 hex digits), or "auto". "auto" values will be replaced by a generated MAC address in init stage 0.

phy.mac.duplexMode bool true

must be set to "true", as EtherMACFullDuplex does not support half-duplex operation (parameter is present to reduce the risk of accidental misconfiguration)

phy.mac.txQueueLimit int 1000

maximum number of frames queued up for transmission in the internal queue (only used if queueModule==""); additional frames cause a runtime error

phy.mac.mtu int 1500B
cli.destAddress string ""

destination MAC address, or module path name of destination station; empty means off

cli.startTime double this.sendInterval

time of sending the first request

cli.stopTime double 0

time of finish sending, 0 means forever

cli.sendInterval double uniform(0s,1s)

interval between sending requests

cli.reqLength int 100B

length of request packets

cli.respLength int 1KiB

length of response packets

tteScheduler.tick double 80ns

Length of a tick

tteScheduler.max_drift double 16ps

Maximum clock drift (e.g 16ps for 200ppm at 80ns per tick)

tteScheduler.max_drift_change double 1ps

Maximum clock drift change per cycle

tteScheduler.cycle_ticks int 37500

Number of ticks for one cycle

tteApp.buffers string

Comma seperated list of buffer modules the application is allowed to use

bgIn.destination_gates string ""

Priority of the buffer (currently only used for rate-constrained traffic) int priority=default(-1); Critical traffic ID of the buffer int ct_id=default(0); Critical traffic marker of the buffer int ct_marker=default(0); Critical traffic mask of the buffer int ct_mask=default(0); Comma seperated list of gates where the frames of the buffer are delivered

bgIn.size int -1

Size of the buffer negative means infinite

bgIn.drop_new bool false

Dropping policy, Should the newest frame instead of the oldest frame be dropped when the buffer is full (see size parameter)

bgOut.destination_gates string ""

Priority of the buffer (currently only used for rate-constrained traffic) int priority=default(-1); Critical traffic ID of the buffer int ct_id=default(0); Critical traffic marker of the buffer int ct_marker=default(0); Critical traffic mask of the buffer int ct_mask=default(0); Comma seperated list of gates where the frames of the buffer are delivered

bgOut.size int -1

Size of the buffer negative means infinite

bgOut.drop_new bool false

Dropping policy, Should the newest frame instead of the oldest frame be dropped when the buffer is full (see size parameter)

Source code:

//
// Module for a TTEthernet Host.
// Contains a EtherLLC for best-effort traffic, a TTEPHYPort module as physical port,
// sync module (Sync) and a TTEScheduler module.
// The Host is configured by the provided TTEthernet XML network configuration
// (network_configuration parameter) and uses the device_name parameter to find its config.
// The configuration is done by the BufferManager that deletes itself at runtime.
//
// @todo Ports for redundancy!
// @todo Documentation for Applications!
//
// @see EtherLLC, TTEPHYPort, Sync, TTEScheduler, BufferManager
//
// @author Till Steinbach
module TTEEtherHost
{
    parameters:
        @display("bgb=894,314;i=device/device");
        int numApps = default(0);
        int numPorts = default(1);
        double hardware_delay @unit(s) = default(0us);
    gates:
        // Physical port of the host
        inout ethg;

    submodules:
        // Physical port of the host
        phy[numPorts]: TTEPHYPort {
            @display("p=235,255,c,50");
        }
        // LLC for best-effort traffic
        llc: EtherLLC {
            parameters:
                @display("p=141,256");
            gates:
                upperLayerIn[3];
                upperLayerOut[3];
        }

        cli: EtherAppCli {
            parameters:
                registerSAP = true;
                @display("p=60,256,col");
        }
        srv: EtherAppSrv {
            parameters:
                registerSAP = true;
                @display("p=60,169,col");
        }
        // Buffer manager that creates the buffers according to the configuration
        configurationManager: <default("BaseConfigurationManager")> like IConfigurationManager {
            @display("p=999,999");
        }
         // Sync module for synchronisation of the scheduler
        sync: <default("DummySync")> like ISync {
            @display("p=141,169");
        }
        // Scheudler for the device
        tteScheduler: TTEScheduler {
            @display("p=235,169");
        }
        tteApp[numApps]: <default("TTEAPITestApplication")> like ITTEApplication {
            @display("p=235,99");
        }
        bgIn: BGQueueBuffer {
            @display("p=141,37");
        }
        bgOut: BGQueueBuffer {
            @display("p=141,99");
        }
        bgTrafficHandle: BGTrafficHandle {
            @display("p=60,99");
        }
    connections:
        phy[0].phys <--> ethg;
        llc.lowerLayerOut --> phy[0].upperLayerIn;
        phy[0].upperLayerOut --> llc.lowerLayerIn;

        cli.out --> llc.upperLayerIn[0];
        cli.in <-- llc.upperLayerOut[0];

        srv.out --> llc.upperLayerIn[1];
        srv.in <-- llc.upperLayerOut[1];

        bgTrafficHandle.lowerLayerOut --> llc.upperLayerIn[2];
        bgTrafficHandle.lowerLayerIn <-- llc.upperLayerOut[2];
        bgTrafficHandle.out --> bgIn.in;
        bgOut.out --> bgTrafficHandle.in;
}