2024-10-08 10:42 PM - last edited on 2024-10-09 04:49 AM by SofLit
Tried flashing stm32f412 custom controller using uart but facing error while going to boot mode.
Tried flashing using stlink, connected but failed to erase memory and application exiting automatically.
2024-10-09 02:00 AM - edited 2024-10-09 02:02 AM
Hello @Vaishnavi and welcome to the Community,
Ensure that both the ST-Link firmware and STM32CubeProgrammer are updated to the latest versions.
Check the power supply to the board and check the jumper settings.
Try select the "Connect Under Reset" mode in STM32CubeProgrammer and erase the whole MCU.
Hope these steps and tips help you resolve your issue.
2024-10-09 02:27 AM
Hi @Imen.D
Stlink and cubeprogrammer are using updated version only
Connected under reset only, its connecting but unable to erase whole mcu
2024-10-09 03:48 AM
What's going on with the VCAP pin(s) ?
Do you see 1.25v there?
Have you placed 4.7uF total capacitance on them? And not omitted or placed wrong values?
2024-10-09 04:35 AM - edited 2024-10-09 04:59 AM
Hello,
As requested in this thread, please share your schematics.
2024-10-09 04:42 AM
Hello @SofLit
I'm trying to flash my hex file to stm32f412 controller using stlink, but after connecting getting error
15:01:09 : Erasing memory corresponding to segment 0:
15:01:09 : Erasing internal memory sector 0
15:01:09 : Error: failed to erase memory
15:01:09 : Error: failed to erase memory
2024-10-09 04:47 AM - edited 2024-10-09 04:49 AM
@Vaishnavi wrote:Tried flashing stm32f412 custom controller using uart but facing error while going to boot mode.
:
I need to flash my hex file to custom stm32f412 board but unable to connect using uart and facing issue while erase memory
I thought the UART part was addressed in your other thread - marked as solved:
So is this thread just about the ST-Link part?
As noted, you need to show your schematics:
A good, clear photograph could also help
2024-10-09 04:51 AM
Modified the post to focus on STLINK.
The system bootloader usage has been answered in this thred: https://community.st.com/t5/stm32cubeprogrammer-mcus/flash-hex-file-to-stm32f412-with-uart-using-stm32cubeprogrammer/td-p/729115
2024-10-09 10:50 PM
Hello
I'm using stlink to flash my hex file to stm32f412, PA13-SWDIO and PA14-SWCLK
But unable to flash getting error, after connecting
15:01:09 : Erasing memory corresponding to segment 0:
15:01:09 : Erasing internal memory sector 0
15:01:09 : Error: failed to erase memory
15:01:09 : Error: failed to erase memory
And application is closing automatically
2024-10-10 01:23 AM
Again, please share your schematics. The information you are sharing doesn't help.