cancel
Showing results for 
Search instead for 
Did you mean: 

HRTIM TIMF Delayed Protection enabled despite disabled in config with LL driver on STM32G474

grmart
Associate

I encountered a bug in the initialization code for HRTIM generated by CubeMX in STM32CubeIDE.

Delayed Protection is enabled for HRTIM Timer F despite the "Delayed Protection Mode"="No Action" in the timer configuration. This does not happen for other HRTIM timers.

This error occurred in my project with STM32G474RBT6 in STM32CubeIDE 1.17 (CubeMX 6.13) but I reproduced this bug on a clean installation of STM32CubeIDE 1.19.0 (CubeMX 6.15.0).

All you need to do is set the LL driver for HRTIM and enable Timer F.
In the MX_HRTIM1_Init function in main.c, there is a function call:
LL_HRTIM_TIM_EnableDLYPRT(HRTIM1, LL_HRTIM_TIMER_F)

I solved it by calling the function LL_HRTIM_TIM_DisableDLYPRT(HRTIM1, LL_HRTIM_TIMER_F) in the following USER CODE block...

2 REPLIES 2
Ghofrane GSOURI
ST Employee

Hello @grmart 

Thanks for your detailed explanation.

Issue has been raised to the development team under internal ticket 157564.  

I will keep you posted with updates

THX

Ghofrane

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.

Hello, here is my simple ioc for reproducing