ESP32 upload to show updaes while uploading


#1

I just found PlatformIO, and so far its nice. There is just one issue that I would like to see if I can correct.
When I upload to my ESP32 board I get the following in the terminal window.


Hash of data verified.
Compressed 3072 bytes to 82…
Wrote 3072 bytes (82 compressed) at 0x00008000 in 0.0 seconds (effective 4915.3 kbit/s)…
Hash of data verified.
Compressed 484752 bytes to 267616…

It hangs here for about 20 seconds while its uploading. then it will comes back with:

Wrote 484752 bytes (267616 compressed) at 0x00010000 in 7.9 seconds (effective 491.3 kbit/s)…
Hash of data verified.

Leaving…
Hard resetting…
[SUCCESS] Took 23.30 seconds

Why does it not show the % while its uploading ?
I would expect to see something like:
Writing at 0x00010000… (5 %)
Writing at 0x00014000… (10 %)
Writing at 0x00018000… (15 %)
Writing at 0x0001c000… (21 %)
Writing at 0x00020000… (26 %)
Writing at 0x00024000… (31 %)
Writing at 0x00028000… (36 %)


#2

Could you open PIO IDE Terminal and manually type pio run -t upload --verbose. Could you share the output on https://hastebin.com?


#3

Sure.

PS C:\Users\Mike\Documents\PlatformIO\Projects\171213-172003-hornbill32dev> pio run -t upload --verbose
[12/15/17 07:28:16] Processing hornbill32dev (platform: espressif32; upload_speed: 460800; board: esp32dev; framework: espidf)

Collected 0 compatible libraries
Looking for dependencies…
No dependencies
MethodWrapper([“upload”], [".pioenvs\hornbill32dev\firmware.bin"])
Auto-detected: COM30
"c:\users\mike.platformio\penv\scripts\python.exe" “C:\Users\Mike.platformio\packages\tool-esptoolpy\esptool.py” --chip esp32 --port “COM30” --baud 460800 --before default_reset --after hard_rese
t write_flash -z --flash_mode dio --flash_freq 40m --flash_size detect 0x1000 C:\Users\Mike\Documents\PlatformIO\Projects\171213-172003-hornbill32dev.pioenvs\hornbill32dev\bootloader.bin 0x8000 C

C:\Users\Mike\Documents\PlatformIO\Projects\171213-172003-hornbill32dev.pioenvs\hornbill32dev\partitions_table.bin 0x10000 .pioenvs\hornbill32dev\firmware.bin
esptool.py v2.1
Connecting…_
Chip is ESP32D0WDQ6 (revision 1)
Uploading stub…
Running stub…
Stub running…
Changing baud rate to 460800
Changed.
Configuring flash size…
Auto-detected Flash size: 4MB
Compressed 16784 bytes to 9687…
Wrote 16784 bytes (9687 compressed) at 0x00001000 in 0.2 seconds (effective 566.5 kbit/s)…
Hash of data verified.
Compressed 3072 bytes to 82…
Wrote 3072 bytes (82 compressed) at 0x00008000 in 0.0 seconds (effective 4915.1 kbit/s)…
Hash of data verified.
Compressed 484880 bytes to 267740…
Wrote 484880 bytes (267740 compressed) at 0x00010000 in 8.0 seconds (effective 486.0 kbit/s)…
Hash of data verified.

Leaving…
Hard resetting…
================================================================================== [SUCCESS] Took 34.59 seconds ==================================================================================
PS C:\Users\Mike\Documents\PlatformIO\Projects\171213-172003-hornbill32dev>


#4

I don’t see option which allows to increase verbosity. Please ask here https://github.com/espressif/esptool/issues

~/.platformio/packages/tool-esptoolpy/esptool.py --help
usage: esptool [-h] [--chip {auto,esp8266,esp32}] [--port PORT] [--baud BAUD]
               [--before {default_reset,no_reset}]
               [--after {hard_reset,soft_reset,no_reset}] [--no-stub]
               {load_ram,dump_mem,read_mem,write_mem,write_flash,run,image_info,make_image,elf2image,read_mac,chip_id,flash_id,read_flash_status,write_flash_status,read_flash,verify_flash,erase_flash,erase_region,version}
               ...

esptool.py v2.1 - ESP8266 ROM Bootloader Utility

positional arguments:
  {load_ram,dump_mem,read_mem,write_mem,write_flash,run,image_info,make_image,elf2image,read_mac,chip_id,flash_id,read_flash_status,write_flash_status,read_flash,verify_flash,erase_flash,erase_region,version}
                        Run esptool {command} -h for additional help
    load_ram            Download an image to RAM and execute
    dump_mem            Dump arbitrary memory to disk
    read_mem            Read arbitrary memory location
    write_mem           Read-modify-write to arbitrary memory location
    write_flash         Write a binary blob to flash
    run                 Run application code in flash
    image_info          Dump headers from an application image
    make_image          Create an application image from binary files
    elf2image           Create an application image from ELF file
    read_mac            Read MAC address from OTP ROM
    chip_id             Read Chip ID from OTP ROM
    flash_id            Read SPI flash manufacturer and device ID
    read_flash_status   Read SPI flash status register
    write_flash_status  Write SPI flash status register
    read_flash          Read SPI flash content
    verify_flash        Verify a binary blob against flash
    erase_flash         Perform Chip Erase on SPI flash
    erase_region        Erase a region of the flash
    version             Print esptool version

optional arguments:
  -h, --help            show this help message and exit
  --chip {auto,esp8266,esp32}, -c {auto,esp8266,esp32}
                        Target chip type
  --port PORT, -p PORT  Serial port device
  --baud BAUD, -b BAUD  Serial port baud rate used when flashing/reading
  --before {default_reset,no_reset}
                        What to do before connecting to the chip
  --after {hard_reset,soft_reset,no_reset}, -a {hard_reset,soft_reset,no_reset}
                        What to do after esptool.py is finished
  --no-stub             Disable launching the flasher stub, only talk to ROM
                        bootloader. Some features will not be available.

#5

I have the same problem. When I run the esptool commandline directly I get the progress report. The progress report only disapears when esptool is called by platformio.


#6

How do you call it manually?