Flashing Fail

Sysprogs forums Forums VisualGDB Flashing Fail

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #27965
    shruthi
    Participant

    Hi there,

    I have problem while flashing the software to stm 32. I am using ST link for debugging.

     

    Flashing was working fine, but after while, i am getting getting the error as “Error finishing flash operation”. 

    In openOCD i am getting the error as below.

    Info : flash_write_start:0x8020400|0x80c7528|stm32f4x.flash
    Error: timeout waiting for algorithm, a target reset is recommended
    Info : flash_write_done:stm32f4x.flash
    Error: error executing stm32x flash write algorithm
    Error: flash write failed = 00000040
    Error: error writing to flash at address 0x08000000 at offset 0x00020400
    Info : Unable to match requested speed 2000 kHz, using 1800 kHz
    Info : Unable to match requested speed 2000 kHz, using 1800 kHz
    adapter speed: 1800 kHz
    target halted due to debug-request, current mode: Thread

     

    Please help me to solve this problem.

     

    Thank you

    #27966
    support
    Keymaster

    Hi,

    Sorry, this looks like a bug in OpenOCD. As the OpenOCD’s FLASH programming logic is maintained by ST, we don’t have many insights into it, however based on our previous experience, trying to rearrange various sections of your program (e.g. making sure they are aligned and none of them is too small) should fix it.

    You can also try building OpenOCD from sources as shown here. Alternatively, please consider trying Segger J-Link. It comes with its own GDB stub that is more reliable than OpenOCD, and usually just works out-of-the-box.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.