Zephyr API Documentation 4.5.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
conn_mgr_monitor.h File Reference

API for monitoring network connections and interfaces. More...

#include <errno.h>
#include <stddef.h>
#include <stdint.h>
#include <zephyr/kernel.h>
#include <zephyr/net/net_ip.h>
#include <zephyr/sys/clock.h>
#include <zephyr/sys/util.h>

Go to the source code of this file.

Macros

Readiness flags

#define CONN_MGR_READY_IPV4   BIT(0)
 An iface is ready with IPv4, see NET_EVENT_L4_IPV4_CONNECTED.
#define CONN_MGR_READY_IPV6   BIT(1)
 An iface is ready with IPv6, see NET_EVENT_L4_IPV6_CONNECTED.
#define CONN_MGR_READY_IP_ANY   BIT(2)
 CONN_MGR_READY_IPV4 or CONN_MGR_READY_IPV6 is set.
#define CONN_MGR_READY_DNS   BIT(3)
 A unicast DNS server is configured for a ready IP family, or name resolution is offloaded, see conn_mgr_dns_is_ready.

Functions

void conn_mgr_mon_resend_status (void)
 Resend L4 connectivity and DNS readiness events depending on current status.
bool conn_mgr_dns_is_ready (void)
 Check whether name resolution is currently available.
uint32_t conn_mgr_get_readiness (void)
 Get the current readiness flags.
net_sa_family_t conn_mgr_get_ready_addr_family (void)
 Get the address family to use in getaddrinfo() hints.
int conn_mgr_wait_ready (uint32_t mask, uint32_t *last_seen, k_timeout_t timeout)
 Wait until it is time to try to connect.
void conn_mgr_ignore_iface (struct net_if *iface)
 Mark an iface to be ignored by conn_mgr.
void conn_mgr_watch_iface (struct net_if *iface)
 Watch (stop ignoring) an iface.
bool conn_mgr_is_iface_ignored (struct net_if *iface)
 Check whether the provided iface is currently ignored.
void conn_mgr_ignore_l2 (const struct net_l2 *l2)
 Mark an L2 to be ignored by conn_mgr.
void conn_mgr_watch_l2 (const struct net_l2 *l2)
 Watch (stop ignoring) an L2.

Detailed Description

API for monitoring network connections and interfaces.