Package: inet.transportlayer.rtp
Rtp
simple moduleThe Rtp module is the center of the Rtp layer of an endsystem. It communicates with the application, and sends and receives Rtp data packets.
Much of the work is done by dynamically created Profile, and Payload Sender and Receiver modules (the latter two are created by Profile).
See ~RtpProfile, ~RtpAvProfile
Inheritance diagram
The following diagram shows inheritance relationships for this type. Unresolved types are missing from the diagram.
Used in compound modules
| Name | Type | Description |
|---|---|---|
| RtpHost | compound module |
A network node with Real-time Transport Protocol (RTP) support. Extends StandardHost by adding RTP-specific components for real-time multimedia streaming applications. |
Extends
| Name | Type | Description |
|---|---|---|
| SimpleModule | simple module |
Base module for all INET simple modules. |
Parameters
| Name | Type | Default value | Description |
|---|---|---|---|
| displayStringTextFormat | string | "" |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
| interfaceTableModule | string |
The path to the InterfaceTable module |
|
| routingTableModule | string |
Properties
| Name | Value | Description |
|---|---|---|
| class | Rtp | |
| display | i=block/buffer |
Gates
| Name | Direction | Size | Description |
|---|---|---|---|
| appIn | input | ||
| profileIn | input | ||
| rtcpIn | input | ||
| udpIn | input | ||
| appOut | output | ||
| profileOut | output | ||
| rtcpOut | output | ||
| udpOut | output |
Signals
| Name | Type | Unit | Description |
|---|---|---|---|
| packetReceived | cPacket |
Statistics
| Name | Title | Source | Record | Unit | Interpolation Mode | Description |
|---|---|---|---|---|---|---|
| packetReceived | packets received | packetReceived | count, sum(packetBytes), vector(packetBytes) | none | ||
| endToEndDelay | end-to-end delay | dataAge(packetReceived) | histogram, vector | s | none |
Source code
// // The Rtp module is the center of the Rtp layer of an endsystem. // It communicates with the application, and sends and receives Rtp data // packets. // // Much of the work is done by dynamically created Profile, and Payload // Sender and Receiver modules (the latter two are created by Profile). // // See ~RtpProfile, ~RtpAvProfile // //# TODO Translate: //# The Rtp module receives the following messages from the application through the `appIn` gate: //# a msg containing a ~RtpControlInfo derived controlinfo. //# - ~RtpCiEnterSession: Enter new session //# Create and initialize an ~RtpProfile module for the session. //# params: `profileName`, `commonName`, bandwidth, `destinationAddress`, port //# - ~RtpCiCreateSenderModule: //# Send a msg to the profile to create a new module for sending the `fileName` file. //# params: ssrc, `payloadType`, `fileName` //# - ~RtpCiDeleteSenderModule: //# Send a msg to the profile to delete the sender module. //# params: ssrc //# - ~RtpCiSenderControl: //# Send a msg to the profile to execute the <command> command. //# params: ssrc, command (see ~RtpSenderControlMessageCommands), parameter1, parameter2 //# - ~RtpCiLeaveSession: Leave session //# Delete ~RtpProfile module. //# params: --- //# - //# The Rtp module sends the following messages to the application through the `appOut` gate: //# A ~RtpControlMsg msg containing a ~RtpControlInfo derived: //# - ~RtpCiSenderModuleCreated: //# Sends the ssrc associated with the created module to the App. //# params: ssrc //# - ~RtpCiSenderModuleDeleted: //# Notifies the App that the module has been deleted. //# params: ssrc //# - ~RtpCiSenderStatus: //# Sends the module status to the App. (PLAYING, FINISHED, STOPPED, PAUSED) //# params: ssrc, status (see ~RtpSenderStatus), `timeStamp` //# - ~RtpCiSessionEntered: //# Notifies the App that a new session (~RtpProfile) has been created. //# params: ssrc //# - ~RtpCiSessionLeft: //# Notifies the App that the session has ended and deletes the ~RtpProfile. //# params: --- simple Rtp extends SimpleModule { parameters: @class(Rtp); string interfaceTableModule; // The path to the InterfaceTable module string routingTableModule; @display("i=block/buffer"); @signal[packetReceived](type=cPacket); @statistic[packetReceived](title="packets received"; source=packetReceived; record=count,"sum(packetBytes)","vector(packetBytes)"; interpolationmode=none); @statistic[endToEndDelay](title="end-to-end delay"; source="dataAge(packetReceived)"; unit=s; record=histogram,vector; interpolationmode=none); gates: input appIn @labels(RtpInterfacePacket/down); input profileIn @labels(RtpInnerPacket); input rtcpIn @labels(RtpInnerPacket); input udpIn @labels(UdpCommand/up); output appOut @labels(RtpInterfacePacket/up); output profileOut @labels(RtpInnerPacket); output rtcpOut @labels(RtpInnerPacket); output udpOut @labels(UdpCommand/down); }File: src/inet/transportlayer/rtp/Rtp.ned