2.0.0.4R9
Software Development Kit
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules
DNS client

Functions

bool ltrx_host_lookup (uint8_t zeroBasedInterface, const char *hostname, uint32_t timeout_ms, struct ltrx_ip_address *ipaddr)
 Host lookup. More...
 

Detailed Description

The Domain Name System (DNS) client resolves DNS names, returning an IP address.

Function Documentation

bool ltrx_host_lookup ( uint8_t  zeroBasedInterface,
const char *  hostname,
uint32_t  timeout_ms,
struct ltrx_ip_address ipaddr 
)

Host lookup.

Return values
trueSuccess.
falseFailed.
Parameters
[in]zeroBasedInterfaceIndex for the desired interface.
  • NETS_SOFTAP_START for ap0.
  • NETS_ETHERNET_START for eth0.
  • NETS_WLAN_START for wlan0.
[in]hostnameHost name to look up.
[in]timeout_msTimeout in milliseconds.
[out]ipaddrThe IP address looked up, if successful