IOCTL_SMARTCARD_POWER IOCTL (winsmcrd.h)

Windows may require a driver to have this IOCTL to be NOP and return success.

The IOCTL_SMARTCARD_POWER control code puts the smart card into one of the following power modes:

Power Mode Setting Description
SCARD_COLD_RESET Sets virtual power that only affects the IOCTL_SMARTCARD_GET_STATE. No impact on the actual reader power states. Returns SCARD_SPECIFIC in IOCTL_SMARTCARD_GET_STATE if the card is present.
SCARD_WARM_RESET Sets virtual power that only affects the IOCTL_SMARTCARD_GET_STATE. No impact on the actual reader power states. Returns SCARD_SPECIFIC in IOCTL_SMARTCARD_GET_STATE if the card is present.

Major code

IRP_MJ_DEVICE_CONTROL

Input buffer

(DWORD) that contains the power state to set.

Output buffer

None.

Status block

Irp->IoStatus.Status is set to STATUS_SUCCESS if the request is successful. Possible error codes are:

Return Code Description
STATUS_NO_MEDIA This code is returned if no smart card is detected.
STATUS_INVALID_PARAMETER This code is returned if the input or output buffer is invalid.
STATUS_DEVICE_POWERED_OFF This code is returned if the proximity radio control is off.

Remarks

Virtual power is set to TRUE for COLD_RESET and WARM_RESET; otherwise, virtual power is set to FALSE.

Requirements

Requirement Value
Header winsmcrd.h

See also

Near field communication (NFC) design guide

Smart card design guide