Kenji Arai / mbed-os_TYBLE16

Dependents:   TYBLE16_simple_data_logger TYBLE16_MP3_Air

Embed: (wiki syntax)

« Back to documentation index

Interface Identification API

Interface Identification API
[Socket API]

Functions

char * lwip_if_indextoname (unsigned int ifindex, char *ifname)
 Maps an interface index to its corresponding name.
unsigned int lwip_if_nametoindex (const char *ifname)
 Returs the interface index corresponding to name ifname.

Function Documentation

char* lwip_if_indextoname ( unsigned int  ifindex,
char *  ifname 
)

Maps an interface index to its corresponding name.

Parameters:
ifindexinterface index
ifnameshall point to a buffer of at least {IF_NAMESIZE} bytes
Returns:
If ifindex is an interface index, then the function shall return the value supplied in ifname, which points to a buffer now containing the interface name. Otherwise, the function shall return a NULL pointer.

Definition at line 61 of file lwip_if_api.c.

unsigned int lwip_if_nametoindex ( const char *  ifname )

Returs the interface index corresponding to name ifname.

Parameters:
ifnameInterface name
Returns:
The corresponding index if ifname is the name of an interface; otherwise, zero.

Definition at line 86 of file lwip_if_api.c.