Multicasting with C Sockets
暂无分享,去创建一个
Sockets are an application programming interface (API) that provides basic function calls to send data across a network. The most common use of the sockets API is to send a TCP data stream from one host to another. TCP also adds important features such as connections, multiplexing or demultiplexing, in-order delivery, reliability, and congestion control on top of the IP layer. This chapter introduces the C sockets API for multicast. It describes multicast and explores how the protocols work in the Internet to deliver multicast packets. The chapter builds out the API and its options through the discussion of simple examples including multicast sender and receiver programs. The steps required to create a C application that sends multicast packets include: creating a socket, setting the scope for the packets, sending the data on the socket and finally closing the socket. A more recent development in multicast is called source specific multicast (SSM), which adds additional functionality into multicast.