MDNSD#
Functions#
Initialize the MDNSD service in device. It creates MDNS daemon. This is a blocking API.
Add a MDNSD service. This is a blocking API.
Delete the MDNSD service. This is a blocking API.
Function Documentation#
rsi_mdnsd_init#
int32_t rsi_mdnsd_init (uint8_t ip_version, uint16_t ttl, uint8_t * host_name)
Initialize the MDNSD service in device. It creates MDNS daemon. This is a blocking API.
[in] | ip_version | - Select the IP version. 4 – to select IPv4, |
[in] | ttl | - Time to live in seconds for which service should be active |
[in] | host_name | - Host name that is used as host name in Type A record. |
Returns
0 - Success
Negative value - Failure
Note
Precondition - rsi_config_ipaddress() API needs to be called before this API.
34
of file network/protocols/rsi_mdnsd.c
rsi_mdnsd_register_service#
int32_t rsi_mdnsd_register_service (uint16_t port, uint16_t ttl, uint8_t more, uint8_t * service_ptr_name, uint8_t * service_name, uint8_t * service_text)
Add a MDNSD service. This is a blocking API.
[in] | port | - Port number on which service should be added. |
[in] | ttl | - Time to live. This is time in seconds for which service should be active |
[in] | more | - This byte should be set to '1' when there are more services to add. |
[in] | service_ptr_name | - Name to be added in Type-PTR record |
[in] | service_name | - Name to be added in Type-SRV record (service name) |
[in] | service_text | - Text field to be added in Type-TXT record |
Returns
0 - Success
Negative value - Failure
Note
Precondition - rsi_config_ipaddress() API needs to be called before this API.
Currently, only one service registration is supported
140
of file network/protocols/rsi_mdnsd.c
rsi_mdnsd_deinit#
int32_t rsi_mdnsd_deinit (void )
Delete the MDNSD service. This is a blocking API.
[in] |
Returns
0 - Success
Negative value - Failure
Note
Precondition - rsi_config_ipaddress() API needs to be called before this API.
254
of file network/protocols/rsi_mdnsd.c