TCP provides reliable byte stream service between endpoints for applications in the Internet. The sender TCP entity puts the output of the application program into the data buffer without separation, and divides the data block into segments with appropriate length when outputting, and each segment is encapsulated in an IP packet for transmission. Each byte in a segment is assigned a sequence number, and the receiving TCP entity assembles each segment into a continuous byte stream according to the byte sequence number and gives it to the application, without knowing that these data are written by the sending application for many times. The interpretation and processing of data streams are completely completed by high-level protocols. In order to realize reliable data transmission service, TCP provides the functions of error detection, response, retransmission and sorting of data segments, provides reliable methods for establishing and disconnecting connections, and also provides mechanisms for flow control and blocking control. In order to realize these functions, the overhead of TCP is bound to be high. UDP is a simple protocol, which does not significantly increase the function and semantics of IP layer and has low overhead. But this provides unreliable and connectionless packet transmission services for applications. Messages of UDP transport protocol may be lost, duplicated, delayed and out of order. This method is especially suitable for the situation that the transmission reliability of each data is not very important, but the transmission speed of the whole network is very important. Playing video with TCP/IP on the Internet, in order to ensure the continuity of video, the data transmission speed is very high, and the reliability of data is not particularly high. Even if some data packets are lost, it will not affect the video playback. So we can take advantage of the low overhead characteristics of UDP here.