Briefly understand the TCP/IP protocol stack

What is TCP/IP protocol?

TCP/IP is the general name for various protocol families related to the Internet. If computers and network devices are to communicate with each other, both parties must be based on the same method. For example, rules such as how to detect communication targets, which side initiates communication first, which language to use for communication, and how to end communication need to be determined in advance. Communication between different hardware and operating systems all require a Rules, and we call these rules protocols.

Hierarchical management of TCP/IP protocol

The most important point in the TCP/IP protocol is layering. The TCP/IP protocol suite consists of application layer, transport layer, network layer, data link layer and physical layer. After layering the TCP/IP protocol, if the design is modified somewhere later, there is no need to replace all of them, only the changed layers need to be replaced. And from a design perspective, it has become simpler. Applications at the application layer can only consider the tasks assigned to themselves, and do not need to figure out where the other party is on the earth, how to transmit, how to ensure the arrival rate, etc.

Let’s take a look at these layers from bottom to top. The lower we go, the closer we get to the hardware:

DTU/Edge Gateway/Plataforma IoT/Módulo GatewayDTU/Edge Gateway/Plataforma IoT/Módulo Gateway

physical layer

This layer is responsible for the transmission of bit streams between nodes, that is, responsible for physical transmission. The protocols at this layer are related to both the link and the transmission medium. In layman’s terms, it is the physical means of connecting computers.

data link layer

Controls the communication between the network layer and the physical layer, and its main function is to ensure reliable data transmission on the physical line. In order to ensure transmission, the data received from the network layer is divided into specific frames that can be transmitted by the physical layer. A frame is a structural packet used to move data structures. It contains not only the original data, but also the physical addresses of the sender and receiver as well as error correction and control information. The address determines where the frame will be sent, while the error correction and control information ensures that the frame arrives error-free. If the receiving point detects an error in the transmitted data when transmitting data, it will notify the sender to resend the frame.

Network layer

Decide how to route data from sender to receiver. The network layer determines the best way from node A to node B in the network by comprehensively considering transmission priority, network congestion, quality of service, and cost of alternative routes. That is, establishing host-to-host communication.

transport layer

This layer provides end-to-end communication for applications on both hosts. The transport layer has two transport protocols: TCP (Transmission Control Protocol) and UDP (User Datagram Protocol). Among them, TCP is a reliable connection-oriented protocol, and UDP is an unreliable or connectionless protocol.

Application layer

After the application receives the data from the transport layer, it must interpret it. Interpretation must specify the format in advance, and the application layer specifies the data format of the application. The main protocols are: HTTP, FTP, Telent, etc.

TCP and UDP

TCP/UDP are both transport layer protocols, but they have different special effects and different application scenarios.

Message-oriented

The message-oriented transmission method is that the application layer hands over a message of any length to UDP, and UDP sends a message of any length, that is, one message is sent at a time. Therefore, the application must choose an appropriately sized packet.

byte stream oriented

Although the interaction between the application and TCP is one data block (of varying sizes) at a time, TCP treats the application as a series of unstructured byte streams. TCP has a buffer. When the data block transmitted by the program is too long, TCP can divide it into shorter blocks and then transmit it.

Resumir

The above content is a brief introduction to the TCP/IP protocol stack. In fact, each layer model of the TCP/IP protocol has many protocols, and each protocol has many things to do. We must first have a clear context structure and grasp the most basic functions of each layer of the model, and then enrich the details, which may make it easier to understand.

X

Please enable JavaScript in your browser to complete this form.
Introduza os detalhes do produto, como a configuração da interface, o ambiente, etc., e outros requisitos específicos para receber um orçamento exato.

pt_PTPortuguese
Please enable JavaScript in your browser to complete this form.
Introduza os detalhes do produto, como a configuração da interface, o ambiente, etc., e outros requisitos específicos para receber um orçamento exato.