Hi Experts ,
Wanted to know is ....
To flash app of 1217936 bytes (663495 compressed) it took 58.9 seconds (effective 165.5 kbit/s). ( Not added bootloader.bin and partition table programming time )
Any Ideas why the programming is so slow (58 seconds).Is the speed of the part itself ( ESP32D0WDQ6 ) ? which is 40MHZ ??
Could this time be sped up considerable? say 10 - 15 sec around or better then this.
The reason I am asking these questions is from production point of view.
satish
Flash timing
Re: Flash timing
You are likely uploading at the default baud rate, 115200. So upload speed is limited by serial connection throughput, not by flash frequency.effective 165.5 kbit/s
If the connections between ESP32 and the USB-UART are short enough, you can try increasing this baud rate. 921600 baud usually works on development boards, some (FT2232- and CP2104-based, at least) are capable of 2-3 Mbaud.
So yes, tenfold improvement is possible if you can increase baud rate.
Re: Flash timing
thanks ESP_igrr .
Changing baud to 921600 baud gave following o/p....
Compressed 1217936 bytes to 663495...
Wrote 1217936 bytes (663495 compressed) at 0x00010000 in 14.1 seconds (effective 693.1 kbit/s)...
But when i tried using 2M as baud rate it shows following error ..
Running stub...
Stub running...
Changing baud rate to 2000000
Changed.
Configuring flash size...
A fatal error occurred: Timed out waiting for packet header
make: *** [/c/esp-idf-v2.1/components/esptool_py/Makefile.projbuild:53: flash] Error 2
Im using ESP32WROOM devkit for prototyping and want to optimize flashing time to the best so that we can estimate flash time during production.
Changing baud to 921600 baud gave following o/p....
Compressed 1217936 bytes to 663495...
Wrote 1217936 bytes (663495 compressed) at 0x00010000 in 14.1 seconds (effective 693.1 kbit/s)...
But when i tried using 2M as baud rate it shows following error ..
Running stub...
Stub running...
Changing baud rate to 2000000
Changed.
Configuring flash size...
A fatal error occurred: Timed out waiting for packet header
make: *** [/c/esp-idf-v2.1/components/esptool_py/Makefile.projbuild:53: flash] Error 2
Im using ESP32WROOM devkit for prototyping and want to optimize flashing time to the best so that we can estimate flash time during production.
-
- Posts: 9761
- Joined: Thu Nov 26, 2015 4:08 am
Re: Flash timing
Are you sure your USB-to-serial converter is capable of running at 2MBaud, and your wiring is short enough not to cause capacitance issues with those frequencies?
Edit: ESP32WROOM devkit: do you mean DevkitC or an ESP32-Wroom module?
Edit: ESP32WROOM devkit: do you mean DevkitC or an ESP32-Wroom module?
-
- Posts: 9761
- Joined: Thu Nov 26, 2015 4:08 am
Re: Flash timing
DevkitC uses an CP2102 converter; that chip unfortunately maxes out at 921.6KBaud.
Re: Flash timing
Is it a limitation of the devkitC?
Can the part be programmed though the JTag interface as well?
Can the part be programmed though the JTag interface as well?
-
- Posts: 9761
- Joined: Thu Nov 26, 2015 4:08 am
Re: Flash timing
Yes, it is; the CP2102 on the DevkitC is the bottleneck here. As far as I'm aware, all the JTAG pins are available on this devboard, so using an external JTAG adapter is an option. You may also be able to connect a different USB-to-JTAG converter (CP2104, FT232, ...) to the board and use that to flash faster.
Re: Flash timing
I have a WROVER devkit (with WROVER module) which I believe uses the FT2232H USB to UART. When I try and flash at 2000000 baud, I don't see any change as compared to flashing at 921600. The command I am using on Ubuntu hosted on VirtualBox hosted on Windows 10 is:
$ make flash ESPBAUD=2000000
The timing I get are:
921600 = ~8.5 seconds
115200 = ~42 seconds
2000000 = ~8.5 seconds
(all the above for the same flash image ... 910832 uncompressed but 472167 compressed)
$ make flash ESPBAUD=2000000
The timing I get are:
921600 = ~8.5 seconds
115200 = ~42 seconds
2000000 = ~8.5 seconds
(all the above for the same flash image ... 910832 uncompressed but 472167 compressed)
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32
Who is online
Users browsing this forum: No registered users and 112 guests