Merge branch 'bugfix/fix_writing_errors_v3.3' into 'release/v3.3'

fix(wifi): fix writing errors(backport v3.3)

See merge request sdk/ESP8266_RTOS_SDK!1409
This commit is contained in:
Dong Heng
2020-05-27 09:56:28 +08:00
44 changed files with 43 additions and 46 deletions

View File

@@ -90,9 +90,6 @@ extern "C" {
#define ESP_WIFI_PARAM_USE_NVS 0
#define WIFI_PROTOCAL_11B 1
#define WIFI_PROTOCAL_11G 2
#define WIFI_PROTOCAL_11N 4
/**
* @brief WiFi stack configuration parameters passed to esp_wifi_init call.
*/

View File

@@ -44,7 +44,7 @@ static esp_err_t wifi_event_handler(void *ctx, system_event_t *event)
ESP_LOGE(TAG, "Disconnect reason : %d", info->disconnected.reason);
if (info->disconnected.reason == WIFI_REASON_BASIC_RATE_NOT_SUPPORT) {
/*Switch to 802.11 bgn mode */
esp_wifi_set_protocol(ESP_IF_WIFI_STA, WIFI_PROTOCAL_11B | WIFI_PROTOCAL_11G | WIFI_PROTOCAL_11N);
esp_wifi_set_protocol(ESP_IF_WIFI_STA, WIFI_PROTOCOL_11B | WIFI_PROTOCOL_11G | WIFI_PROTOCOL_11N);
}
esp_wifi_connect();
xEventGroupClearBits(wifi_event_group, CONNECTED_BIT);