|
|||||||||||
Technical Support On-Line Manuals RL-ARM User's Guide (MDK v4) RL-RTX Overview Product Description Product Specification Technical Data Timing Specifications Advantages Your First RTX Application Theory of Operation Timer Tick Interrupt System Task Manager Task Management Idle Task System Resources Scheduling Options Pre-emptive Scheduling Round-Robin Scheduling Cooperative Multitasking Priority Inversion Stack Management User Timers Interrupt Functions Configuring RL-RTX Configuration Options Tasks Stack Size Stack Checking Run in Privileged Mode Hardware Timer Round-Robin Multitasking User Timers FIFO Queue Buffer Idle Task Error Function Create New RTX_Config.c Configuration Macros Alternate Tick Timer Low Power RTX Library Files Using RL-RTX Writing Programs Include Files Defining Tasks Multiple Instances External References Using a Mailbox SWI Functions SVC Functions Debugging System Info Task Info Event Viewer Usage Hints ARM7/ARM9 Version Cortex-M Version Create New RTX Application Function Reference Event Flag Management Routines Mailbox Management Routines Memory Allocation Routines Mutex Management Routines Semaphore Management Routines System Functions Task Management Routines Time Management Routines User Timer Management Routines RL-FlashFS RL-TCPnet RL-CAN RL-USB Example Programs Library Reference Appendix |
Low Power RTXThe Low Power RTX extension allows using power-saving modes efficiently and building RTX applications for power constrained devices such as battery powered devices. The operation of the OS task scheduler in Low Power mode is different than normal operation. Instead of executing periodic system tick interrupts when all active tasks are suspended, the system enters a power-down mode. It calculates how long it can stay in power-down mode and disables power for peripherals and the CPU. The wake-up timer must remain powered. The time is responsible to wake-up the system after the power-down period expires. The following functions provide a Low Power RTX extension:
ConfigurationThe Low Power RTX is controlled from the idle task. The peripheral wake-up timer must be initialized before the system enters an endless loop. The function os_suspend() calculates the timeout until the first suspended task becomes ready, and returns the timeout to the user. for (;;) { sleep = os_suspend(); The user sets-up a peripheral timer to sleep timeout and starts the timer. The timeout is measured in system ticks. if (sleep) { /* Setup the wake-up timer ... */ When the wake-up timer is set-up and running, the user puts the system in power-down mode. The wake-up timer must run also in power-down mode. All other peripherals and the CPU may power-down to reduce power. /* Power-down the system ... */ SCB->SCR |= SCB_SCR_SLEEPDEEP_Msk; __WFE(); The wake-up timer, when expired, generates the interrupt and wakes-up the system. Hence, it must run also in power-down mode. The system resumes operation and needs to call the function os_resume(). This function restores the RTX and re-enables the OS task scheduler. /* After Wake-up */ sleep = (tc - LPC_WWDT->TV) / 250; } os_resume(sleep); If, for any reason, the system does not wake up immediately after the wake-up interrupt, the actual sleep time is checked and adjusted. RTX_LowPower demo examples configured for low power RTX:
Note
| ||||||||||
|
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.