-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to flash Blue Pill #13
Comments
Hi @Wosamarak, I'm not sure why the final result isn't working, though there are some areas where I could probably make the build and flash process a bit less confusing. I wrote the main Makefile under The other confusing part is that there are two similarly named rules, The "unable to read DFU status after completion" is normal for Could you attach a copy of the |
Hello, something must be different between our compilers. My binary is 144 bytes bigger than yours, but yours is working! Right now, I have no clue, whats going on. And: You are right: The error message regarding the DFU status is also appearing here. In the meantime I also tried some more things. As my dfu-util 0.9 was not willing to give me verbose information, I went to dfu-util 1.0 from their sourceforge site. This is unwilling to flash even your binary, stating that the file ID does not match the device ID. 'dfu-util.exe -d 1209:da42 -D build/DAP103-BLUEPILL-DFU.bin' Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc. Warning: Invalid DFU suffix signature |
Hmm, well, now I'm even more puzzled. I built a copy of dfu-util from git tag v0.10 and I can't see get the File ID error to reproduce. The file VID/PID is initialized to Additionally, I loaded the |
I disassembled both binaries and tried to compare, but unfortunately the code is very different. The difference starts already in the first lines, where just different registers are used. So comparing binaries makes less sense (however I attach an difference-report). In addition I added some more C and CXX flags: 'CFLAGS += -Wa,-adhln=$@.s -g -fverbose-asm', to create additional assembler files with corresponding c-files. Comparing those with yours, should reveal more details about the difference. |
I was originally concerned that there might be latent bugs in the source code that might have surfaced when compiling with the newer version of gcc, but since your firmware binary seems to run fine on my bluepill, I no longer think that's likely to be the root cause of your problems. At this point, other than ruling out weirdness with dfu-util, there's not a lot I can do to troubleshoot this remotely. If you want to keep digging, you could flash a second bluepill or find another debugger and then debug the firmware to see why it fails to enumerate. Otherwise if the version of firmware I built is working for you when you flash it, you could just stick with that. |
Thanks for all your help! For the first step I will stick with your firmware, as that is running. And yes: I will try it with another Bluepill. Maybe mine has some flash problem at the end of the slightly larger code. |
Hello,
looks like I do something wrong, as I can't flash dap42 to an blue-pill.
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
However a
dfu-util -l
shows:
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:
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.
The text was updated successfully, but these errors were encountered: