Cant connect Wi-Fi Esp32

Hello.
I’m using some Esp32 Devkit V1 that I bought recently and Arduino IDE. Trying to deploy the project but devices can’t connect to Wi-Fi.
In serial monitor shows “secure connection failed”.
Testing with old devices Esp32 Devkit V1 with same template and code all works fine. I have lots of devices running with no problem.
I have no idea what is going on.
Can anyone help?

Hello,

Did you choose Esp32 Devkit V1 in Boards?

Yes.
In older boards same code is working fine.
Very strange.

Select ESP32 DEV MODULE from the list under boards. This should solve the issue.

Did not worked, @Madhukesh.
Same response when I try to connect to internet using a domestic router: “secure connection failed”.
When I try to connect to my phone as router using same ssid it works.

@PeteKnight
@vshymanskyy
Any clue?

What ESP332 core version are you using?

Pete.

Hello, Pete.
Thanks for reply.
I´m using arduino ide with esp32 2.0.6 version.

What happens if you try to downgrade to 2.0.5 ?

Pete.

Hi, Pete.
I tried with all versions above 2.0.0 and nothing.
Same behavior. When connects, the connection keep crashing.
Evaluating the board, I can only identify a minimal difference between this one and others I have that runs ok: a small “k” marked on the chip’s antenna.
The esp32 board with abnormal bahavior does not have the k marked on the antenna.

Have you tried playing with other wifi sketch other than Blynk? Will the board still crash?

Hi, @Madhukesh .
I will try.

@vshymanskyy @Dmitriy
What kind of error generates the message “secure connection failed”?
Device can connect to WiFi network but when tries to connect to Blynk return this message.

[231] --------------------------
[231] Product: BuildPay Laundromat
[241] Firmware: 1.0.0 (build Dec 16 2022 20:27:47)
[241] Token: …qZP2
[242] Device: ESP32 @ 240MHz
[242] MAC: 94:E6:86:3C:7C:4C
[252] Flash: 4096K
[252] ESP sdk: v4.4.1-472-gc9140caf8c
[253] Chip rev: 3
[253] Free mem: 248548
[263] --------------------------
[263] INIT => CONNECTING_NET
[264] Connecting to WiFi: BPay_01
[990] Using Dynamic IP: 192.168.8.177
[990] CONNECTING_NET => CONNECTING_CLOUD
[1001] Connecting to blynk.cloud:443
[7118] Secure connection failed
[7128] Connecting to blynk.cloud:443
[14118] Secure connection failed

Do you use WiFiClientSecure or WiFiClient ?

I´m using Edgent_ESP32 example from blynk library.
It uses WiFiClient .

This is a local server ?

No.
blynk.cloud.

2.0.6 should work.
Edgent in ESP32 uses a secure client and it tries to connect to port 443, which is correct.
Secure connection failed roughly means the same as Connection failed, but also indicates that there may be a problem with the certificate validation.
To understand what’s going on, set ESP32 core debug level do debug or verbose.

3 Likes

Many thanks, @vshymanskyy .
I will run more tests here.