Power Management Architecture (Compact 7)

3/12/2014

Power Manager, included with Windows Embedded Compact 7, provides sophisticated power management support for your hardware platform. You can use Power Manager to extend battery life and improve the overall power efficiency of your system. Because Power Manager acts as a mediator between device drivers, applications, and the kernel/OEM Adaptation Layer (OAL), you can configure Power Manager to intelligently manage hardware in a way that cooperates with the needs of applications that use devices on your platform. For example, you may have an application that needs to continually update a display device while the remaining platform hardware is running in a lower power-saving mode, or your platform may allow a network device to stay powered on while the rest of platform is powered off.

Note

The term device in this context means a peripheral on a Windows Embedded Compact-based system, like a display screen or a network adapter. The term platform refers to the entire Windows Embedded Compact system: CPU, memory, and all peripherals.

The following figure illustrates the architecture of power management in Windows Embedded Compact 7.

Power Management Architecture

As shown in this figure, Power Manager communicates with applications through an application interface and a notification message queue. Applications use the application interface to request system power state transitions. For example, an application can issue a request to transition the system to a suspended state on behalf of user input. For more about the application interface, see Power Management Application Interface. Power Manager uses the notification message queue to notify applications about power-related events. For example, Power Manager informs interested applications when the OS resumes from a suspended state. For more about the notification message queue, see Power Management Notification Interface.

When Power Manager communicates with device drivers, it does so through a device driver interface and by issuing I/O control (IOCTL) commands to device drivers. Power Manager uses the DeviceIoControl function to issue IOCTLs directly to device drivers. For example, Power Manager uses IOCTLs to determine device capabilities and to update a device's power state. Because IOCTLs run in a thread context, driver developers have much more flexibility in how they implement power state change functionality. Using IOCTLs to manage power also facilitates the separation of device power state from overall system power state. Thus, some devices can be turned off while the OS is running, and others can be left on while most of the OS is suspended. Device drivers communicate with Power Manager by making calls through the device driver interface. For example, device drivers call the Power Manager DevicePowerNotify function to request device power state changes. For more about the device driver interface, see Power Management Device Driver Interface.

Power Manager observes the following rules when mediating between devices, applications, and the OS:

  • System power states impose maximum power consumption limits on all devices.
  • Applications impose minimum power limits on specific devices to obtain minimum performance levels.
  • Power Manager permits devices to intelligently manage their own power as long as their power levels are between the minimum and maximum limits.
  • If an application requests a minimum power consumption limit that is higher than the maximum power limit of the current system power state, the power level of the device that the application uses remains elevated for as long as the application requires use of the device.
  • If the OS transitions to a suspended state, Power Manager ignores application-imposed minimum power limits while the OS is in the suspended state.

In This Section

See Also

Concepts

Architecture