Skip to content

Commit

Permalink
Merge branch 'bugfix/add_clear_ap_list_interface' into 'master'
Browse files Browse the repository at this point in the history
esp_wifi:add clear ap list interface

See merge request espressif/esp-idf!19441
  • Loading branch information
jack0c committed Aug 18, 2022
2 parents 2310736 + b9a0a3d commit b738321
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
15 changes: 15 additions & 0 deletions components/esp_wifi/include/esp_wifi.h
Original file line number Diff line number Diff line change
Expand Up @@ -453,6 +453,21 @@ esp_err_t esp_wifi_scan_get_ap_num(uint16_t *number);
esp_err_t esp_wifi_scan_get_ap_records(uint16_t *number, wifi_ap_record_t *ap_records);


/**
* @brief Clear AP list found in last scan
*
* @attention When the obtained ap list fails,bss info must be cleared,otherwise it may cause memory leakage.
*
* @return
* - ESP_OK: succeed
* - ESP_ERR_WIFI_NOT_INIT: WiFi is not initialized by esp_wifi_init
* - ESP_ERR_WIFI_NOT_STARTED: WiFi is not started by esp_wifi_start
* - ESP_ERR_WIFI_MODE: WiFi mode is wrong
* - ESP_ERR_INVALID_ARG: invalid argument
*/
esp_err_t esp_wifi_clear_ap_list(void);


/**
* @brief Get information of AP which the ESP32 station is associated with
*
Expand Down

0 comments on commit b738321

Please sign in to comment.