This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| en:iot-open:networking2:transport [2024/11/03 14:07] – pczekalski | en:iot-open:networking2:transport [2024/11/03 14:21] (current) – pczekalski | ||
|---|---|---|---|
| Line 7: | Line 7: | ||
| The transport layer is responsible for end-to-end communication and provides segmentation and aggregation mechanisms, error detection and correction, flow control, port-based addressing and quality of services. IP-based protocols use two kinds of connections: | The transport layer is responsible for end-to-end communication and provides segmentation and aggregation mechanisms, error detection and correction, flow control, port-based addressing and quality of services. IP-based protocols use two kinds of connections: | ||
| * **TCP**: connection-oriented mode, where the connection between endpoints is kept open for the whole transmission time, and it is possible to detect connection breaks and interferences. TCP ensures delivery, and this mechanism is built into the Transportation layer.\\ One can imagine a TCP connection as making a phone call: while connected, you can hear the other side's speech, breathing, and background noises to tell the connection is not dropped. A dropped phone connection can be sensed, e.g., by the termination signal or simply when there is silence and no replies from the other party. Similarly, in TCP, when there is no acknowledgement for a specific timeout or after some retries, the connection is considered dropped. This way, both endpoints will be aware of the state of the connection and can ensure the quality of service.\\Examples of services using this connection on the regular Internet are Web (HTTP), FTP, and SSH.\\ TCP is more complex than UDP in terms of both transmission and implementation. | * **TCP**: connection-oriented mode, where the connection between endpoints is kept open for the whole transmission time, and it is possible to detect connection breaks and interferences. TCP ensures delivery, and this mechanism is built into the Transportation layer.\\ One can imagine a TCP connection as making a phone call: while connected, you can hear the other side's speech, breathing, and background noises to tell the connection is not dropped. A dropped phone connection can be sensed, e.g., by the termination signal or simply when there is silence and no replies from the other party. Similarly, in TCP, when there is no acknowledgement for a specific timeout or after some retries, the connection is considered dropped. This way, both endpoints will be aware of the state of the connection and can ensure the quality of service.\\Examples of services using this connection on the regular Internet are Web (HTTP), FTP, and SSH.\\ TCP is more complex than UDP in terms of both transmission and implementation. | ||
| - | * **UDP**: connectionless mode, where the sender sends the data and " | + | * **UDP**: connectionless mode, where the sender sends the data and " |
| A choice between UDP and TCP is driven by other network layers, e.g. some IoT network stacks do not provide TCP-like connections. Higher-level protocols also drive the selection of the transport layer connection standards, e.g. MQTT generally requires TCP while CoAP uses UDP; see the following chapters for details. | A choice between UDP and TCP is driven by other network layers, e.g. some IoT network stacks do not provide TCP-like connections. Higher-level protocols also drive the selection of the transport layer connection standards, e.g. MQTT generally requires TCP while CoAP uses UDP; see the following chapters for details. | ||