IAMExtDevice::get_DevicePower method (strmif.h)

The get_DevicePower method retrieves the external device's power mode.

Syntax

HRESULT get_DevicePower(
  [out] long *pPowerMode
);

Parameters

[out] pPowerMode

Pointer to a long integer that receives one of the following values, indicating the device's power mode.

Value Description
ED_POWER_OFF Power is off.
ED_POWER_ON Power if on.
ED_POWER_STANDBY Device is in standby mode.

Return value

When this method succeeds, it returns S_OK. Otherwise it returns an HRESULT error code.

Remarks

In Windows XP Service Pack 2 and later, the following additional power mode is defined.

Value Description
ED_POWER_DEVICE_DEPENDENT Power is on with limited functions.
 

To use this constant, include the header file Xprtdefs.h.

DV and MPEG Camcorder Implementation

The MSDV and UVC drivers return ED_POWER_ON when the camcorder is on. If the camcorder is off or in standby mode, the DV driver is not loaded, so this method is not available. If the camcorder is removed unexpectedly, the method can return ERROR_GEN_FAILURE.

MSTape supports both ED_POWER_OFF and ED_POWER_ON, but not ED_POWER_STANDBY.

Requirements

   
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header strmif.h (include Dshow.h)
Library Strmiids.lib

See also

Error and Success Codes

IAMExtDevice Interface

IAMExtDevice::put_DevicePower