PwrTest Device Scenario

The PwrTest Device Scenario monitors device idle statistics.

This scenario is primarily used for Windows 7 device power activity, subsequent versions of Windows use a different mechanism for tracking device idle that is not currently supported by Pwrtest. For versions of Windows newer than Windows 7, use the Windows Performance Toolkit (WPT). The WPT includes the Windows Performance Recorder (WPR) that you can use to trace the kernel-mode power provider and the Windows Performance Analyzer (WPA) that can show the power framework (PoFx) device statistics and can graph the transitions afterward.

Syntax

pwrtest /device  [/t:n] [/?] 

/t:n
Specifies the total time (in minutes) for the scenario to run (the default value for n is 30 minutes).

Examples

pwrtest /device /t:60
pwrtest /device

XML log file output

<PwrTestLog>
  <SystemInformation>
  </SystemInformation>
  <DeviceIdleEvents> 
    <DeviceIdleChangeEvent>
        <Timestamp></TimeStamp>
        <InstancePath></InstancePath>
        <Description></Description>
    </DeviceIdleChangeEvent>
    <DeviceIdleEvent>
        <Timestamp></TimeStamp>
        <InstancePath></InstancePath>
        <Device></Device>
        <Pdo></Pdo>
        <ConservationTimeout></ConservationTimeout>
        <PerformanceTimeout></PerformanceTimeout>
        <AccruedIdleTime></AccruedIdleTime>
        <BusyCount></BusyCount>
        <AccruedBusyCount></AccruedBusyCount>
        <IdlePowerState></IdlePowerState>
        <CurrentPowerState></CurrentPowerState>
        <Analysis></Analysis>
    </DeviceIdleEvent>
  </DeviceIdleEvents>
</PwrTestLog> 

The following table describes the XML elements that appear in the log file.

Element Description
<DeviceIdleEvents>

Contains all the different device idle events. Only one <DeviceIdleEvents element per PwrTest log file.

<Timestamp>

Time stamp of any given event.

<InstancePath>

Device instance path.

<DeviceIdleChangeEvent>

Device add or remove event.

<Description>

DeviceRemoved or DeviceDetected.

<DeviceIdleEvent>

Device idle statistics event.

<Device>

Functional device object.

<Pdo>

Physical device object

<ConservationTimeout>

Conservative timeout (usually used on DC power).

<PerformanceTimeout>

Performance timeout (usually used on AC power).

<AccruedIdleTime>

The idle time accrued during the period.

<BusyCount>

The number of times the device driver called PoSetDeviceBusy during the period.

<AccruedBusyCount>

The total number of times the device driver called PoSetDeviceBusy.

<IdlePowerState>

Shows which numeric state is the idle state.

<CurrentPowerState>

The current numeric power state.

<Analysis>

String that describes what happened during the period.

PwrTest Syntax