Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

read(2)

write(2)

getmsg(2)

putmsg(2)

socket(2)

bind(2)

connect(2)

send(2)

sendto(2)

recv(2)

recvfrom(2)

streamio(7)

tcp(7)

clone(7)

ip(7)

UDP(7)  —  

NAME

udp − user datagram protocol (UDP) interface

DESCRIPTION

udp is a (N by 1) STREAMS multiplexor.  The upstream side (N) is clonable (see clone(7)).  The downstream side is the ip(7) multiplexor.  udp provides a simple, unreliable datagram protocol (UDP) service.  Each udp stream supports two abstractions: socket abstraction as used in the BSD systems and Transport Level Interface (TLI) abstraction as used in the System V Release 3. 

In the socket abstraction, udp(7) can operate in either “connection” or “connectionless” mode.  In the former, the user has to connect(2) to the peer first.  Then the data transfer can take place via the normal read(2) or write(2) system calls.  In the latter, the each data transfer may address to a different peer.  User uses the putmsg(2) and getmsg(2) system calls for data transfer.  Each transfer unit (called a “message” in the STREAMS parlance) contains an M_PROTO block which encodes the address, followed by M_DATA blocks.  The address is specified in the format of struct sockaddr_in as described in <netinet/in.h>. 

In the TLI abstraction, each transfer contains an M_PROTO block and some M_DATA blocks.  The M_PROTO has the type T_UNITDATA_REQ for output and T_UNITDATA_IND for input.  The address is specified in the format of struct sockaddr_in as described in <netinet/in.h>. 

COMMAND FUNCTIONS

udp recognizes the following ioctl commands; their interpretations are described in tcp(7). 

I_PUSH
I_POP
SOCK_ON
SOCK_BIND
SOCK_CONNECT
SOCK_SHUTDOWN
SOCK_GETNAME
SOCK_GETPEER

FILES

/dev/udp udp clone device

/dev/udp0 udp control channel

SEE ALSO

read(2), write(2), getmsg(2), putmsg(2), socket(2), bind(2), connect(2), send(2), sendto(2), recv(2), recvfrom(2)
streamio(7), tcp(7), clone(7), ip(7)

September 02, 1992

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026