Description
Hello,
looks like I do something wrong, as I can't flash dap42 to an blue-pill.
- Using Windows 10 20H2, GNU Arm-none-eabi 10.2.1, Git bash
- Its a 128kB device, tested with STMFlashLoader.
- I am able to flash dapboot, it is recognized in Windows and appears as "DAPBoot DFU Bootloader" in the device manager.
- lsusb shows no problems:
Bus 003 Device 007: ID 1209:db42
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.10
bDeviceClass 0
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x1209
idProduct 0xdb42
bcdDevice 1.11
iManufacturer 1
iProduct 2
iSerial 3
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 0x001b
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xc0
Self Powered
MaxPower 100mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 254
bInterfaceSubClass 1
bInterfaceProtocol 2
iInterface 4 DAPBoot DFU
Device Firmware Upgrade Interface Descriptor:
bLength 9
bDescriptorType 33
bmAttributes 11
Will Detach
Manifestation Intolerant
Upload Supported
Download Supported
wDetachTimeout 255 milliseconds
wTransferSize 1024 bytes
bcdDFUVersion 1.10
Binary Object Store Descriptor:
bLength 5
bDescriptorType 15
wTotalLength 0x001d
bNumDeviceCaps 1
Platform Device Capability:
bLength 24
bDescriptorType 16
bDevCapabilityType 5
bReserved 0
PlatformCapabilityUUID {3408b638-09a9-47a0-8bfd-a0768815b665}
WebUSB:
bcdVersion 1.00
bVendorCode 1
iLandingPage 1 https://devanlai.github.io/webdfu/dfu-util/
can't get debug descriptor: No such file or directory
Device Status: 0x0000
(Bus Powered)
I have built DAP103-BLUEPILL-DFU.bin, as this should be the right binary, when a DFU bootloader is present.
I went in the ./src subdirectory, and started there make TARGET=STM32F103-BLUEPILL-DFUBOOT dfuse-flash
, here is the first thing, where I am struggeling: It looks like, that DAP42.bin is hardcoded, and the TARGET definition is not honored.
dfu-util -d 1209:da42,0483:df11 -a 0 -s 0x08000000:leave -D DAP42.bin
This leads to an dfu-util error:
dfu-util 0.9
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2020 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/
Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
No DFU capable USB device available
However a dfu-util -l
shows:
dfu-util 0.9
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2020 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/
Found DFU: [1209:db42] ver=0111, devnum=7, cfg=1, intf=0, path="3-5.4.6", alt=0, name="DAPBoot DFU", serial="194425875177485752FF7306"
The error stays the same, when I use 'DAP103-BLUEPILL-DFU.bin' as the binary.
Same happens, when I correct the USB VID/PID address in 1209:db42,0483:df11, as this is the PID, the device appears in the device-manager.
Playing with all parameters I came up to this short command:
'dfu-util.exe -d 1209:db42 -a 0 -D DAP103-BLUEPILL-DFU.bin' , the first, where dfu-util succeded, but with an error:
dfu-util 0.9
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2020 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/
Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
Opening DFU capable USB device...
ID 1209:db42
Run-time device DFU version 0110
Claiming USB DFU Interface...
Setting Alternate Setting #0 ...
Determining device status: state = dfuIDLE, status = 0
dfuIDLE, continuing
DFU mode device DFU version 0110
Device returned transfer size 1024
Copying data from PC to DFU device
Download [=========================] 100% 13652 bytes
Download done.
state(7) = dfuMANIFEST, status(0) = No error condition is present
unable to read DFU status after completion
After this, the device is dead: Nothing happens, when un and re-plugging, even not a single USB-error. Its just completly dead.
I need to go back, set the BOOT0-jumper and reflash the bootloader.
Thats where I stand now clueless.