mdns_query() function
Query mDNS for host or service Note that querying PTR types sends Multicast query, all other types send Unicast queries
Arguments
name
service instance or host name (NULL for PTR queries)
service_type
service type (_http, _arduino, _ftp etc.) (NULL for host queries)
proto
service protocol (_tcp, _udp, etc.) (NULL for host queries)
type
type of query (MDNS_TYPE_*)
timeout
time in milliseconds to wait for answers.
max_results
maximum results to be collected
results
pointer to the results of the query results must be freed using mdns_query_results_free below
Return value
- ESP_OK success - ESP_ERR_INVALID_STATE mDNS is not running - ESP_ERR_NO_MEM memory error - ESP_ERR_INVALID_ARG timeout was not given
mdns_query() is called by 7 functions and calls 1 function:
![]()
mdns_query()
mdns_query():
![]()
mdns_query()