In real time systems using an RTOS, what how would the RTOS handle an idle period? Would it run nop instructions at the lowest frequency supported by a Dynamic Voltage Scaling capable processor? or would it turn to a sleep state? Can anyone refer me to actual practical implementations. Thanks
- Anybody can ask a question
- Anybody can answer
- The best answers are voted up and rise to the top
I depends entirely on the system requirements. Systems that need to operate at very low power could go to sleep until the next interrupt. Other systems might have plenty of power but need to be very reliable...these could be doing self-tests in the background task.
It would most likely go to for one of the device's sleep mode.
It's very quick (often a matter of a single instruction) and designed to do exactly that: fill inactive periods with inactivity ;) This in turn helps to save power.
However, if power is not a concern to you, you may simply "halt" in a polling loop until a continue condition occurs.
Clocking the system down seems like a "half-way solution" - doesn't make much sense to me.
You asked about a practical implementation. Here are the QNX power management definitions. It's highly customizable.