[SOLVED] j_link message: active write protected STM32 device detected..............

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] j_link message: active write protected STM32 device detected..............

    Hello Community,

    I'm new to using jlink probe. I am using crossworks and trying to connect to an stm32f7 board with the jlink-edu. The message shown in the photo pops up, prompting me to unlock the device-when I agree to the unlock it gives out error saying cannot stop/halt CPU,then it fails to continue. It does however seem to recognize the target because running "connect" on jlink-commander does not return any errors. trying "r" on jlink-commander however return the same error-"cannot halt CPU".
    I have looked at similar threads but it seems they have the same problem under different situations.


    Kindly help.
    [img]https://community.st.com/servlet/JiveServlet/showImage/2-146447-14851/pastedImage_4.png[/img]
  • Hi,


    does this issue also occur with the latest version of the J-Link software & documentation pack?

    Is the reset pin connected?

    Best regards,
    Niklas
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi Boi,

    stm32f7 board

    According to the screenshot, you specified "stm32f407" as the device.

    Are you using an evalboard or custom hardware?

    Btw. J-Link Commander should look like as follows:

    I am curious why it shows up as "J-Link Commander" without version number in the screenshot provided:



    Best regards,
    Niklas
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi Niklas,

    Pardon I meant to write stm32f407, that is the evaluation board I have . I was following application note AN00021_CONNECTJLINKTOSTM32.
    I post a link to photo showing the setup and jlink commander screenshot once more

    imagebin.ca/v/3LOzS1hEn0DM
    -------------------------------------------------
    imagebin.ca/v/3LP23ktJLekB
    -------------------------------------------------
    imagebin.ca/v/3LP3mDnyPfRo

    Kind regards,
    Boi
  • Hi Boi,


    the unlock command only supports the devices listed.
    However, as you can see in the image, unlocking of STM32 devices is supported natively (upper marking in the screenshot)


    If you type in "con" multiple times, does it unlock the device multiple times?

    We also provide a tool to reset the option bytes of STM32 devices to factory default.
    It is called "J-Link STM32 Unlock" and the executable is named "JLinkSTM32.exe"


    Best regards,
    Niklas
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi Niklas,

    "con" returns with no error. But say I try to connect to the target using the IDEs, it still gives"cannot halt CPU". typing "r" under jlink commander also brings up the same error.
    I will try to use jlinkstm32.exe you mention.
    Results of "con" on the following link

    imagebin.ca/v/3LQK4H9LMEsZ

    Kind regards,
    Boi
  • Hi Boikhutso,


    thanks for the feedback and good to hear that you are up and running again!


    Best regards,
    Niklas
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.