cancel
Showing results for 
Search instead for 
Did you mean: 

Error when debugging: Failed to execute MI command

MRey.1
Associate III

I have a project that ran without issue, with STM32CubeIDE 1.13.0. When I updated it to 1.17.0 I could no longer debug that same project. The error window says:

Error in final launch sequence:

 

Failed to execute MI command:

load D:\\Proyectos\\STM32CubeIDE\\XXXX\\XXXX\\Debug\\XXXX.elf

 

Error message from debugger back end:

Error finishing flash operation

Failed to execute MI command:

load D:\\Proyectos\\STM32CubeIDE\\XXXX\\XXXX\\Debug\\XXXX.elf

 

Error message from debugger back end:

Error finishing flash operation

Failed to execute MI command:

load D:\\Proyectos\\STM32CubeIDE\\XXXX\\XXXX\\Debug\\XXXX.elf

 

Error message from debugger back end:

Error finishing flash operation

Error finishing flash operation

 

I added the log file in case it helps

1 ACCEPTED SOLUTION

Accepted Solutions

Pffft - not elf (but debug launch- maybe.).

I try in such "strange" cases: use the other debug !  (and watch for every possible error or warning message !!!)

So ST/GDB -> open OCD , set generator options ! (to same...software reset, etc.), then try...

i had sometimes very starnge effects : suddenly  debug no more working...switch to OCD , not working...switch back to using GDB - hey works again ! So try...play a little bit around.

If you feel a post has answered your question, please click "Accept as Solution".

View solution in original post

6 REPLIES 6
AScha.3
Chief III

Maybe st-link needs update first...did you try ?

+

connect using CubeProgrammer , and show, what its telling. (set connect: normal, software reset)

If you feel a post has answered your question, please click "Accept as Solution".

Thanks for the reply

Yes, I forgot to add that I also updated the STLINK-V3 firmware

I used CubeProgrammer and had no errors:

MRey1_1-1743452214119.png

 

 

Good,

so it should work in IDE also. Just set same ...(set connect: normal, software reset)

because obvious: st-link and your cpu ok, can connect. So just the settings in IDE could ... be not so good.

If you feel a post has answered your question, please click "Accept as Solution".

I just did it, but it shows the same error. Could it be an error in the .elf or launch files after updating?

Pffft - not elf (but debug launch- maybe.).

I try in such "strange" cases: use the other debug !  (and watch for every possible error or warning message !!!)

So ST/GDB -> open OCD , set generator options ! (to same...software reset, etc.), then try...

i had sometimes very starnge effects : suddenly  debug no more working...switch to OCD , not working...switch back to using GDB - hey works again ! So try...play a little bit around.

If you feel a post has answered your question, please click "Accept as Solution".

I couldn't make it work with GDB, but it debugs successfully with OCD

I can use it as is, but I'll try to make it work with GDB if it can be fixed

Many thanks AScha!