Skip to main content
Philipp Legrum
Visitor II
June 27, 2018
Question

Why does STM32Cube recommend to not use SysTick

  • June 27, 2018
  • 1 reply
  • 1273 views
Posted on June 27, 2018 at 22:08

as TimeBase Source?

Today, I've been trying to activate FreeRTOS' USE_TICKLESS_IDLE feature.

It turns out that the tickless idle --in fact it is a unnecessary tick suppression-- works only when Timebase Source is SysTick because it is hard-coded so in the FreeRTOS port. (I'm using the latest CubeMX and firmware package.)

While this is perfectly fine for me, I'm curious why CubeMX keeps recommending not tu use SysTick as Time Base.

Thanks, Phil

#tickless-idle #systick #stm32l476rg
This topic has been closed for replies.

1 reply

Ben K
Senior III
June 28, 2018
Posted on June 28, 2018 at 09:18

The HAL has its own timebase which it uses for timeout detection. This was originally based on the SysTick interrupt, but in order to be able to operate alongside the FreeRTOS, it has to use a TIM timer instead.