IOCTL_SERIAL_GET_MODEM_CONTROL control code

The IOCTL_SERIAL_GET_MODEM_CONTROL request returns the value of the modem control register in the serial controller.

To set the modem control register, a client can use an IOCTL_SERIAL_SET_MODEM_CONTROL request.

Input Parameters

The Parameters.DeviceIoControl.OutputBufferLength member is set to the size, in bytes, of a ULONG.

Output Parameters

The AssociatedIrp.SystemBuffer member points to a client-allocated ULONG buffer that the serial controller driver uses to output the value of the modem control register.

I/O Status Block

If the request is successful, the Information member is set to the size, in bytes, of a ULONG. Otherwise, the Information member is set to zero.

The Status member is set to one of the Generic Status Values for Serial Device Control Requests.

Remarks

The IOCTL_SERIAL_GET_MODEM_CONTROL and IOCTL_SERIAL_SET_MODEM_CONTROL requests are used primarily for hardware testing. No standard register layout is defined for the modem control operations. Peripheral drivers that use these IOCTLs risk making themselves dependent on the hardware features of a particular serial controller.

For an example layout of a modem control register, see the definition of the MCR bits (SERIAL_MCR_DTR through SERIAL_MCR_LOOP) in the Serial.h header file in the Serial driver sample on GitHub.

Requirements

Header

Ntddser.h (include Ntddser.h)

See also

IOCTL_SERIAL_SET_MODEM_CONTROL

 

 

Send comments about this topic to Microsoft

Show: