Share via


Power Requirements on Devices (Windows Embedded CE 6.0)

1/6/2010

In some situations, applications may want to influence Power Manager administration of system power states. For example, a pager application might want to keep COM3: at D3 or higher, even in a suspended state, so that an incoming page wakes the system. A streaming audio application might want to keep the network card and audio system at full power, even when the system is on battery power and has been idle for a while. Power Manager provides the SetPowerRequirement function to support applications that have special power management needs.

SetPowerRequirement allows applications to request that Power Manager set a minimum power requirement on device power states. If a power requirement has been set, Power Manager does not allow devices to set their own power state below that specified by the requirement. When Power Manager changes system power states, it normally keeps device requirements in force, even if they maintain the power state of a device at a level higher than allowed by the system power state.

Device power requirements are normally set aside when the OS is in a suspended state. In an OS suspended state, the CPU is stopped, and interrupts are not serviced. If an application is using a device that might be able to operate in a suspended state, it can set the POWER_FORCE flag when it calls SetPowerRequirement. A device driver must disable itself if the OS is suspended.

Power Manager can set aside device power requirements under other circumstances, as well. For example, an OEM may choose to interpret the OS power state POWER_STATE_CRITICAL flag as indicating that the battery level of the OS is critically low and all devices should be turned off.

See Also

Reference

SetPowerRequirement

Concepts

Application Interface