Zephyr Project API 3.7.0
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
Wi-Fi Network Manager API

Wi-Fi Network manager API. More...

Data Structures

struct  wifi_nm_mgd_iface
 WiFi Network Managed interfaces. More...
 
struct  wifi_nm_instance
 WiFi Network manager instance. More...
 

Enumerations

enum  wifi_nm_iface_type { WIFI_TYPE_STA = 0 , WIFI_TYPE_SAP }
 Types of Wi-Fi interface. More...
 

Functions

struct wifi_nm_instancewifi_nm_get_instance (const char *name)
 Get a Network manager instance for a given name.
 
struct wifi_nm_instancewifi_nm_get_instance_iface (struct net_if *iface)
 Get a Network manager instance for a given interface.
 
unsigned char wifi_nm_get_type_iface (struct net_if *iface)
 Get a Wi-Fi type for a given interface.
 
bool wifi_nm_iface_is_sta (struct net_if *iface)
 Check if the interface is a Wi-Fi station interface.
 
bool wifi_nm_iface_is_sap (struct net_if *iface)
 Check if the interface is a Wi-Fi Soft AP interface.
 
int wifi_nm_register_mgd_iface (struct wifi_nm_instance *nm, struct net_if *iface)
 Register a managed interface.
 
int wifi_nm_register_mgd_type_iface (struct wifi_nm_instance *nm, enum wifi_nm_iface_type type, struct net_if *iface)
 Register a managed interface.
 
int wifi_nm_unregister_mgd_iface (struct wifi_nm_instance *nm, struct net_if *iface)
 Unregister managed interface.
 

Detailed Description

Wi-Fi Network manager API.

Enumeration Type Documentation

◆ wifi_nm_iface_type

#include <include/zephyr/net/wifi_nm.h>

Types of Wi-Fi interface.

Enumerator
WIFI_TYPE_STA 

IEEE 802.11 Wi-Fi Station.

WIFI_TYPE_SAP 

IEEE 802.11 Wi-Fi Soft AP.

Function Documentation

◆ wifi_nm_get_instance()

struct wifi_nm_instance * wifi_nm_get_instance ( const char *  name)

#include <include/zephyr/net/wifi_nm.h>

Get a Network manager instance for a given name.

Parameters
nameName of the Network manager instance

◆ wifi_nm_get_instance_iface()

struct wifi_nm_instance * wifi_nm_get_instance_iface ( struct net_if iface)

#include <include/zephyr/net/wifi_nm.h>

Get a Network manager instance for a given interface.

Parameters
ifaceInterface

◆ wifi_nm_get_type_iface()

unsigned char wifi_nm_get_type_iface ( struct net_if iface)

#include <include/zephyr/net/wifi_nm.h>

Get a Wi-Fi type for a given interface.

Parameters
ifaceInterface

◆ wifi_nm_iface_is_sap()

bool wifi_nm_iface_is_sap ( struct net_if iface)

#include <include/zephyr/net/wifi_nm.h>

Check if the interface is a Wi-Fi Soft AP interface.

Parameters
ifaceInterface
Return values
trueIf the interface is a Wi-Fi Soft AP interface.

◆ wifi_nm_iface_is_sta()

bool wifi_nm_iface_is_sta ( struct net_if iface)

#include <include/zephyr/net/wifi_nm.h>

Check if the interface is a Wi-Fi station interface.

Parameters
ifaceInterface
Return values
trueIf the interface is a Wi-Fi station interface.

◆ wifi_nm_register_mgd_iface()

int wifi_nm_register_mgd_iface ( struct wifi_nm_instance nm,
struct net_if iface 
)

#include <include/zephyr/net/wifi_nm.h>

Register a managed interface.

Parameters
nmPointer to Network manager instance
ifaceManaged interface
Return values
0If successful.
-EINVALIf invalid parameters were passed.
-ENOTSUPIf the interface is not a Wi-Fi interface.
-ENOMEMIf the maximum number of managed interfaces has been reached.

◆ wifi_nm_register_mgd_type_iface()

int wifi_nm_register_mgd_type_iface ( struct wifi_nm_instance nm,
enum wifi_nm_iface_type  type,
struct net_if iface 
)

#include <include/zephyr/net/wifi_nm.h>

Register a managed interface.

Parameters
nmPointer to Network manager instance
typeWi-Fi type
ifaceManaged interface
Return values
0If successful.
-EINVALIf invalid parameters were passed.
-ENOTSUPIf the interface is not a Wi-Fi interface.
-ENOMEMIf the maximum number of managed interfaces has been reached.

◆ wifi_nm_unregister_mgd_iface()

int wifi_nm_unregister_mgd_iface ( struct wifi_nm_instance nm,
struct net_if iface 
)

#include <include/zephyr/net/wifi_nm.h>

Unregister managed interface.

Parameters
nmPointer to Network manager instance
ifaceInterface
Returns
int 0 for OK; -EINVAL for invalid parameters; -ENOENT if interface is not registered with the Network manager.