ESP32 with CP2102N Help. - Page 1
Forum section: electronics / general

author: Marine_Assistant
author_rank: Newbie
timestamp: May 01, 2025, 11:07:31 am
content: Hi everyone,I'm working on a custom PCB design using the ESP32 and the CP2102N USB-to-UART bridge. This is my first time integrating both on a board, and I’d really appreciate it if anyone could take a look at my schematic and let me know if there are any issues or things I should change.I've attached the schematic to this post (see below), and here are the datasheets I'm referencing:ESP32 Datasheet (Wroom)https://www.snapeda.com/parts/ESP32-WROOM-32/Espressif%20Systems/datasheet/CP2102N Datasheet (Silicon Labs)https://www.pololu.com/file/0J1761/cp2102n-datasheet.pdfSome specific things I’d love feedback on:- USB D+/D− routing and termination- Power supply filtering and decoupling for both chips- Reset/EN and BOOT circuitry for the ESP32- General lookovver the schematic, Anything ive done wrong?Let me know if you spot anything questionable or if you've done a similar setup before and have tips!Attached is a .PDF of the Schematic ive madeThanks in advance!

author: Psi
author_rank: Super Contributor
timestamp: May 01, 2025, 12:22:54 pm
content: You have R6 shorted, so something is wrong there.You also have TX on the USB chip connected to TX of the ESP32.(Output to Output instead of Output to Input or vice versa)Everyone has done that at least once on a PCB by mistake, but its pretty annoying, so better fix that tooDid you intend to have that LED on when the USB is in suspend state.Usually people connect them up to flash with data RX or TX.Is D3 supposed to be reverse polarity protection? because it gets bypassed by VDD going to the USB chip.So isn't really doing reverse polarity protection because if reverse voltage gets onto the USB chip it's going to backfeed into the ESP32 on TX/RX

author: fchk
author_rank: Frequent Contributor
timestamp: May 01, 2025, 04:23:11 pm
content: Quote from: Marine_Assistant on May 01, 2025, 11:07:31 amWhy do you use the first generation of ESP32? There is ESP32S3, and it has USB already built-in on GPIO19/20. And the price difference is not that much.The ONLY reason for still using ESP32 first gen ist Ethernet RMII for wired Ethernet. ESP32S2 and ESP32S3 don't have this.

author: Marine_Assistant
author_rank: Newbie
timestamp: May 01, 2025, 08:52:00 pm
content: Thanks guys for your feedback and finding the mistakes i made!Thinking about it I will probably move over to the S3, Ive not used one yet but it seems much easier and I could get rid of the whole USB stuff. I will however add ESD Protection, Ill update my schematic and repost here, If you could have a look that would be great.

author: tooki
author_rank: Super Contributor
timestamp: May 01, 2025, 09:02:47 pm
content: Quote from: Marine_Assistant on May 01, 2025, 11:07:31 amFirst of all, don’t add a size tag to your text. Let the reader have control over the text size, not you.Anyway, your schematic won’t work for automatic upload. That requires a specific circuit using some transistors.Look at the schematic for the ESP32 DEVKIT-C board. That, with a slightly larger capacitor to the EN pin, will give you reliable auto-upload. I’ve successfully designed a custom ESP32 board using the CP2102N, based on that schematic.With that said, I’d follow fchk’s advice to use a newer ESP32 chip. There’s a DEVKIT-C board for it, too. Always a good starting point.Quote from: Marine_Assistant on May 01, 2025, 11:07:31 amWe can’t comment on that until you make a layout.But you’ll want to use your layout program’s coplanar waveguide calculator, and your selected PCB house’s actual PCB layer stackup, to create a proper 90 ohm controlled-impedance differential pair. Solid grounding is crucial. I have seen a CP2102N layout fail because of poor layout.

author: linux-works
author_rank: Super Contributor
timestamp: May 02, 2025, 03:18:28 pm
content: I'm one of those that like the external uart instead of the built-in usb 'native' pair of wires, for serial debug and flashing use.the fact that you have to do a mode switch and re-enumerate usb (/dev/ttyACM1 then ACM2 then back to ACM0) is a huge PITA. you also lose the first few seconds of serial i/o time unless you work around it. that mode switch often causes your serial terminal to drop and you have to reconnect. just an unnecessary hassle! really not needed.plus, when using a proper uart chip, you can do the 2 transistor dance to do the reset (EN) and load/run wire so that you dont have to press buttons, ever, to flash. that's a big win, too.on my current set of projects, they will use the c3 or c6 chip (probably c3). it has native usb but I'm mostly ignoring it for all those reasons.