Skip to main content
Graduate
April 22, 2025
Solved

reset problem

  • April 22, 2025
  • 2 replies
  • 826 views

hi, im using stm32g474vet6 mcu for power converter. when the supply is turned on initially first time, controller is behaving like hang or stuck somewhere. if i do a pushbutton reset, the mcu starts working fine. after that no issue. whenever im turning off and on the power supply, that time controller is not responding or hanging.

what to do for this. since nrst pin not pulled down or pull up. only boot pin is pulled down with 10kohms. 

i think in debugging mode, controller will alive only, this problem will not come. initially some code issue or init issue or configuration issue if there also, but after the reset mcu starts working finely.

so what happens with the initial supply on time. since i have changed power supplies also. after changing the power supply, if i turn off and on(POR) , during that time also hanging is happening.

whenever main supply turn off and on this probelm is coming one time, after push button reset only mcu starts working fine.

can anyone suggest what to do 

 

 

    This topic has been closed for replies.
    Best answer by KnarfB

    Check your design against "AN5093 Application note Getting started with STM32G4 Series hardware development boards".

    NRST is a bidirectional pin, you may monitor the internal POR and VSS with a scope.

    I assumed the chip is already programmed. Otherwise, the empty flash check will kick in.

    Check MCU settings (like option bits) for accidental system memory boot (see AN2606 Application note STM32 microcontroller system memory boot mode).

    Start with the simplest possible bring-up firmware just switching a LED on or such.

    hth

    KnarfB

    2 replies

    KnarfBAnswer
    Super User
    April 22, 2025

    Check your design against "AN5093 Application note Getting started with STM32G4 Series hardware development boards".

    NRST is a bidirectional pin, you may monitor the internal POR and VSS with a scope.

    I assumed the chip is already programmed. Otherwise, the empty flash check will kick in.

    Check MCU settings (like option bits) for accidental system memory boot (see AN2606 Application note STM32 microcontroller system memory boot mode).

    Start with the simplest possible bring-up firmware just switching a LED on or such.

    hth

    KnarfB

    Graduate II
    April 22, 2025

    So probably is running, and just crashes.

    Have some signs-of-life early in the Reset Handler code, and have it output some info if it ends up in Error_Handler() or HardFault_Handler() rather than die silently in a while(1) loop.

    If you are starting an HSE (External Oscillator) or PLL, make sure that's not timing out or failing with the initial start.

    Super User
    April 22, 2025

    > since nrst pin not pulled down or pull up.

    Do you have a 0.1uF cap on NRST to GND?  There is an internal pull-up.

    Graduate
    April 23, 2025

    yes there is an 0.1uf cap on nrst to gnd