Skip to main content
Associate II
June 16, 2025
Solved

CubeIDE 1.18.1 generates wrong code for TIM15

  • June 16, 2025
  • 2 replies
  • 330 views

We're using STM32CubeIDE 1.18.1 under Windows.  When generating LL_ code for a STM32C092, TIM15 init generates this code:

static void MX_TIM15_Init(void)
{
 LL_TIM_InitTypeDef TIM_InitStruct = {0};

 /* Peripheral clock enable */

 LL_APB2_GRP1_EnableClock(LL_APB2_GRP1_PERIPH_TIM15);

 

In stm32c0xx_ll_bus.h, the enable clock function redefines the call:

#define LL_APB2_GRP1_EnableClock LL_APB1_GRP2_EnableClock but

LL_APB2_GRP1_PERIPH_TIM15

is undefined. It would seem the generated code should be LL_APB1_GRP2_PERIPH_TIM15

for RCC_APBENR2_TIM15EN.

 

Regards,

Mike


Edited to apply source code formatting - please see How to insert source code for future reference.

Best answer by Ghofrane GSOURI

Hello @MikeInMinnesota 

Your contribution is much appreciated.

Issue has been raised to our development team for correction.

Internal ticket number :212341 

I will keep you posted with updates.

THX

Ghofrane

 

2 replies

Ghofrane GSOURI
Technical Moderator
June 16, 2025

Hello @MikeInMinnesota 

First let me thank you for posting.

I'm currently investigating this . I will get back to you asap.

Could you please share your  IOC .

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.
Associate II
June 16, 2025

Sure, Ghofrane - Thanks for your help.

Regards,

Mike

Ghofrane GSOURI
Ghofrane GSOURIBest answer
Technical Moderator
June 16, 2025

Hello @MikeInMinnesota 

Your contribution is much appreciated.

Issue has been raised to our development team for correction.

Internal ticket number :212341 

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.