Can't connect to custom ESP32-S2 board

backwardsj
Posts: 3
Joined: Mon Aug 12, 2024 12:10 pm

Can't connect to custom ESP32-S2 board

Postby backwardsj » Fri Jul 25, 2025 4:12 pm

I am trying to get a very basic custom pcb using an esp32-s2fh2 chip working, schematic attached. I am holding the switch down to bring strapping pin GPI0 to ground during power up to select the boot mode. After initial attempts to communicate with the chip failed, I verified the oscillator was at 40MHz (800mV peak to peak), the chip is drawing power (10mA), that the switch if effective, that the RX onto the board is as expected and the TX on the board is quiet.

Then I read some posts here and decided to solder an additional 100uF electrolytic capacitor onto the enable RC network to alleviate any problems from slowly settling power supplies during testing. After this I got this response from the chip ID esptool command:
esptool v5.0.1
Connected to ESP32-S2 on /dev/cu.usbmodem14303:
Chip type: ESP32-S2FH2 (revision v1.0)
Features: Wi-Fi, Single Core, 240MHz, Embedded Flash 2MB, No Embedded PSRAM, ADC and temperature sensor calibration in BLK2 of eFuse V2
Crystal frequency: 40MHz
MAC: 74:4d:bd:00:8f:6c
Uploading stub flasher...
A serial exception error occurred: Write timeout
My USB to UART translation was through an on-board STlink. I have not had this response since. If I boot it in download mode over UART now, I can see:
Build:Oct 25 2019
rst:0x1 (POWERON),boot:0x0 (DOWNLOAD(USB/UART0/1/SPI))
waiting for download
Which looks good, but then I get :
esptool v5.0.1
Serial port /dev/cu.usbmodem14303:
Connecting......................................
A fatal error occurred: Failed to connect to Espressif device: No serial data received.
Is it possible that an unsuccessful attempt to upload the stub flasher has created problems? Is there anything I can do to get a working system?

Thanks!
basic_white.pdf
(168.44 KiB) Downloaded 35 times

Sprite
Espressif staff
Espressif staff
Posts: 10617
Joined: Thu Nov 26, 2015 4:08 am

Re: Can't connect to custom ESP32-S2 board

Postby Sprite » Sat Jul 26, 2025 3:03 am

What's generating your 3V3?

backwardsj
Posts: 3
Joined: Mon Aug 12, 2024 12:10 pm

Re: Can't connect to custom ESP32-S2 board

Postby backwardsj » Sat Jul 26, 2025 9:15 am

I have a cheap programmable power supply generating the 3V3.

Sprite
Espressif staff
Espressif staff
Posts: 10617
Joined: Thu Nov 26, 2015 4:08 am

Re: Can't connect to custom ESP32-S2 board

Postby Sprite » Sun Jul 27, 2025 12:48 am

Oooh, and you have very little local decoupling as well... that's likely your issue: long wires to the power supply have a non-negligable induction/resistance and you have nothing to compensate for that. Try to add some capacitance to your 3.3V line, preferably close to the ESP32. In the future, it's probably better to have a 3.3V LDO or buck converter on your board and feed the PCB with a higher voltage.

backwardsj
Posts: 3
Joined: Mon Aug 12, 2024 12:10 pm

Re: Can't connect to custom ESP32-S2 board

Postby backwardsj » Sun Jul 27, 2025 10:18 pm

Thanks for the suggestion and general advice. I added 100uF and 1000uF electrolytic capacitors to the board where the 3V3 comes in which is about 1cm from the esp32 and the bulk SMD ceramic decoupling capacitors, 10uF, 1uF and 0.1uF. The pins also have closer 0.1uF decoupling capacitors. Unfortunately the behaviour is as before. I should be able to scope the power and UART lines soon but for now I cannot.

How confident are you in the power supply being the issue? Is a power issue consistent with the chip entering download mode and sending the UART message but not functioning after that? Does the other functionality have stricter power requirements?

Thanks for your help!

Sprite
Espressif staff
Espressif staff
Posts: 10617
Joined: Thu Nov 26, 2015 4:08 am

Re: Can't connect to custom ESP32-S2 board

Postby Sprite » Mon Jul 28, 2025 2:27 am

I am not, but it seems like an obvious thing that, even if it does not lead to issues now, will certainly lead to issues later. Most commonly you'll get brownouts when initializing or using WiFi, as the radio has a very spiky usage pattern.

In general, the ESP32 has a pretty robust bootloader in ROM. It is technically possible to make that inaccessible, but you'd really have to try, I've never seen it happen in the field by accident, so I'm pretty confident your ESP32 itself still works.

Who is online

Users browsing this forum: ChatGPT-User, PetalBot, Qwantbot and 5 guests