Listens on an UDP port, and sends back each received packet to its sender. Note: when used together with UDPBasicApp, UDPBasicApp's "received packet lifetime" statistic will record round-trip times.
The following diagram shows usage relationships between types. Unresolved types are missing from the diagram.
The following diagram shows inheritance relationships for this type. Unresolved types are missing from the diagram.
Name | Type | Default value | Description |
---|---|---|---|
interfaceTableModule | string |
The path to the InterfaceTable module |
|
localPort | int |
local port to listen on |
Name | Value | Description |
---|---|---|
display | i=block/app |
Name | Direction | Size | Description |
---|---|---|---|
udpIn | input | ||
udpOut | output |
Name | Type | Unit |
---|---|---|
pk | cPacket |
Name | Title | Source | Record | Unit | Interpolation Mode |
---|---|---|---|---|---|
echoedPk | packets echoed | pk | count, sum(packetBytes), vector(packetBytes) | none |
// // Listens on an UDP port, and sends back each received packet to its sender. // Note: when used together with ~UDPBasicApp, ~UDPBasicApp's "received packet // lifetime" statistic will record round-trip times. // simple UDPEchoApp like IUDPApp { parameters: string interfaceTableModule; // The path to the InterfaceTable module int localPort; // local port to listen on @display("i=block/app"); @signal[pk](type=cPacket); @statistic[echoedPk](title="packets echoed"; source=pk; record=count,"sum(packetBytes)","vector(packetBytes)"; interpolationmode=none); gates: input udpIn @labels(UDPControlInfo/up); output udpOut @labels(UDPControlInfo/down); }