|
arduino-audio-tools
|
Login to WiFi using Zephyr's wifi_mgmt / net_mgmt API. Access via the global object ZEPHYR_WIFI. More...
#include <WiFiZephyr.h>
Public Member Functions | |
| bool | begin (const char *ssid, const char *password) |
| void | end () |
| const struct in_addr & | ip () const |
| bool | isConnected () |
| const char * | localIP () |
| void | setPowerSave (enum wifi_ps mode) |
| wifi_status_t | status () |
Protected Member Functions | |
| bool | setupWIFI (const char *ssid, const char *password) |
Static Protected Member Functions | |
| static void | ip_event_handler (struct net_mgmt_event_callback *cb, uint64_t mgmt_event, struct net_if *iface) |
| static void | wifi_event_handler (struct net_mgmt_event_callback *cb, uint64_t mgmt_event, struct net_if *iface) |
Protected Attributes | |
| struct in_addr | _ip = {} |
| struct net_mgmt_event_callback | _ip_cb |
| volatile bool | _is_open = false |
| enum wifi_ps | _power_save = WIFI_PS_DISABLED |
| struct net_mgmt_event_callback | _wifi_cb |
Static Protected Attributes | |
| static WiFiZephyr * | _instance = nullptr |
Login to WiFi using Zephyr's wifi_mgmt / net_mgmt API. Access via the global object ZEPHYR_WIFI.
|
inline |
Returns the assigned IPv4 address (valid after isConnected() == true).
|
inlinestaticprotected |
Handles NET_EVENT_IPV4_ADDR_ADD (equivalent to IP_EVENT_STA_GOT_IP).
|
inline |
Power-save mode — maps to Zephyr's WIFI_PS_* values: WIFI_PS_DISABLED (= WIFI_PS_NONE equivalent) WIFI_PS_ENABLED
|
inline |
|
inlinestaticprotected |
Handles WIFI_CONNECT_RESULT and WIFI_DISCONNECT_RESULT.
|
inlinestaticprotected |
|
protected |
|
protected |
|
protected |