stm32f411ce LIBUSB_ERROR_PIPE while writing firmware
Multiplatform USB DFU host utility
Brought to you by:
tormod
When I try
dfu-util.exe -d 0483:df11 -a "@Internal Flash /0x08000000/04*016Kg,01*064Kg,03*128Kg" --dfuse-address 0x08000000 -D adafruit-circuitpython-stm32f411ce_blackpill-en_US-7.3.0.bin
I get
dfu-util 0.11
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2021 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to http://sourceforge.net/p/dfu-util/tickets/
Warning: Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release
Opening DFU capable USB device...
Device ID 0483:df11
Device DFU version 011a
Claiming USB DFU Interface...
Setting Alternate Interface #0 ...
Determining device status...
DFU state(10) = dfuERROR, status(10) = Device's firmware is corrupt. It cannot return to run-time (non-DFU) operations
Clearing status
Determining device status...
DFU state(2) = dfuIDLE, status(0) = No error condition is present
DFU mode device DFU version 011a
Device returned transfer size 2048
DfuSe interface name: "Internal Flash "
Downloading element to address = 0x08000000, size = 475340
Erase [=========================] 100% 475340 bytes
Erase done.
Download [=== ] 13% 63488 bytesdfuse_download: libusb_control_transfer returned -9 (LIBUSB_ERROR_PIPE)
Error during download
The percentage at which it fails varies, I saw for example 2%, 12%, 13%.
With .bin files of completely different firmware, it fails at other percentages, for example 0% or 8%.
It sometimes also fails at 0% of erasure. For small .bin files more often than for large ones.
I tried several different cables (several USB C and a USB Micro-B with an adaptor to USB C), but to no avail.
I also tried dfu-util version 0.7. Same problem there:
Downloading to address = 0x08000000, size = 475340
.................................dfuse_download: libusb_control_transfer returned -9
Error during download
Failed to write whole chunk: -9 of 2048 bytes
How can this be fixed? Thank you!
Anonymous
Please follow the instructions on https://sourceforge.net/p/dfu-util/tickets/new/
The same problem. I patch quirks.h, quirks.c to add "quirks |= QUIRK_POLLTIMEOUT" for my vendor and product ID. My version 0.11+ saved at https://github.com/azorg/dfu-util
Please if you upload the source to github or anywhere else, upload the whole git history with your changes on top. In other words, pull the official git tree, make your changes, and push to wherever.
Still waiting for complete information.
I don't quite know if this is related, but I'm getting the same error on an upload (to my linux machine). The chip is from the same series, but I don't know the exact name.