AVR tickless mode
Posted: Mon Nov 05, 2018 11:08 am
Hi,
I study ChibiOS and need some help.
When I tested tickless mode from Arduino Uno demo example, I found that prescaler value is hard-coded to 1024 (hal_st_lld.c) and tick frequency is set to 15625 (obviously F_CLK/1024). So I have a question:
- what is the basic principle on how to calculate prescaler in tickless mode if I want to set a 1000 Hz (1 ms) tick? How do we consider a hardware timer resolution in this matter? Why do we need to set tick frequency to the higher value than in the periodic tick mode?
I study ChibiOS and need some help.
When I tested tickless mode from Arduino Uno demo example, I found that prescaler value is hard-coded to 1024 (hal_st_lld.c) and tick frequency is set to 15625 (obviously F_CLK/1024). So I have a question:
- what is the basic principle on how to calculate prescaler in tickless mode if I want to set a 1000 Hz (1 ms) tick? How do we consider a hardware timer resolution in this matter? Why do we need to set tick frequency to the higher value than in the periodic tick mode?