I had a working platformio / ESP32-S3 LILYGO T5 e paper configuration, updating the firmware with esptool. On the last successful update of the firmware, I messed up and now in Serial Monitor, I can see the code is panicking and in a cycle of constant reboots:
Start of setup
Guru Meditation Error: Core 1 panic’ed (StoreProhibited). Exception was unhandled.
Core 1 register dump:
PC : 0x400570e8 PS : 0x00060630 A0 : 0x82001878 A1 : 0x3fcebdf0
A2 : 0x00000000 A3 : 0xffffffff A4 : 0x0003f480 A5 : 0x00000000
A6 : 0x02c945e0 A7 : 0x00003f48 A8 : 0x8200182c A9 : 0x3fcebd70
A10 : 0x00000003 A11 : 0x00000003 A12 : 0x00000003 A13 : 0x000003e5
A14 : 0x3fcebdbc A15 : 0x000f4240 SAR : 0x00000000 EXCCAUSE: 0x0000001d
EXCVADDR: 0x00000000 LBEG : 0x400570e8 LEND : 0x400570f3 LCOUNT : 0x00003f47
Backtrace: 0x400570e5:0x3fcebdf0 |<-CORRUPTED
ELF file SHA256: 240928e468cd81e4
Rebooting…
ESP-ROM:esp32s3-20210327
Build:Mar 27 2021
rst:0xc (RTC_SW_CPU_RST),boot:0x2f (SPI_FAST_FLASH_BOOT)
Saved PC:0x420216c2
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fce3808,len:0x44c
load:0x403c9700,len:0xbe4
load:0x403cc700,len:0x2a68
entry 0x403c98d4
My challenge now though is that if I try to upload new firmware… esptool isn’t happy:
Retrieving maximum program size .pio\build\lilygo-t-display-s3\firmware.elf
Checking size .pio\build\lilygo-t-display-s3\firmware.elf
Advanced Memory Usage is available via “PlatformIO Home > Project Inspect”
RAM: [= ] 5.7% (used 18720 bytes from 327680 bytes)
Flash: [ ] 3.8% (used 248645 bytes from 6553600 bytes)
Configuring upload protocol…
AVAILABLE: cmsis-dap, esp-bridge, esp-builtin, esp-prog, espota, esptool, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa
CURRENT: upload_protocol = esptool
Looking for upload port…
Auto-detected: COM12
Uploading .pio\build\lilygo-t-display-s3\firmware.bin
esptool.py v4.5.1
Serial port COM12
Connecting…
A serial exception error occurred: Write timeout
My thinking is that the broken code running on the esp32 is rebooting, whilst esptool is trying to update the firmware. If I hold down the reset button, on the LILYGO and wait 'till platformio is trying to upload… I can get a little further:
Looking for upload port…
Auto-detected: COM12
Uploading .pio\build\lilygo-t-display-s3\firmware.bin
esptool.py v4.5.1
Serial port COM12
Connecting…
Chip is ESP32-S3 (revision v0.1)
Features: WiFi, BLE
Crystal is 40MHz
MAC: 34:85:18:70:4e:a0
Uploading stub…
Running stub…
Stub running…
Changing baud rate to 460800
A fatal error occurred: No serial data received.
*** [upload] Error 2
Anyone got any suggestions on how I can get out of this hole I have dug for myself!