SparkFun Forums 

Where electronics enthusiasts find answers.

User avatar
By skyfly200
#208247
I'm getting this error when trying to upload any sketch to my ESP32 Thing board
Arduino: 1.8.5 (Windows 8.1), Board: "SparkFun ESP32 Thing, 80MHz, Default, 921600, None"

Sketch uses 199724 bytes (15%) of program storage space. Maximum is 1310720 bytes.
Global variables use 13524 bytes (4%) of dynamic memory, leaving 314156 bytes for local variables. Maximum is 327680 bytes.
esptool.py v2.6
Serial port COM5
Connecting....
Chip is ESP32D0WDQ6 (revision 1)
Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
MAC: 30:ae:a4:bb:fb:30
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 921600
Changed.
Configuring flash size...
Warning: Could not auto-detect Flash size (FlashID=0xffffff, SizeID=0xff), defaulting to 4MB
Compressed 8192 bytes to 47...

A fatal error occurred: Timed out waiting for packet content
A fatal error occurred: Timed out waiting for packet content

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
User avatar
By TS-Mark
#208263
Hi skyfly200,

Try holding down the GPIO 0 button before hitting "Upload" and keep it held down until esptool.py starts to run. You may need to turn on "Verbose Output" to see that in the printout from the IDE. To do that, go to your "Preferences" menu and click the boxes next to "Show verbose output during" for both Compilation and Upload.

If that does not fix the issue, let us know and we can troubleshoot further.
By paulvha
#208266
This error occurs when you keep the serial monitor open while uploading. The serial monitor will "read" the response the esptool.py is expecting from the ESP32. Make sure to close the monitor before starting compile/upload.
User avatar
By jsy360
#208536
Hi - I am having similar issues.

I'm getting:
"A fatal error occurred: Timed out waiting for packet header".

When I hold down the 0 button on the ESP32 Thing, I get:
"A fatal error occurred: Invalid head of packet (0x86)"

When I flash at 40Hz, I get:
"A fatal error occurred: MD5 of file does not match data in flash!"

How did everyone else solve this problem?
User avatar
By TS-Mark
#208620
Hi jsy360,

Can you please provide a bit more information about which board you are uploading to (we carry a couple of ESP32 Things now so it might be an issue of the wrong board) and what selections you have made in the boards tool? If possible, can you take a screenshot of your settings in that menu? Also, which version of Arduino and the ESP32 Arduino Core are you running and what operating system are you using?