EthernetPreemptingPhyLayer¶
Package: inet.physicallayer.wired.ethernet
compound module EthernetPreemptingPhyLayer
(no description)
Usage diagram¶
Inheritance diagram¶
Parameters¶
Name |
Type |
Default value |
Description |
|---|---|---|---|
bitrate |
double |
Properties¶
Name |
Value |
Description |
|---|---|---|
display |
i=block/layer |
Gates¶
Name |
Direction |
Size |
Description |
|---|---|---|---|
upperLayerIn |
input |
||
upperLayerOut |
output |
||
lowerLayerIn |
input |
||
lowerLayerOut |
output |
Unassigned submodule parameters¶
Name |
Type |
Default value |
Description |
|---|---|---|---|
c1.displayStringTextFormat |
string |
“classified %p pk (%l)” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
c1.reverseOrder |
bool |
false |
|
c1.classifierClass |
string |
“inet::PacketFragmentTagClassifier” |
Determines the output queue of packets, the parameter must be the name of a C++ class which implements the IPacketClassifierFunction interface and is registered via Register_Class |
phyHeaderInserter.displayStringTextFormat |
string |
“processed {numProcessedPackets} pk ({processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
fragmentPhyHeaderInserter.displayStringTextFormat |
string |
“processed {numProcessedPackets} pk ({processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
m1.displayStringTextFormat |
string |
“passed %p pk (%l)” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
m1.forwardServiceRegistration |
bool |
true |
|
m1.forwardProtocolRegistration |
bool |
true |
|
interFrameGapInserter.displayStringTextFormat |
string |
“delayed %p pk (%l)\nifg: %g” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
interFrameGapInserter.clockModule |
string |
“” |
Relative path of a module that implements IClock(1,:ref:2 <neddoc-msg-inet-iclock>); optional |
interFrameGapInserter.initialChannelBusy |
bool |
false |
Assume that the channel was busy before the simulation started |
interFrameGapInserter.duration |
double |
96s / dropUnit(parent.bitrate) |
|
outboundEmitter.displayStringTextFormat |
string |
“processed {numProcessedPackets} pk ({processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
outboundEmitter.packetFilter |
object |
“*” |
Which packets are considered, matches all packets by default |
outboundEmitter.direction |
string |
“undefined” |
|
outboundEmitter.signalName |
string |
||
transmitter.displayStringTextFormat |
string |
“processed {numProcessedPackets} pk ({processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
transmitter.clockModule |
string |
“” |
Relative path of a module that implements IClock(1,:ref:2 <neddoc-msg-inet-iclock>); optional |
transmitter.datarate |
double |
parent.bitrate |
|
m2.displayStringTextFormat |
string |
“passed %p pk (%l)” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
m2.forwardServiceRegistration |
bool |
true |
|
m2.forwardProtocolRegistration |
bool |
true |
|
fragmentPhyHeaderChecker.displayStringTextFormat |
string |
“dropped {numDroppedPackets}/{numProcessedPackets} pk ({droppedTotalLength}/{processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
fragmentPhyHeaderChecker.backpressure |
bool |
false |
|
phyHeaderChecker.displayStringTextFormat |
string |
“dropped {numDroppedPackets}/{numProcessedPackets} pk ({droppedTotalLength}/{processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
phyHeaderChecker.backpressure |
bool |
false |
|
c2.displayStringTextFormat |
string |
“classified %p pk (%l)” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
c2.reverseOrder |
bool |
false |
|
c2.classifierClass |
string |
“inet::PacketEthernetPreambleTypeClassifier” |
Determines the output queue of packets, the parameter must be the name of a C++ class which implements the IPacketClassifierFunction interface and is registered via Register_Class |
inboundEmitter.displayStringTextFormat |
string |
“processed {numProcessedPackets} pk ({processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
inboundEmitter.packetFilter |
object |
“*” |
Which packets are considered, matches all packets by default |
inboundEmitter.direction |
string |
“undefined” |
|
inboundEmitter.signalName |
string |
||
receiver.displayStringTextFormat |
string |
“processed {numProcessedPackets} pk ({processedTotalLength})” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
receiver.datarate |
double |
parent.bitrate |
Source code¶
module EthernetPreemptingPhyLayer like IEthernetPhyLayer
{
parameters:
volatile double bitrate @unit(bps);
outboundEmitter.signalName = "packetSentToLower";
outboundEmitter.direction = "outbound";
inboundEmitter.signalName = "packetReceivedFromLower";
inboundEmitter.direction = "inbound";
*.bitrate = default(this.bitrate);
@display("i=block/layer");
gates:
input upperLayerIn;
output upperLayerOut;
input lowerLayerIn;
output lowerLayerOut;
submodules:
c1: PacketClassifier {
classifierClass = default("inet::PacketFragmentTagClassifier");
@display("p=200,100");
}
phyHeaderInserter: <default("EthernetPhyHeaderInserter")> like IPacketFlow {
@display("p=100,200");
}
fragmentPhyHeaderInserter: <default("EthernetFragmentPhyHeaderInserter")> like IPacketFlow {
@display("p=300,200");
}
m1: PacketMultiplexer {
@display("p=200,300");
}
interFrameGapInserter: InterpacketGapInserter {
duration = default(96s / dropUnit(parent.bitrate));
@display("p=200,400");
}
outboundEmitter: <default("PacketEmitter")> like IPacketFlow {
@display("p=200,500");
}
transmitter: <default("StreamThroughTransmitter")> like IPacketTransmitter {
datarate = default(parent.bitrate);
@display("p=200,600");
}
m2: PacketMultiplexer {
@display("p=600,100");
}
fragmentPhyHeaderChecker: <default("EthernetFragmentPhyHeaderChecker")> like IPacketFilter {
@display("p=700,200");
}
phyHeaderChecker: <default("EthernetPhyHeaderChecker")> like IPacketFilter {
@display("p=500,200");
}
c2: PacketClassifier {
classifierClass = default("inet::PacketEthernetPreambleTypeClassifier");
@display("p=600,300");
}
inboundEmitter: <default("PacketEmitter")> like IPacketFlow {
@display("p=600,500");
}
receiver: <default("DestreamingReceiver")> like IPacketReceiver {
datarate = default(parent.bitrate);
@display("p=600,600");
}
connections:
upperLayerIn --> { @display("m=n"); } --> c1.in;
c1.out++ --> phyHeaderInserter.in;
c1.out++ --> fragmentPhyHeaderInserter.in;
phyHeaderInserter.out --> m1.in++;
fragmentPhyHeaderInserter.out --> m1.in++;
m1.out --> interFrameGapInserter.in;
interFrameGapInserter.out --> outboundEmitter.in;
outboundEmitter.out --> transmitter.in;
transmitter.out --> { @display("m=s"); } --> lowerLayerOut;
lowerLayerIn --> { @display("m=s"); } --> receiver.in;
receiver.out --> inboundEmitter.in;
inboundEmitter.out --> c2.in;
c2.out++ --> phyHeaderChecker.in;
c2.out++ --> fragmentPhyHeaderChecker.in;
phyHeaderChecker.out --> m2.in++;
fragmentPhyHeaderChecker.out --> m2.in++;
m2.out --> { @display("m=n"); } --> upperLayerOut;
}
File: src/inet/physicallayer/wired/ethernet/EthernetPreemptingPhyLayer.ned