mirror of
https://github.com/esphome/esphome.git
synced 2025-11-19 16:25:50 +00:00
fixes
This commit is contained in:
@@ -1127,14 +1127,13 @@ void WiFiComponent::retry_connect() {
|
|||||||
#ifdef USE_WIFI_FAST_CONNECT
|
#ifdef USE_WIFI_FAST_CONNECT
|
||||||
if (current_phase == WiFiRetryPhase::FAST_CONNECT_CYCLING_APS) {
|
if (current_phase == WiFiRetryPhase::FAST_CONNECT_CYCLING_APS) {
|
||||||
// Fast connect: always advance to next AP (no retries per AP)
|
// Fast connect: always advance to next AP (no retries per AP)
|
||||||
// Clear old scan data so new AP is tried with config only
|
|
||||||
this->selected_sta_index_++;
|
this->selected_sta_index_++;
|
||||||
this->num_retried_ = 0;
|
this->num_retried_ = 0;
|
||||||
this->scan_result_.clear();
|
|
||||||
advanced_to_next_target = true;
|
advanced_to_next_target = true;
|
||||||
ESP_LOGD(TAG, "Advanced to next AP in phase %s", LOG_STR_ARG(retry_phase_to_log_string(this->retry_phase_)));
|
ESP_LOGD(TAG, "Advanced to next AP in phase %s", LOG_STR_ARG(retry_phase_to_log_string(this->retry_phase_)));
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (current_phase == WiFiRetryPhase::SCAN_WITH_HIDDEN && this->num_retried_ + 1 >= WIFI_RETRY_COUNT_PER_SSID &&
|
if (current_phase == WiFiRetryPhase::SCAN_WITH_HIDDEN && this->num_retried_ + 1 >= WIFI_RETRY_COUNT_PER_SSID &&
|
||||||
this->selected_sta_index_ < static_cast<int8_t>(this->sta_.size()) - 1) {
|
this->selected_sta_index_ < static_cast<int8_t>(this->sta_.size()) - 1) {
|
||||||
// Hidden mode: exhausted retries on current SSID, advance to next
|
// Hidden mode: exhausted retries on current SSID, advance to next
|
||||||
|
|||||||
Reference in New Issue
Block a user