RAK11200 Stuck on Boot Loop

I’m unable to flash to the RAK11200. It keeps on outputting this to the serial monitor (on both boot connected to gnd and not connected):

rst:0x3 (SW_RESET),boot:0x17 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:1184
load:0x40078000,len:13232
load:0x40080400,len:3028
entry 0x400805e4

I have tried to flash the simplest programs via arduino using the settings in the documentation and it keeps on giving:

Connecting........_____....._____....._____....._____....._____....._____....._____

A fatal error occurred: Failed to connect to ESP32: Invalid head of packet (0x65)

I have also tried

python -m esptool --chip esp32 erase_flash

From which I got

Connecting......................................

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

Hi @spacefarers ,

Can you confirm first if the RAK11200 is in bootloader mode? You can check its serial output while connecting the BOOT pin to ground followed by reset.

Yes I was previously able to flash to it but now it is stuck on boot loop regardless of whether the boot pin is grounded.

Hi @spacefarers ,

Try to enable boot mode again but check on Serial terminal if the ESP32 really goes to bootloader mode. You should see something like waiting for download if you successfully put it in bootloader mode.