| IoT Socket Version 1.3.0 Simple IP Socket (BSD like) |

Macros
IoT Socket Options
IoT Socket Macros

Socket Option definitions. More...

## Macros
#define | IOT_SOCKET_IO_FIONBIO 1
| Non-blocking I/O (Set only, default = 0); opt_val = &nbio, opt_len = sizeof(nbio), nbio (integer): 0=blocking, non-blocking otherwise. More...
#define | IOT_SOCKET_SO_RCVTIMEO 2
| Receive timeout in ms (default = 0); opt_val = &timeout, opt_len = sizeof(timeout) More...
#define | IOT_SOCKET_SO_SNDTIMEO 3
| Send timeout in ms (default = 0); opt_val = &timeout, opt_len = sizeof(timeout) More...
#define | IOT_SOCKET_SO_KEEPALIVE 4
| Keep-alive messages (default = 0); opt_val = &keepalive, opt_len = sizeof(keepalive), keepalive (integer): 0=disabled, enabled otherwise. More...
#define | IOT_SOCKET_SO_TYPE 5
| Socket Type (Get only); opt_val = &socket_type, opt_len = sizeof(socket_type), socket_type (integer): IOT_SOCKET_SOCK_xxx. More...

## Description

Socket Option definitions.

The Socket Option specifies the socket option for which the value is to be set or obtained.

## Macro Definition Documentation

## ◆ IOT_SOCKET_IO_FIONBIO

#define IOT_SOCKET_IO_FIONBIO 1

Non-blocking I/O (Set only, default = 0); opt_val = &nbio, opt_len = sizeof(nbio), nbio (integer): 0=blocking, non-blocking otherwise.

Enables or disables the non-blocking mode for the socket.

## ◆ IOT_SOCKET_SO_RCVTIMEO

#define IOT_SOCKET_SO_RCVTIMEO 2

Receive timeout in ms (default = 0); opt_val = &timeout, opt_len = sizeof(timeout)

Specifies the time limit for receiving in blocking mode. The time limit is in milliseconds.

## ◆ IOT_SOCKET_SO_SNDTIMEO

#define IOT_SOCKET_SO_SNDTIMEO 3

Send timeout in ms (default = 0); opt_val = &timeout, opt_len = sizeof(timeout)

Specifies the time limit for sending in blocking mode. The time limit is in milliseconds.

## ◆ IOT_SOCKET_SO_KEEPALIVE

#define IOT_SOCKET_SO_KEEPALIVE 4

Keep-alive messages (default = 0); opt_val = &keepalive, opt_len = sizeof(keepalive), keepalive (integer): 0=disabled, enabled otherwise.

Enables or disables the keep-alive mode for the stream socket.

## ◆ IOT_SOCKET_SO_TYPE

#define IOT_SOCKET_SO_TYPE 5

Socket Type (Get only); opt_val = &socket_type, opt_len = sizeof(socket_type), socket_type (integer): IOT_SOCKET_SOCK_xxx.

Obtains the type of the socket.