Channel ThruputMeteringChannel

Package: inet.common.misc
File: src/inet/common/misc/ThruputMeteringChannel.ned

This channels adds suport for thruput meternig to the datarate channel A cDatarateChannel extended with throughput calculation. Values get displayed on the link, using the connection's "t=" display string tag.

The display can be customized with the "format" attribute. In the format string, the following characters will get expanded:

"Current" actually means the last measurement interval, which is 10 packets or 0.1s, whichever comes first.

ThruputMeteringChannel

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.

Extends:

Name Type Description
DatarateChannel channel (no description)

Known subclasses:

Name Type Description
C channel (no description)

Networks:

Name Type Description
OSPF_AreaTest network (no description)

Parameters:

Name Type Default value Description
disabled bool false
delay double 0s

propagation delay

datarate double 0bps

bits per second; 0=infinite

ber double 0

bit error rate (BER)

per double 0

packet error rate (PER)

thruputDisplayFormat string ""

the format string for display on the link. Leave empty to disable display

Properties:

Name Value Description
class ThruputMeteringChannel

Signals:

Name Type Unit
channelBusy long
messageSent omnetpp::cMessage
messageDiscarded omnetpp::cMessage

Statistics:

Name Title Source Record Unit Interpolation Mode
packetsDiscarded constant1(messageDiscarded) count? none
busy channelBusy vector? sample-hold
utilization timeavg(channelBusy) last?
packetBytes packetBytes(messageSent) sum? B none
throughput sumPerDuration(packetBits(messageSent)) last? bps
packets constant1(messageSent) count? none

Source code:

//
// This channels adds suport for thruput meternig to the datarate channel
// A cDatarateChannel extended with throughput calculation. Values
// get displayed on the link, using the connection's "t=" display
// string tag.
//
// The display can be customized with the "format" attribute.
// In the format string, the following characters will get expanded:
//   - 'N': number of packets
//   - 'V': volume (in bytes)
//   - 'p': current packet/sec
//   - 'b': current bandwidth
//   - 'u': current channel utilization (%)
//   - 'P': average packet/sec on [0,now)
//   - 'B': average bandwidth on [0,now)
//   - 'U': average channel utilization (%) on [0,now)
// Other characters are copied verbatim.
//
// "Current" actually means the last measurement interval, which is
// 10 packets or 0.1s, whichever comes first.
//
channel ThruputMeteringChannel extends ned.DatarateChannel
{
    @class(ThruputMeteringChannel);
    string thruputDisplayFormat = default("");  // the format string for display on the link. Leave empty to disable display
}