Updated: October 28, 2024 |
Disconnect the current Wi-Fi network connection
#include <qwf/qwf_wifi.h>
qwf_wifi_Results_e qwf_wifi_Disconnect(qwf_Context_t *pCtx)
This function requests the Wi-Fi Manager service to disconnect the current network connection. The service does this by disabling the active Saved Network profile.
If other network profiles are enabled, meaning their auto-connect settings are enabled, and available, meaning they were found in the latest scan, the Wi-Fi supplicant service selects one of them and tries connecting to its access point. The selection is based on which network was last connected and the current signal strengths.
WIFI_OK Successful result
WIFI_ERR_INACTIVE The QWF Wi-Fi Manager service is inactive or not ready
WIFI_ERR_INT The QWF Wi-Fi Manager service couldn't issue the request or read the response
WIFI_ERR_PARAM pCtx is NULL, or the QWF Wi-Fi Manager conext can't be retrieved