-
Notifications
You must be signed in to change notification settings - Fork 177
Documentation update on tickless mode porting guide #1337
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
3a9ec86
5ed260a
127cd3a
9d09e3c
363298c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,37 @@ | ||||||
| Tickless mode is an optimization mechanism available in RTOS for suspending the SysTick. You can use it in situations when RTOS is idle for multiple ticks, so you can achieve power savings by entering uninterrupted sleep. | ||||||
|
|
||||||
| # Reminder on scheduling & sleep modes in Mbed OS | ||||||
|
|
||||||
| Mbed OS uses the SysTick timer at period of 1ms to process threads' scheduling. | ||||||
| For instance, a system running two threads would see its timing diagram look like : | ||||||
rajkan01 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||||||
|
|
||||||
|  | ||||||
rajkan01 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||||||
|
|
||||||
| Note how the device never enters deepsleep and wastes cycles in Systick while all thread are asleep. | ||||||
rajkan01 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||||||
|
|
||||||
| # Tickless mode | ||||||
|
|
||||||
| To support tickless mode in Mbed OS, your target needs to meet two requirements: | ||||||
|
|
||||||
| - Support for Sleep HAL API | ||||||
| - Support for either Low Power or Microsecond Ticker HAL API | ||||||
|
|
||||||
| To enable tickless mode support in Mbed OS, you need to add the `MBED_TICKLESS` macro in the macros option of the target's section in the `targets.json` file. | ||||||
|
||||||
|
|
||||||
| When the tickless mode is enabled, the device default SysTick mechanism overrides by the [OsTimer](../mbed-os-api-doxy/structos__timer__def.html) implementation based on either the [low power ticker](../mbed-os-api-doxy/group__hal__lp__ticker.html) or [microsecond ticker](../mbed-os-api-doxy/group__hal__us__ticker.html). | ||||||
|
||||||
| When the tickless mode is enabled, the device default SysTick mechanism overrides by the [OsTimer](../mbed-os-api-doxy/structos__timer__def.html) implementation based on either the [low power ticker](../mbed-os-api-doxy/group__hal__lp__ticker.html) or [microsecond ticker](../mbed-os-api-doxy/group__hal__us__ticker.html). | |
| When the tickless mode is enabled, the device's default SysTick mechanism overrides the [OsTimer](../mbed-os-api-doxy/structos__timer__def.html) implementation, based on either the [low power ticker](../mbed-os-api-doxy/group__hal__lp__ticker.html) or [microsecond ticker](../mbed-os-api-doxy/group__hal__us__ticker.html). |
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Low-power ticker, low power ticker or LowPowerTicker?
Uh oh!
There was an error while loading. Please reload this page.