I'm getting "A fatal error occurred: Failed to connect to ESP32: Timed out waiting for packet header" when I'm flashing the PCB.
From breadboard to PCB, I added a ch340 serial chip (which seems to work, but I'm using FT232 with breadboard), a RT9013 (in theory it should capable for 500mA current) for 3.3v (instead of AMS1117-3.3 which is used by breadboard), bypass caps (1.0uF for both RT9013 VIN, ESP32 VIN and ch340 VIN).
Beside, I added a Li-on manage chip (which can delivery enough energy I guess, but I don't have a oscilloscope so I cannot verify it) but I've not add Li-on battery yet so I should just connect VUSB & SYS. And I added a opamp... Both them work well when standalone.
And I added some trans & mosfet which I connect manually when I'm using breadboard and I think have nothing to do with this.
I'm assuming if these is some problem with USB Power Delivery so I changed to a 20AWG Usb charging cable but it still not working.
And after few tries, it burned by RT9013 so I think it must have something to do with my power supply. But at this stage I temporarily have nothing can do...
I'm wondering if there is any problem with my PCB design or connection since I'm newbie on PCB...
And, most components on the board are soldered by SMT process, I just soldered usb connector, ESP32 module and inductor.
I've attached sch & pcb layout. I cannot upgrade eagle project directly because it contains some privacy info but the images should show everything that required...
What's wrong when I move from breadboard to PCB?
Re: What's wrong when I move from breadboard to PCB?
There are so many ESP32 boards schematics, haven't you noticed the reset circuit needed to put ESP32 into bootloader mode, it looks like you are missing one...
Re: What's wrong when I move from breadboard to PCB?
Thanks a lot. I didn't notice this...
I've seen this schematic for ESP8266 in some boards, and when I was drawing them, I read https://github.com/espressif/esptool/wi ... bootloader and it says
I use miniterm --rts 1 --dtr 1 COM4 115200 and I was not able to get boot log (according to the doc). (I thought it should reset ESP32 or I'm wrong...)
I'm a little confusing now..
I'll try to trigger reset and boot mode manually to see if this matter, after I replaced the broken LDO....
I've seen this schematic for ESP8266 in some boards, and when I was drawing them, I read https://github.com/espressif/esptool/wi ... bootloader and it says
Make the following connections for esptool.py to automatically enter the bootloader
ESP32 Pin Serial Pin
EN RTS
GPIO0 DTR
So I think I only need to connect EN to RTS and GPIO0 to DTR and ignored them ...Note that some serial terminal programs (not esptool.py) will assert both RTS and DTR when opening the serial port, pulling them low together and holding the ESP32 in reset. If you've wired RTS to the ESP32 then you should disable RTS/CTS "hardware flow control" in the program. Development boards like NodeMCU use additional circuitry to avoid this problem - if both RTS and DTR are asserted together, this doesn't reset the chip.
I use miniterm --rts 1 --dtr 1 COM4 115200 and I was not able to get boot log (according to the doc). (I thought it should reset ESP32 or I'm wrong...)
I'm a little confusing now..
I'll try to trigger reset and boot mode manually to see if this matter, after I replaced the broken LDO....
Re: What's wrong when I move from breadboard to PCB?
This is correct. With this config normal serial programs won't work without some tweaking for RTS/DTR, but esptool.py, "make monitor" in IDF, miniterm (with correct args) and some other tools will work fine.yangff wrote: So I think I only need to connect EN to RTS and GPIO0 to DTR and ignored them ...
Both RTS/DTR are active low, so to keep them high (ie EN pin high, ESP32 enabled) you will need "miniterm.py --dtr 0 --rts 0 /dev/ttyUSB0 115200"yangff wrote: I use miniterm --rts 1 --dtr 1 COM4 115200 and I was not able to get boot log (according to the doc). (I thought it should reset ESP32 or I'm wrong...)
(If you saw the --rts 1 --drt 1 in our docs somewhere, can you please tell me where? Will fix.)
That will hopefully get you some serial output. (You may want to try toggling RTS if you can. You can do this via miniterm as well.)
Other than that, I'd suggest checking with a multimeter that the VCC and ENs pin both have correct voltages. And check for bad soldering, etc.
Re: What's wrong when I move from breadboard to PCB?
I will try this argument after I get my new LDO.Both RTS/DTR are active low, so to keep them high (ie EN pin high, ESP32 enabled) you will need "miniterm.py --dtr 0 --rts 0 /dev/ttyUSB0 115200"
It's not in the document. I use "--dtr 1 --rts 1" because I read "GPIO0" should be high to for ESP32 to running its program(If you saw the --rts 1 --drt 1 in our docs somewhere, can you please tell me where? Will fix.)
and I've no idea whether it's 1 or 0 for "miniterm" ...The ESP32 will enter the serial bootloader when GPIO0 is held low on reset. Otherwise it will run the program in flash.
Re: What's wrong when I move from breadboard to PCB?
I removed the Li-on chip, shorted USB-VCC to LDO and I can feed ESP-32 is a lot more hot(40°C at least I feel). But still having no output in the terminal...
If it's the problem of power supply, how much current should I feed to the module. Or do I need a larger cap?
Code: Select all
Administrator@WIN-F5GR238P6RA MINGW32 ~
$ python -m serial.tools.miniterm --dtr 0 --rts 0 COM4 115200
--- Miniterm on COM4 115200,8,N,1 ---
--- Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H ---
Re: What's wrong when I move from breadboard to PCB?
OK... After carefully inspected my breadboard, I found the problem...
First, I replaced the LDO to AMS1117-3.3 by some ugly wire...
Second, I miss connected RX to RX and TX to TX in the pcb.. after some dirty cut and reconnect it finally works... I'm wondering what I'm thinking at that time... maybe they have the same name so I didn't manually wire them..
Thank you.
First, I replaced the LDO to AMS1117-3.3 by some ugly wire...
Second, I miss connected RX to RX and TX to TX in the pcb.. after some dirty cut and reconnect it finally works... I'm wondering what I'm thinking at that time... maybe they have the same name so I didn't manually wire them..
Thank you.
Re: What's wrong when I move from breadboard to PCB?
Glad you got it sorted out.yangff wrote:after some dirty cut and reconnect it finally works...
Who is online
Users browsing this forum: No registered users and 140 guests