Setting and Clearing the Communication Mode on a Parallel Port

A client sets the communication mode on a parallel port by using the following internal device control requests:

IOCTL_INTERNAL_PARALLEL_SET_CHIP_MODE

IOCTL_INTERNAL_PARALLEL_CLEAR_CHIP_MODE

A kernel-mode driver can also use the system-supplied parallel device callback routines obtained with an IOCTL_INTERNAL_GET_PARALLEL_PNP_INFO request. This request returns a PARALLEL_PNP_INFORMATION structure that includes the following pointers to system-supplied callbacks:

  • The TrySetChipMode member is a pointer to a PPARALLEL_SET_CHIP_MODE callback, which sets the operating mode of a parallel port.

  • The ClearChipMode member is a pointer to a PPARALLEL_CLEAR_CHIP_MODE callback, which clears the operating mode of a parallel port by resetting the communication mode of the host chipset to IEEE 1284-compatibility mode.

A client must first allocate a parallel port before it can set or clear the communication mode.

A client must first clear the communication mode before it can set a new communication mode. Clearing the communication mode returns the host chipset to IEEE 1284-compatibility mode.

To determine the current mode, a client can use the IOCTL_INTERNAL_GET_PARALLEL_PNP_INFO request, which returns a PARALLEL_PNP_INFORMATION structure that contains information about the current communication mode.

 

 

Send comments about this topic to Microsoft