Issues with STM32CubeMX v6.13.0 LL Driver Code Generation
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2025-04-01 11:29 PM
Hi,
I'm encountering a couple of issues while using STM32CubeMX version 6.13.0 to generate code for a project involving an STM32G0B1 MCU. The project utilizes one ADC, DMA, and TIM6 as the trigger conversion source. I'm comparing the generated LL driver code with the HAL driver code generation.
My first issue concerns the TIM6 configuration. When setting the Prescaler to 64-1 and the Counter Period to 125-1 in STM32CubeMX, the generated code includes something like "64 - DEFINE...". I had to manually modify the TIM6 configuration in the generated files to set the Prescaler to 63 and the Counter Period to 124 to resolve this.
The second issue relates to a difference in runtime behavior. The same function, which is called after each ADC value conversion, takes approximately 30 microseconds to execute with the HAL driver generated code. However, with the LL driver generated code, the same function takes around 39 microseconds. I'm trying to understand why this function takes longer to execute with the LL driver code, as it's the same function with same code.
Could you please provide some insight into these issues?
Thank you for your time and assistance.
- Labels:
-
STM32CubeMX
-
STM32G0 Series
