6#include "wifi_client.hpp"
27 static void EventHandler(
void* arg, esp_event_base_t event_base, int32_t event_id,
30 static inline bool is_initialized_ =
false;
31 static inline esp_netif_t* netif_ =
nullptr;
33 bool enabled_ =
false;
34 bool connected_ =
false;
36 char ip_str_[IP4ADDR_STRLEN_MAX] = {};
WifiError Connect(const Config &config) override
连接到 WiFi 网络 / Connect to a WiFi network
WifiError Disable() override
禁用 WiFi 模块 / Disable the WiFi module
int GetRSSI() const override
获取当前 WiFi 信号强度 / Get the current WiFi signal strength
WifiError Disconnect() override
断开当前 WiFi 连接 / Disconnect from the current WiFi connection
bool IsConnected() const override
检查是否已连接 / Check if currently connected
WifiError Scan(std::vector< ScanResult > &results) override
扫描可用 WiFi 网络 / Scan for available WiFi networks
const char * GetIPAddress() const override
获取当前 IP 地址 / Get the current IP address
WifiError Enable() override
启用 WiFi 模块 / Enable the WiFi module
信号量类,实现线程同步机制 Semaphore class implementing thread synchronization
Wifi 客户端接口类 / Interface class for WiFi client management.
WifiError
WiFi 错误码枚举 / Enumeration of WiFi error codes.
LibXR Color Control Library / LibXR终端颜色控制库
WiFi 连接配置 / WiFi connection configuration.