// parallel.h
PPARALLEL_CLEAR_CHIP_MODE PparallelClearChipMode;
NTSTATUS PparallelClearChipMode(
[in] PVOID ClearChipContext,
[in] UCHAR ChipMode
)
{...}
View the official Windows Driver Kit DDI referenceNo description available.
The PPARALLEL_CLEAR_CHIP_MODE-typed callback routine clears the operating mode of a parallel port by resetting the communication mode of the host chipset to IEEE 1284-compatibility mode. The system-supplied function driver for parallel ports supplies this routine.
ClearChipContext [in]Pointer to the device extension of a parallel port's functional device object (FDO).
ChipMode [in]Specifies the current operating mode of the parallel port.
For more information about operating modes, see the modes that are defined for the enhanced capabilities register (ECR) in the parallel.h file that is included in the Microsoft Windows Driver Kit (WDK).
| Return code | Description |
|---|---|
| STATUS_SUCCESS | The operating mode was set to IEEE 1284-compatibility mode. |
| STATUS_INVALID_DEVICE_STATE | The specified mode does not match the current mode. |
To obtain a pointer to the system-supplied PPARALLEL_CLEAR_CHIP_MODE callback, a kernel-mode driver uses an IOCTL_INTERNAL_GET_PARALLEL_PNP_INFO request, which returns a PARALLEL_PNP_INFORMATION structure. The ClearChipMode member of the PARALLEL_PNP_INFORMATION structure is a pointer to this callback.
A caller uses the PPARALLEL_CLEAR_CHIP_MODE callback in conjunction with the PPARALLEL_SET_CHIP_MODE callback.
To set a mode, a caller must first clear the current mode.
For more information, see Setting and Clearing the Communication Mode on a ParallelPort.
IOCTL_INTERNAL_PARALLEL_SET_CHIP_MODE
IOCTL_INTERNAL_GET_PARALLEL_PORT_INFO
IOCTL_INTERNAL_PARALLEL_CLEAR_CHIP_MODE