FreeRTOS systick

Is it possile to configure freertos so that it works with a systick lower than 1msec (i.e. .1 or .5 msec). I’m working on a STM32F429Idiscovery.
Thanks for your answer,

I think you don’t want that :wink:
Systick handling at that rate would cause a serious runtime impact.
Which bigger problem do you want to solve ?

I’m working on an ST32F429I discovery. If I need to schedule a periodic task with a period lower than 1msec, than I need of a systick with a period less than 1msec.

If I need to sample a signal at a frequency of 2 kHz, I can not do it with a task. This is my question

My question is to understand if I can change the systick resolution (in some configuration file). I understand also the overhead that I have to pay in switching time. Anyway, this is useful to understand which kind of applications I canmanage with tasks in freeRTOS.

Thanks for your replay and I hope that you can give me more hints.


PS: in the discovery, the HAL systick timer must be kept at 1 msec, but I don’t konw if the free RTOS systick is based on the HAL_Systick or on the interrupt of a timer.

You DON’T need a systick of 2 kHz to sample a signal at 2 kHz, you just need some timer running at 2 kHz that triggers the action. Also, if you can read the signal in the ISR (or trigger the conversion if it is something like an A/D) then as a benefit, you get much less sampling jitter.

FreeRTOS itself doesn’t really care about the tick rate, as everything in the kernel itself times everything in ticks. Its just the macros that let you convert time in milliseconds to ticks that have problems.

Most of the ST32 parts have plenty of timers, so that normally isn’t a problem.

In that case you could also use a TIMer and do the sampling in it‘s ISR.
That‘s much cheaper than bumping the FreeRTOS systick rate and probably more precise.
I wonder if there is a HAL config setting to configure the FreeRTOS systick, which is usually a TIMer, because HAL uses the ARM SysTick for something else.
However, you can configure configTICK_RATE_HZ as you want only limited by your HW.

Thanks for your reply. I unrdestand your point.