Zephyr Project API 4.0.0
A Scalable Open Source RTOS
Loading...
Searching...
No Matches

Connectivity Manager Connectivity API structure. More...

#include <conn_mgr_connectivity_impl.h>

Data Fields

int(* connect )(struct conn_mgr_conn_binding *const binding)
 When called, the connectivity implementation should start attempting to establish connectivity (association with a network) for the bound iface pointed to by if_conn->iface.
 
int(* disconnect )(struct conn_mgr_conn_binding *const binding)
 When called, the connectivity implementation should disconnect (disassociate), or stop any in-progress attempts to associate to a network, the bound iface pointed to by if_conn->iface.
 
void(* init )(struct conn_mgr_conn_binding *const binding)
 Called once for each iface that has been bound to a connectivity implementation using this API.
 
int(* set_opt )(struct conn_mgr_conn_binding *const binding, int optname, const void *optval, size_t optlen)
 Implementation callback for conn_mgr_if_set_opt.
 
int(* get_opt )(struct conn_mgr_conn_binding *const binding, int optname, void *optval, size_t *optlen)
 Implementation callback for conn_mgr_if_get_opt.
 

Detailed Description

Connectivity Manager Connectivity API structure.

Used to provide generic access to network association parameters and procedures

Field Documentation

◆ connect

int(* conn_mgr_conn_api::connect) (struct conn_mgr_conn_binding *const binding)

When called, the connectivity implementation should start attempting to establish connectivity (association with a network) for the bound iface pointed to by if_conn->iface.

Must be non-blocking.

Called by conn_mgr_if_connect.

◆ disconnect

int(* conn_mgr_conn_api::disconnect) (struct conn_mgr_conn_binding *const binding)

When called, the connectivity implementation should disconnect (disassociate), or stop any in-progress attempts to associate to a network, the bound iface pointed to by if_conn->iface.

Must be non-blocking.

Called by conn_mgr_if_disconnect.

◆ get_opt

int(* conn_mgr_conn_api::get_opt) (struct conn_mgr_conn_binding *const binding, int optname, void *optval, size_t *optlen)

Implementation callback for conn_mgr_if_get_opt.

Used to retrieve implementation-specific connectivity settings.

Calls to conn_mgr_if_get_opt on an iface will result in calls to this callback with the conn_mgr_conn_binding struct bound to that iface.

It is up to the connectivity implementation to interpret optname. Options can be specific to the bound iface (pointed to by if_conn->iface), or can apply to the whole connectivity implementation.

See the description of conn_mgr_if_get_opt for more details. get_opt implementations should conform to that description.

◆ init

void(* conn_mgr_conn_api::init) (struct conn_mgr_conn_binding *const binding)

Called once for each iface that has been bound to a connectivity implementation using this API.

Connectivity implementations should use this callback to perform any required per-bound-iface initialization.

Implementations may choose to gracefully handle invalid buffer lengths with partial writes, rather than raise errors, if deemed appropriate.

◆ set_opt

int(* conn_mgr_conn_api::set_opt) (struct conn_mgr_conn_binding *const binding, int optname, const void *optval, size_t optlen)

Implementation callback for conn_mgr_if_set_opt.

Used to set implementation-specific connectivity settings.

Calls to conn_mgr_if_set_opt on an iface will result in calls to this callback with the conn_mgr_conn_binding struct bound to that iface.

It is up to the connectivity implementation to interpret optname. Options can be specific to the bound iface (pointed to by if_conn->iface), or can apply to the whole connectivity implementation.

See the description of conn_mgr_if_set_opt for more details. set_opt implementations should conform to that description.

Implementations may choose to gracefully handle invalid buffer lengths with partial reads, rather than raise errors, if deemed appropriate.


The documentation for this struct was generated from the following file: