Page 1 of 1

Cant Flash Copy of Devkit

Posted: Fri Feb 14, 2020 9:17 pm
by mikeoto
Hi,

We just spun our first board and are having issues flashing the esp32 WROOM 32D module. The USB circuit is the exact same as the devkitc v4 (https://dl.espressif.com/dl/schematics/ ... v4-sch.pdf).

The logs of the devkit flashing and our board flashing are below- our board gets hung up after the board is recognised and after the first write.

DEVKIT FLASHING (working)
  1. Executing "/home/mike/.espressif/python_env/idf4.1_py2.7_env/bin/python /home/mike/esp/esp-idf/components/esptool_py/esptool/esptool.py -p /dev/ttyUSB0 -b 460800 --before default_reset --after hard_reset write_flash @flash_project_args"...
  2. esptool.py -p /dev/ttyUSB0 -b 460800 --before default_reset --after hard_reset write_flash --flash_mode dio --flash_freq 40m --flash_size 2MB 0x8000 partition_table/partition-table.bin 0x1000 bootloader/bootloader.bin 0x10000 mair-template.bin
  3. esptool.py v2.9-dev
  4. Serial port /dev/ttyUSB0
  5. Connecting......
  6. Detecting chip type... ESP32
  7. Chip is ESP32D0WDQ5 (revision 1)
  8. Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
  9. Crystal is 40MHz
  10. MAC: c4:4f:33:3e:da:f5
  11. Uploading stub...
  12. Running stub...
  13. Stub running...
  14. Changing baud rate to 460800
  15. Changed.
  16. Configuring flash size...
  17. Compressed 3072 bytes to 103...
  18. Wrote 3072 bytes (103 compressed) at 0x00008000 in 0.0 seconds (effective 4232.2 kbit/s)...
  19. Hash of data verified.
  20. Compressed 25472 bytes to 15107...
  21. Wrote 25472 bytes (15107 compressed) at 0x00001000 in 0.3 seconds (effective 599.4 kbit/s)...
  22. Hash of data verified.
  23. Compressed 174416 bytes to 90872...
  24. Wrote 174416 bytes (90872 compressed) at 0x00010000 in 2.1 seconds (effective 675.3 kbit/s)...
  25. Hash of data verified.
  26.  
  27. Leaving...
  28. Hard resetting via RTS pin...
MY BOARD (not working)
  1. Executing "/home/mike/.espressif/python_env/idf4.1_py2.7_env/bin/python /home/mike/esp/esp-idf/components/esptool_py/esptool/esptool.py -p /dev/ttyUSB0 -b 460800 --before default_reset --after hard_reset write_flash @flash_project_args"...
  2. esptool.py -p /dev/ttyUSB0 -b 460800 --before default_reset --after hard_reset write_flash --flash_mode dio --flash_freq 40m --flash_size 2MB 0x8000 partition_table/partition-table.bin 0x1000 bootloader/bootloader.bin 0x10000 mair-template.bin
  3. esptool.py v2.9-dev
  4. Serial port /dev/ttyUSB0
  5. Connecting.....
  6. Detecting chip type... ESP32
  7. Chip is ESP32D0WDQ5 (revision 1)
  8. Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
  9. Crystal is 40MHz
  10. MAC: c8:2b:96:9f:01:70
  11. Uploading stub...
  12. Running stub...
  13. Stub running...
  14. Changing baud rate to 460800
  15. Changed.
  16. Configuring flash size...
  17. Compressed 3072 bytes to 103...
  18. Wrote 3072 bytes (103 compressed) at 0x00008000 in 0.0 seconds (effective 4280.0 kbit/s)...
  19.  
  20. A fatal error occurred: Timed out waiting for packet header
Let me know what you think this could mean, Im at a loss right now. On both boards, the boot and enable pins move correctly and it seems like even on the devkit it is recognizing the esp32 chip at least somewhat.

Re: Cant Flash Copy of Devkit

Posted: Sat Feb 15, 2020 10:01 am
by ESP_Sprite
Are you sure the pins to the flash chip are all OK? It smells like the stub waits for the flash to respond to something...

Re: Cant Flash Copy of Devkit

Posted: Tue Feb 18, 2020 1:51 pm
by mikeoto
Im not using the flash SPI pins for anything else, although they are broken out to a header (which is unpopulated). I will probe those pins to see if they look funky during startup. Let me know if you have any other ideas. Thanks!

Re: Cant Flash Copy of Devkit

Posted: Tue Feb 18, 2020 3:19 pm
by mikeoto
Found a short between CLK and SD0 under the module, thanks for the tip Sprite. Saved me a lot of time!