lwIP  2.1.0
Lightweight IP stack
Socket API

Modules

 Interface Identification API
 
 NETDB API
 

Macros

#define accept(s, addr, addrlen)   lwip_accept(s,addr,addrlen)
 
#define bind(s, name, namelen)   lwip_bind(s,name,namelen)
 
#define shutdown(s, how)   lwip_shutdown(s,how)
 
#define getpeername(s, name, namelen)   lwip_getpeername(s,name,namelen)
 
#define getsockname(s, name, namelen)   lwip_getsockname(s,name,namelen)
 
#define setsockopt(s, level, optname, opval, optlen)   lwip_setsockopt(s,level,optname,opval,optlen)
 
#define getsockopt(s, level, optname, opval, optlen)   lwip_getsockopt(s,level,optname,opval,optlen)
 
#define closesocket(s)   lwip_close(s)
 
#define connect(s, name, namelen)   lwip_connect(s,name,namelen)
 
#define listen(s, backlog)   lwip_listen(s,backlog)
 
#define recv(s, mem, len, flags)   lwip_recv(s,mem,len,flags)
 
#define recvmsg(s, message, flags)   lwip_recvmsg(s,message,flags)
 
#define recvfrom(s, mem, len, flags, from, fromlen)   lwip_recvfrom(s,mem,len,flags,from,fromlen)
 
#define send(s, dataptr, size, flags)   lwip_send(s,dataptr,size,flags)
 
#define sendmsg(s, message, flags)   lwip_sendmsg(s,message,flags)
 
#define sendto(s, dataptr, size, flags, to, tolen)   lwip_sendto(s,dataptr,size,flags,to,tolen)
 
#define socket(domain, type, protocol)   lwip_socket(domain,type,protocol)
 
#define select(maxfdp1, readset, writeset, exceptset, timeout)   lwip_select(maxfdp1,readset,writeset,exceptset,timeout)
 
#define poll(fds, nfds, timeout)   lwip_poll(fds,nfds,timeout)
 
#define ioctlsocket(s, cmd, argp)   lwip_ioctl(s,cmd,argp)
 
#define inet_ntop(af, src, dst, size)   lwip_inet_ntop(af,src,dst,size)
 
#define inet_pton(af, src, dst)   lwip_inet_pton(af,src,dst)
 
#define read(s, mem, len)   lwip_read(s,mem,len)
 
#define readv(s, iov, iovcnt)   lwip_readv(s,iov,iovcnt)
 
#define write(s, dataptr, len)   lwip_write(s,dataptr,len)
 
#define writev(s, iov, iovcnt)   lwip_writev(s,iov,iovcnt)
 
#define close(s)   lwip_close(s)
 
#define fcntl(s, cmd, val)   lwip_fcntl(s,cmd,val)
 
#define ioctl(s, cmd, argp)   lwip_ioctl(s,cmd,argp)
 

Detailed Description

BSD-style socket API.
Thread-safe, to be called from non-TCPIP threads only.
Can be activated by defining LWIP_SOCKET to 1.
Header is in posix/sys/socket.h
The socket API is a compatibility API for existing applications, currently it is built on top of the sequential API. It is meant to provide all functions needed to run socket API applications running on other platforms (e.g. unix / windows etc.). However, due to limitations in the specification of this API, there might be incompatibilities that require small modifications of existing programs.

Macro Definition Documentation

◆ accept

#define accept (   s,
  addr,
  addrlen 
)    lwip_accept(s,addr,addrlen)

◆ bind

#define bind (   s,
  name,
  namelen 
)    lwip_bind(s,name,namelen)

◆ close

#define close (   s)    lwip_close(s)

◆ closesocket

#define closesocket (   s)    lwip_close(s)

◆ connect

#define connect (   s,
  name,
  namelen 
)    lwip_connect(s,name,namelen)

◆ fcntl

#define fcntl (   s,
  cmd,
  val 
)    lwip_fcntl(s,cmd,val)

◆ getpeername

#define getpeername (   s,
  name,
  namelen 
)    lwip_getpeername(s,name,namelen)

◆ getsockname

#define getsockname (   s,
  name,
  namelen 
)    lwip_getsockname(s,name,namelen)

◆ getsockopt

#define getsockopt (   s,
  level,
  optname,
  opval,
  optlen 
)    lwip_getsockopt(s,level,optname,opval,optlen)

◆ inet_ntop

#define inet_ntop (   af,
  src,
  dst,
  size 
)    lwip_inet_ntop(af,src,dst,size)

◆ inet_pton

#define inet_pton (   af,
  src,
  dst 
)    lwip_inet_pton(af,src,dst)

◆ ioctl

#define ioctl (   s,
  cmd,
  argp 
)    lwip_ioctl(s,cmd,argp)

◆ ioctlsocket

#define ioctlsocket (   s,
  cmd,
  argp 
)    lwip_ioctl(s,cmd,argp)

◆ listen

#define listen (   s,
  backlog 
)    lwip_listen(s,backlog)

◆ poll

#define poll (   fds,
  nfds,
  timeout 
)    lwip_poll(fds,nfds,timeout)

◆ read

#define read (   s,
  mem,
  len 
)    lwip_read(s,mem,len)

◆ readv

#define readv (   s,
  iov,
  iovcnt 
)    lwip_readv(s,iov,iovcnt)

◆ recv

#define recv (   s,
  mem,
  len,
  flags 
)    lwip_recv(s,mem,len,flags)

◆ recvfrom

#define recvfrom (   s,
  mem,
  len,
  flags,
  from,
  fromlen 
)    lwip_recvfrom(s,mem,len,flags,from,fromlen)

◆ recvmsg

#define recvmsg (   s,
  message,
  flags 
)    lwip_recvmsg(s,message,flags)

◆ select

#define select (   maxfdp1,
  readset,
  writeset,
  exceptset,
  timeout 
)    lwip_select(maxfdp1,readset,writeset,exceptset,timeout)

◆ send

#define send (   s,
  dataptr,
  size,
  flags 
)    lwip_send(s,dataptr,size,flags)

◆ sendmsg

#define sendmsg (   s,
  message,
  flags 
)    lwip_sendmsg(s,message,flags)

◆ sendto

#define sendto (   s,
  dataptr,
  size,
  flags,
  to,
  tolen 
)    lwip_sendto(s,dataptr,size,flags,to,tolen)

◆ setsockopt

#define setsockopt (   s,
  level,
  optname,
  opval,
  optlen 
)    lwip_setsockopt(s,level,optname,opval,optlen)

◆ shutdown

#define shutdown (   s,
  how 
)    lwip_shutdown(s,how)

◆ socket

#define socket (   domain,
  type,
  protocol 
)    lwip_socket(domain,type,protocol)

◆ write

#define write (   s,
  dataptr,
  len 
)    lwip_write(s,dataptr,len)

◆ writev

#define writev (   s,
  iov,
  iovcnt 
)    lwip_writev(s,iov,iovcnt)