esp_wifi_start_scan() 使用条件

flyfly20000
Posts: 12
Joined: Mon Aug 26, 2019 8:54 am

esp_wifi_start_scan() 使用条件

Postby flyfly20000 » Sat Sep 07, 2019 10:58 am

专家:
3. The scanning triggered by esp_wifi_start_scan() will not be effective until connection between ESP32 and the AP is established. If ESP32 is scanning and connecting at the same time, ESP32 will abort scanning and return a warning message and error number ESP_ERR_WIFI_STATE. If you want to do reconnection after ESP32 received disconnect event, remember to add the maximum retry time, otherwise the called scan will not work. This is especially true when the AP doesn’t exist, and you still try reconnection after ESP32 received disconnect event with the reason code WIFI_REASON_NO_AP_FOUND.-----这句话里 remember to add the maximum retry time 这个指的具体处理过程是? 调用那个函数?才能继续使用esp_wifi_start_scan()

it_zzc
Posts: 46
Joined: Mon Apr 15, 2019 1:37 pm

Re: esp_wifi_start_scan() 使用条件

Postby it_zzc » Tue Sep 10, 2019 3:44 am

请参考: https://gitlab.espressif.cn:6688/applic ... est.c#L278

1. 首先你需要停止 ESP-MESH 自组网的功能和停止上一次 wifi_scan
2. 当扫描不到数据时,需要重试

Who is online

Users browsing this forum: No registered users and 3 guests