From 3f5cb422b05e4d5bbdcdf8f761829403b6977ecb Mon Sep 17 00:00:00 2001 From: scipio Date: Tue, 7 Jul 2009 19:03:33 +0000 Subject: [PATCH] Edits for comments. --- doc/txt/tep112.txt | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/doc/txt/tep112.txt b/doc/txt/tep112.txt index 8c2cb096..5b2a99f3 100644 --- a/doc/txt/tep112.txt +++ b/doc/txt/tep112.txt @@ -251,6 +251,14 @@ mcu_power_t means that this command can have fan-out calls. Section 5 describes one example use of McuPowerOverride, in the timer stack for the Atmega128 microcontroller family. +As part of power state override, a platform MUST define the enum +TOS_SLEEP_NONE in its hardware.h file. This enum defines the highest +power state of the platform's microcontroller in a chip-independent +way. If a component wires to McuPowerOverride and returns TOS_SLEEP_NONE, +this will cause TinyOS to never put the microcontroller into a power +saving state. This enum allows a component to prevent sleep in a +platform-independent way. + 4. Peripherals and Subsystems ==================================================================== @@ -277,7 +285,7 @@ include power management into shared non-virtualized devices. An implementation of McuSleepC can be found in ``tinyos-2.x/tos/chips/atm128``, ``tinyos-2.x/tos/chips/msp430``, and ``tinyos-2.x/tos/chips/px27ax``. -An example of a use of McuPowerOverride can be found in the atmega128 timer +An example use of McuPowerOverride can be found in the atmega128 timer system. Because some low-power states have much longer wakeup latencies than others, the timer system does not allow long latencies if it has a timer that is going to fire soon. The implementation can be found in @@ -285,6 +293,19 @@ that is going to fire soon. The implementation can be found in ``tinyos-2.x/tos/chips/atm128/timer/HplAtm128Timer0AsyncC.nc`` automatically wires it to McuSleepC if it is included. +For the atmega128 microcontroller, TOS_SLEEP_NONE is the "idle" power +state. + +A second example use of McuPowerOverride is in the msp430 timer system. +By default, the msp430 lowest power state is LPM4, which does not keep +clocks enabled. If ``tinyos-2.x/tos/chips/msp430/timer/Msp430ClockC.nc'' +is included in the component graph, however, this configuration wires +the McuPowerOverride of ``tinyos-2.x/tos/chips/msp430/timer/Msp430ClockP.nc`` +to McuSleepC. This implemementation of McuPowerOverride raises the lowest +power state to LPM3, which keeps clocks enabled. + +For msp430 microcontrollers, TOS_SLEEP_NONE is the "active" power state. + 6. Author's Address ==================================================================== -- 2.39.2