fix(esp_wifi): Remove deprecated arguments from some APIs

This commit is contained in:
Kapil Gupta
2025-07-14 18:09:20 +05:30
parent f2cd005473
commit 35f8d9d42c
8 changed files with 9 additions and 16 deletions

View File

@@ -37,13 +37,11 @@ typedef enum dpp_bootstrap_type {
* *
* Starts DPP Supplicant and initializes related Data Structures. * Starts DPP Supplicant and initializes related Data Structures.
* *
* @param evt_cb (Deprecated) Callback function to receive DPP related events
*
* return * return
* - ESP_OK: Success * - ESP_OK: Success
* - ESP_FAIL: Failure * - ESP_FAIL: Failure
*/ */
esp_err_t esp_supp_dpp_init(void *ctx); esp_err_t esp_supp_dpp_init(void);
/** /**
* @brief De-initialize DPP Supplicant * @brief De-initialize DPP Supplicant

View File

@@ -125,11 +125,6 @@ esp_err_t esp_wifi_wps_disable(void);
* *
* @attention WPS can only be used when station is enabled. WPS needs to be enabled first for using this API. * @attention WPS can only be used when station is enabled. WPS needs to be enabled first for using this API.
* *
* @param timeout_ms : deprecated: This argument's value will have not effect in functionality of API.
* The argument will be removed in future.
* The app should start WPS and register for WIFI events to get the status.
* WPS status is updated through WPS events. See wifi_event_t enum for more info.
*
* @return * @return
* - ESP_OK : succeed * - ESP_OK : succeed
* - ESP_ERR_WIFI_WPS_TYPE : wps type is invalid * - ESP_ERR_WIFI_WPS_TYPE : wps type is invalid
@@ -137,7 +132,7 @@ esp_err_t esp_wifi_wps_disable(void);
* - ESP_ERR_WIFI_WPS_SM : wps state machine is not initialized * - ESP_ERR_WIFI_WPS_SM : wps state machine is not initialized
* - ESP_FAIL : wps initialization fails * - ESP_FAIL : wps initialization fails
*/ */
esp_err_t esp_wifi_wps_start(int timeout_ms); esp_err_t esp_wifi_wps_start(void);
/** /**
* @brief Enable Wi-Fi AP WPS function. * @brief Enable Wi-Fi AP WPS function.

View File

@@ -1060,7 +1060,7 @@ init_fail:
} }
esp_err_t esp_supp_dpp_init(esp_supp_dpp_event_cb_t cb) esp_err_t esp_supp_dpp_init(void)
{ {
esp_err_t ret = ESP_OK; esp_err_t ret = ESP_OK;

View File

@@ -1656,7 +1656,7 @@ int esp_wifi_wps_disable(void)
return ESP_OK; return ESP_OK;
} }
int esp_wifi_wps_start(int timeout_ms) int esp_wifi_wps_start(void)
{ {
int ret; int ret;

View File

@@ -161,7 +161,7 @@ void dpp_enrollee_init(void)
ESP_ERROR_CHECK(esp_wifi_init(&cfg)); ESP_ERROR_CHECK(esp_wifi_init(&cfg));
ESP_ERROR_CHECK(esp_wifi_set_mode(WIFI_MODE_STA)); ESP_ERROR_CHECK(esp_wifi_set_mode(WIFI_MODE_STA));
ESP_ERROR_CHECK(esp_supp_dpp_init(NULL)); ESP_ERROR_CHECK(esp_supp_dpp_init());
ESP_ERROR_CHECK(dpp_enrollee_bootstrap()); ESP_ERROR_CHECK(dpp_enrollee_bootstrap());
ESP_ERROR_CHECK(esp_wifi_start()); ESP_ERROR_CHECK(esp_wifi_start());

View File

@@ -58,7 +58,7 @@ static void wps_restart(void)
{ {
ESP_ERROR_CHECK(esp_wifi_wps_disable()); ESP_ERROR_CHECK(esp_wifi_wps_disable());
ESP_ERROR_CHECK(esp_wifi_wps_enable(&config)); ESP_ERROR_CHECK(esp_wifi_wps_enable(&config));
ESP_ERROR_CHECK(esp_wifi_wps_start(0)); ESP_ERROR_CHECK(esp_wifi_wps_start());
} }
static void handle_wps_success(void *event_data) static void handle_wps_success(void *event_data)
@@ -172,7 +172,7 @@ static void start_wps(void)
ESP_LOGI(TAG, "start wps..."); ESP_LOGI(TAG, "start wps...");
ESP_ERROR_CHECK(esp_wifi_wps_enable(&config)); ESP_ERROR_CHECK(esp_wifi_wps_enable(&config));
ESP_ERROR_CHECK(esp_wifi_wps_start(0)); ESP_ERROR_CHECK(esp_wifi_wps_start());
} }
void app_main(void) void app_main(void)

View File

@@ -70,7 +70,7 @@ static void test_wps_init(void)
{ {
esp_wps_config_t config = WPS_CONFIG_INIT_DEFAULT(WPS_TYPE_DISABLE); esp_wps_config_t config = WPS_CONFIG_INIT_DEFAULT(WPS_TYPE_DISABLE);
ESP_ERROR_CHECK(esp_wifi_wps_enable(&config)); ESP_ERROR_CHECK(esp_wifi_wps_enable(&config));
ESP_ERROR_CHECK(esp_wifi_wps_start(0)); ESP_ERROR_CHECK(esp_wifi_wps_start());
} }

View File

@@ -65,7 +65,7 @@ static void test_wps_init(void)
{ {
esp_wps_config_t config = WPS_CONFIG_INIT_DEFAULT(WPS_TYPE_DISABLE); esp_wps_config_t config = WPS_CONFIG_INIT_DEFAULT(WPS_TYPE_DISABLE);
ESP_ERROR_CHECK(esp_wifi_wps_enable(&config)); ESP_ERROR_CHECK(esp_wifi_wps_enable(&config));
ESP_ERROR_CHECK(esp_wifi_wps_start(0)); ESP_ERROR_CHECK(esp_wifi_wps_start());
} }