Skip to main content
Visitor II
December 12, 2018
Question

STM32L4 sometimes hangs after NVIC_SystemReset()

  • December 12, 2018
  • 6 replies
  • 1613 views

About once over 10, the MCU seems to hang after NVIC_SystemReset() call. Notice that:

  • The MCU restarts correctly after poweron reset,
  • NRESET set to 0 then 1 does NOT restart the MCU
  • When MCU is hung, the NRESET Level is correctly UP (thanks to internal pull-up)

    This topic has been closed for replies.

    6 replies

    Graduate II
    December 12, 2018

    Is this a custom board? Is anything else driving NRESET?​

    PGoudAuthor
    Visitor II
    December 12, 2018

    Yes it is a custom board.

    NRESET is only connected through a 1nF capacitance toward 0v.

    But notice that when the MCU is hung, the level at NRESET is 3.2 V

    PGoudAuthor
    Visitor II
    December 12, 2018

    New information.

    I can systematically set my MCU in this "hung" mode after :

    • Init of my board (HAL, Clock etc ...) and GPIOs THEN NVIC_SystemReset()

    BUT this is systematically "hanging" ONLY if

    • my software has just been reprogrammed and automatically restarted
    • my board is attach to the programming STLink (obviously it has just been reprogrammed ;O),

    This with a production (not debug) software that set :

    • JTMS/JTCK/JTDI/JTDO in MODE ANALOG / NO PULL
    • JNRESET in MODE INPUT / PULL UP

    Super User
    December 12, 2018

    STLink connected to NRST?

    JW

    PGoudAuthor
    Visitor II
    December 14, 2018

    Sometimes.

    The problem can occur connected or not connected.

    But for a while I thougt it was easyer to produce when connected and software has just been programmed.

    Visitor II
    November 7, 2024

    I ran into the exact same failure phenomenon, and I'm using an STM32L451CC.Is there a solution yet?