-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
STM32F030R8T6: flash loader run error #958
Comments
Maybe I know what’s the problem here. May you try my branch(with a quick and dirty fix , just as a proof of my thought)? /~https://github.com/chenguokai/stlink/tree/stlink-v3_pre If I am right, the issue is related to the non-PIC code of new flashloaders combined with a dirty fix in flashloader.c. |
I've built from your branch and can confirm, it fixes the problem. |
@chenguokai: What do we have here? |
As I mentioned, the GPL licensed flashloaders, is PIC (position independent code) while the new ones, are not. That’s also why I needed to write a linker script, specifying the base address. By disassembling the compiled flashloaders, I recognized the addressing mode to be PC(program counter) relative. I thought they are kinds of PIC, so I kept the dirty hack as a marco in flashloader.c. From this issue, I can confirm that flashloader code is definitely not PIC, so the two nops should be added to the flashloader code rather than appended before a binary. |
Ok then, you may hand in a PR for the June release, but make sure to branch of |
@grzegorz-kraszewski Please verify if my PR fixes this problem :-) |
Fixes for STM32F0 flashloader (Closes #958)
Not sure, as it triggers another one:
|
@grzegorz-kraszewski: This looks like a different topic. Please open a new ticket for that. |
Does a relaunch or a unplug and plug help? |
Commandline-Output:
Expected/description:
Expect it to be flashed of course. More info:
The text was updated successfully, but these errors were encountered: