LilyGo T5 4.7 how to force into download mode

I have accidentally flashed LilyGo T5 4.7 board with ESP32S3
Now it is in boot loop :

00:44:24.789 -> Starting...
00:44:24.789 -> Memory alloc failed!
00:44:24.789 -> Guru Meditation Error: Core  1 panic'ed (StoreProhibited). Exception was unhandled.
00:44:24.789 -> 
00:44:24.789 -> Core  1 register dump:
00:44:24.822 -> PC      : 0x4008bacc  PS      : 0x00060c30  A0      : 0x800d35b2  A1      : 0x3ffb21a0  
00:44:24.822 -> A2      : 0x00000000  A3      : 0xffffffff  A4      : 0x0003f480  A5      : 0x00000000  
00:44:24.822 -> A6      : 0x00000001  A7      : 0x00003f48  A8      : 0x800e7050  A9      : 0x3ffb2170  
00:44:24.822 -> A10     : 0x00000002  A11     : 0x3f4013d5  A12     : 0x00000040  A13     : 0x00000001  
00:44:24.822 -> A14     : 0x00000044  A15     : 0x3ffb8a68  SAR     : 0x00000015  EXCCAUSE: 0x0000001d  
00:44:24.864 -> EXCVADDR: 0x00000000  LBEG    : 0x4008bacc  LEND    : 0x4008bad7  LCOUNT  : 0x00003f47  
00:44:24.864 -> 
00:44:24.864 -> 
00:44:24.864 -> Backtrace: 0x4008bac9:0x3ffb21a0 0x400d35af:0x3ffb21b0 0x400dca01:0x3ffb2210 0x400e9ef6:0x3ffb2290
00:44:24.864 -> 
00:44:24.864 -> 
00:44:24.864 -> 
00:44:24.864 -> 
00:44:24.864 -> ELF file SHA256: 4eed671fe7535a55
00:44:24.864 -> 
00:44:25.034 -> Rebooting...
00:44:25.034 -> ets Jul 29 2019 12:21:46

Unfortunately I am not able to flash new sketch now.
I get:

A fatal error occurred: Failed to connect to ESP32: Invalid head of packet (0x30): Possible serial noise or corruption.
For troubleshooting steps visit: https://docs.espressif.com/projects/esptool/en/latest/troubleshooting.html
Failed uploading: uploading error: exit status 2

I think it must be forced to upload mode. But I can't find the correct reset & boot buttons. Which button combination does what I'm looking for ?

Push both rst and boot button. Then release first the rst button, then the boot button.
Then you need to select the changed USB port in the IDE.
Download should work thereafter.
After successful download and program start, the USB port will be different again.
Good Luck!

ok but which one is the reset and boot buttons on this device ?

The reset button is labeled REST, and the neighbor button labeled STR_IO0 most likely is the boot button, as boot mode is on GPIO0.

The weather in LUZERN was sunny on Fri, 23 Sep 2023.

1 Like

I don't see any REST or STR_IO0 labels on this card ?

Post a link to your display from the TTGO website. I have the 4.7" e-paper version.
Or take a look at the schematics they provide, most likely.

You have the older version. I have one of these too.
https://github.com/Xinyuan-LilyGO/LilyGo-EPD47/blob/master/schematic/T5-4.7.pdf

The two buttons next to the ESP32, s5 and s6.

The processor is an ESP32-WROVER-E.

There was light rain on Sat 24-Sep 2022 in Luzern.

1 Like

ok thanks. so in which order should I press s5 and s6 ?
btw how do you understand this schematic ?

S5 is reset, S6 is boot. Push and hold both, release S5 first. See schematics.

1 Like

thank you. I don't understand anything from those schematics. How do you even see the reset button there ?

Also, you wrote that the processor is an ESP32-WROVER-E twice.
Should I do something about it ? Any option to be selected ?

tried s5-s6 buttons now and it seems to go into download mode but sketch upload fails:

Serial monitor:

09:48:30.660 -> rst:0x1 (POWERON_RESET),boot:0x3 (DOWNLOAD_BOOT(UART0/UART1/SDIO_REI_REO_V2))

09:48:30.660 -> waiting for download

09:49:02.542 -> de:DIO, clock div:1

09:49:02.542 -> load:0x3fff0030,len:1344

09:49:02.542 -> load:0x40078000,len:13964

09:49:02.542 -> load:0x40080400,len:3600

09:49:02.542 -> entry 0x400805f0

09:49:02.914 -> C:\Users\ilker\Documents\Arduino\MyDisplay\MyDisplay.ino

09:49:02.914 -> Starting...

upload:

esptool.py v4.5.1
Serial port COM16
Connecting......................................

A fatal error occurred: Failed to connect to ESP32: Invalid head of packet (0x3A): Possible serial noise or corruption.
For troubleshooting steps visit: Troubleshooting - ESP32 - — esptool.py latest documentation
Failed uploading: uploading error: exit status 2

What processor/board did you select to compile for?

Power supply might also be an issue. The LDO seems to be too weak.
I had glued a USB to serial adapter, and a LD1117V33 LDO, to supply strong 3.3V to the board

I selected ESp32 dev module
is that correct ?

Yes. I had misunderstood you first post. I thought you had an issue with an ESP32S3.
That's why I tried to answer. With a standard ESP32 with USB to serial chip and the connected reset/boot circuit, download should always be possible.
You could try to at a LiPo battery for stable supply.
I can't help any more.

I connected a 18650 battery and power is stable.
In your previous answer you wrote "LDO seems to be too weak"
where do you see that ?

And you wrote:

"Push both rst and boot button. Then release first the rst button, then the boot button.
Then you need to select the changed USB port in the IDE."

but I do not see any com port change when I do that button combination. I can only verify that it goes into download mode from serial monitor (it says "waiting for download" instead of the boot loop)

So what might be wrong here ?

That would be the case with ESP32S3.

I used countermeasures on my board. But that was 2 years ago.

Bye and out.

ok thanks.
I found the problem. it was about "JTAG adapter" setting on the IDE.
I changed it to "USB bridge" and now upload is successful.