cancel
Showing results for 
Search instead for 
Did you mean: 

STM32G051G6U6 IWDG not refreshing

ManishNair
Associate III

Hi,

I am facing an issue with IWDG in  STM32G051G6U6.

HAL_IWDG_Refresh(&hiwdg);  not refreshing IWDG and  the core resets after IWDG overflow time.

IWDG overflow is set at 13Sec (varying wrt prescaler) and I am refreshing it at every 1 sec.

Counter prescaler 128,  window value 4095, down counter 4095, Core Frq 40Mhz

Only few test program lines are loaded to toggle an led @ 1 Hz with the help of two HAL_Delay (500);  gpio toggle followed by HAL_IWDG_Refresh(&hiwdg); 

Another problem noticed was, TIM17( APB bus frq 40Mhz) was not running or ISR (NVIC enabled) is not serving when I deactivate IWDG.

I think i missed something else as the same board worked perfectly with all peripherals. Only change I made was Cube IDE update.

2 REPLIES 2
Sarra.S
ST Employee

Hello @ManishNair

Make sure there are no blocking functions or delays that prevent the refresh call from executing in time 

Also, can you confirm that the same setup using IWDG config worked before? which CubeIDE version are you using? 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Cube IDE 1.14.1

The same setup worked before!

Also my variables are not displayed in build analyzer. RAM size is not updating wrt buffer length...

I doubt some error in CUBE IDE... Can you suggest a stable version of cubeIDE. I faced several issues with ver.1.15.1 ( STM32F070  usb not working)