ESP32 WiFi - Suddenly doesn't connect over WiFi anymore

This is really weird:

Yesterday My ESP32 was running just fine the whole Day over WiFi. Unplugged Power in the Evening.
Today in the Morning plugged it back in - No Connection. By the Status LED i can see it is working.

I can connect to it via USB/ESP Home Dashboard, though. And then (after an “Authentification failed”) it even accepts to connect to the Router, and is shown there as Device.
I swear, i didn’t change anything Network-Related i can think of :smiley:

Leaving...
Hard resetting via RTS pin...
INFO Successfully uploaded program.
INFO Starting log output from /dev/ttyUSB0 with baud rate 115200
[12:10:21][I][logger:258]: Log initialized
[12:10:21][C][ota:469]: There have been 1 suspected unsuccessful boot attempts.
[12:10:21][D][esp32.preferences:113]: Saving 1 preferences to flash...
[12:10:21][D][esp32.preferences:142]: Saving 1 preferences to flash: 0 cached, 1 written, 0 failed
[12:10:21][I][app:029]: Running through setup()...
[12:10:21][C][uart.arduino_esp32:077]: Setting up UART...
[12:10:21][    54][E][HardwareSerial.cpp:525] setRxBufferSize(): RX Buffer can't be resized when Serial is already running.
[12:10:21]
[12:10:21][C][switch.gpio:011]: Setting up GPIO Switch 'LD2410 OnOff'...
[12:10:21][D][switch:017]: 'LD2410 OnOff' Turning OFF.
[12:10:21][D][switch:056]: 'LD2410 OnOff': Sending state OFF
[12:10:21][D][switch:017]: 'LD2410 OnOff' Turning OFF.
[12:10:21][C][ld2410:033]: Setting up LD2410...
[12:10:22][C][ld2410:049]: Firmware Version : 0.0.0000
[12:10:22][C][ld2410:050]: LD2410 setup complete.
[12:10:22][C][dht:011]: Setting up DHT...
[12:10:22][C][wifi:037]: Setting up WiFi...
[12:10:22][C][wifi:038]:   Local MAC: C8:F0:9E:50:55:F8
[12:10:22][D][wifi:386]: Starting scan...
[12:10:22][D][esp32.preferences:113]: Saving 1 preferences to flash...
[12:10:22][D][esp32.preferences:142]: Saving 1 preferences to flash: 1 cached, 0 written, 0 failed
[12:10:28][D][wifi:401]: Found networks:
[12:10:28][I][wifi:445]: - '..' (E0:28:6D:70:32:A5) [redacted]▂▄▆█
[12:10:28][D][wifi:446]:     Channel: 1
[12:10:28][D][wifi:447]:     RSSI: -75 dB
[12:10:28][I][wifi:445]: - '..' (1C:ED:6F:67:FC:6B) [redacted]▂▄▆█
[12:10:28][D][wifi:446]:     Channel: 1
[12:10:28][D][wifi:447]:     RSSI: -84 dB
[12:10:28][D][wifi:450]: - 'IchKannEuchBeimSexHoeren'[redacted] (E2:28:6D:70:32:A5) [redacted]▂▄▆█
[12:10:28][I][wifi:257]: WiFi Connecting to '..'...
[12:10:29][W][wifi_esp32:494]: Event: Disconnected ssid='..' bssid=E0:28:6D:70:32:A5[redacted] reason='Authentication Failed'
[12:10:29][W][wifi:570]: WiFi Unknown connection status 0
[12:10:29][I][wifi:257]: WiFi Connecting to '..'...
[12:10:29][I][wifi:518]: WiFi Connected!
[12:10:29][C][wifi:362]:   Local MAC: C8:F0:9E:50:55:F8
[12:10:29][C][wifi:363]:   SSID: '..'[redacted]
[12:10:29][C][wifi:364]:   IP Address: 192.168.128.80
[12:10:29][C][wifi:366]:   BSSID: E0:28:6D:70:32:A5[redacted]
[12:10:29][C][wifi:367]:   Hostname: 'esp32-presence03'
[12:10:29][C][wifi:369]:   Signal strength: -78 dB ▂▄▆█
[12:10:29][C][wifi:373]:   Channel: 1
[12:10:29][C][wifi:374]:   Subnet: 255.255.255.0
[12:10:29][C][wifi:375]:   Gateway: 192.168.128.1
[12:10:29][C][wifi:376]:   DNS1: 192.168.128.1
[12:10:29][C][wifi:377]:   DNS2: 0.0.0.0
[12:10:29][D][wifi:527]: Disabling AP...
[12:10:29][C][ota:093]: Over-The-Air Updates:
[12:10:29][C][ota:094]:   Address: esp32-presence03.local:3232
[12:10:29][C][ota:097]:   Using Password.
[12:10:29][C][api:025]: Setting up Home Assistant API server...
[12:10:29][I][app:062]: setup() finished successfully!
[12:10:29][I][app:102]: ESPHome version 2023.3.2 compiled on Apr  1 2023, 12:09:26
[12:10:29][C][wifi:504]: WiFi:
[12:10:29][C][wifi:362]:   Local MAC: C8:F0:9E:50:55:F8
[12:10:29][C][wifi:363]:   SSID: '..'[redacted]
[12:10:29][C][wifi:364]:   IP Address: 192.168.128.80
[12:10:29][C][wifi:366]:   BSSID: E0:28:6D:70:32:A5[redacted]
[12:10:29][C][wifi:367]:   Hostname: 'esp32-presence03'
[12:10:29][C][wifi:369]:   Signal strength: -76 dB ▂▄▆█
[12:10:29][C][wifi:373]:   Channel: 1
[12:10:29][C][wifi:374]:   Subnet: 255.255.255.0
[12:10:29][C][wifi:375]:   Gateway: 192.168.128.1
[12:10:29][C][wifi:376]:   DNS1: 192.168.128.1
[12:10:29][C][wifi:377]:   DNS2: 0.0.0.0
(...)
[12:10:30][C][captive_portal:088]: Captive Portal:
[12:10:30][C][mdns:108]: mDNS:
[12:10:30][C][mdns:109]:   Hostname: esp32-presence03
[12:10:30][C][ota:093]: Over-The-Air Updates:
[12:10:30][C][ota:094]:   Address: esp32-presence03.local:3232
[12:10:30][C][ota:097]:   Using Password.
[12:10:30][C][api:138]: API Server:
[12:10:30][C][api:139]:   Address: esp32-presence03.local:6053
[12:10:30][C][api:141]:   Using noise encryption: YES
[12:10:31][D][api:102]: Accepted 192.168.128.81
[12:10:31][D][api.connection:920]: Home Assistant 2023.3.6 (192.168.128.81): Connected successfully

I think, the most interesting Parts are:

[12:10:21][C][ota:469]: There have been 1 suspected unsuccessful boot attempts.

[12:10:29][W][wifi_esp32:494]: Event: Disconnected ssid='..' bssid=E0:28:6D:70:32:A5[redacted] reason='Authentication Failed'
[12:10:29][W][wifi:570]: WiFi Unknown connection status 0
[12:10:29][I][wifi:257]: WiFi Connecting to '..'...
[12:10:29][I][wifi:518]: WiFi Connected!

I just don’t know where to start, as i didn’t change anything related (that i know).
How can i narrow down what the Problem is?

Edit: What i did so far:

  • Assign a static IP → Same behaviour. No Connection via WiFi, via USB same Log Output
  • Switch 2,4GhZ Channel to manually / 9
  • Make sure it is set to b/g/n
  • Checked Router (fritz.box), no failed Authentifications logged
  • Reflashed (Installed) Firmware

I know this is a little late, haha! but this worked for me when I had esp32 wifi issues.

wifi:

power_save_mode: none

seems the low power mode is flakey.

Scott

1 Like