USB Type-C Port Controller Interface driver programming reference

This section provides programming reference information about writing Windows drivers for USB Type-C port controllers.

In this architecture, the USB Type-C Port Controller Interface framework extension is a Microsoft-provided driver UcmTcpciCx.sys. This is an in-box driver included in Windows 10, version 1703.

The client driver is written by an IHV/OEM. This section refers to that driver as the port controller client driver.

This section describes the driver support methods that are implemented by the UcmTcpciCx library. Your client driver calls these methods to communicate with the class extension:

Method Description

UCMTCPCI_PORT_CONTROLLER_ALERT_DATA_INIT method

Initializes the UCMTCPCI_PORT_CONTROLLER_ALERT_DATA structure.

UCMTCPCI_PORT_CONTROLLER_CONFIG_INIT method

Initializes the UCMTCPCI_PORT_CONTROLLER_CONFIG structure.

UCMTCPCI_PORT_CONTROLLER_IDENTIFICATION_INIT method

Initializes the UCMTCPCI_PORT_CONTROLLER_IDENTIFICATION structure.

UCMTCPCI_DEVICE_CONFIG_INIT method

Initializes the UCMTCPCI_DEVICE_CONFIG structure.

UCMTCPCI_PORT_CONTROLLER_CAPABILITIES_INIT method

Initializes the UCMTCPCI_PORT_CONTROLLER_CAPABILITIES structure.

UcmTcpciDeviceInitialize method

Initializes the USB Type-C Port Controller Interface framework extension (UcmTcpciCx).

UcmTcpciDeviceInitInitialize method

Initializes device initialization operations when the Plug and Play (PnP) manager reports the existence of a device.

UcmTcpciPortControllerAlert method

Sends information about the hardware alerts that are received on the port controller to UcmTcpciCx.

UcmTcpciPortControllerCreate method

Creates a port controller object to register with UcmTcpciCx.

UcmTcpciPortControllerSetHardwareRequestQueue method

Assigns a framework queue object to which the UcmTcpciCx dispatches hardware requests for the port controller.

UcmTcpciPortControllerStart method

Indicates to the UcmTcpciCx class extension that the client driver is now ready to service hardware requests for the port controller.

UcmTcpciPortControllerStop method

Indicates to the UcmTcpciCx class extension to stop sending hardware requests to the port controller object.

This section describes the IOCTLs that are sent by UcmTcpciCx and handled by your client driver for the port controller device. The client driver gets or sets values of the registers defined as per the Universal Serial Bus Type-C Port Controller Interface Specification. See UcmTcpciSpec.h.

Control Code Description

IOCTL_UCMTCPCI_PORT_CONTROLLER_GET_STATUS

Gets values of all status registers as per the Universal Serial Bus Type-C Port Controller Interface Specification. The client driver must retrieve the values of the CC_STATUS, POWER_STATUS, and FAULT_STATUS registers.

IOCTL_UCMTCPCI_PORT_CONTROLLER_GET_CONTROL

Gets the values of all control registers defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_SET_CONTROL

Sets the value of a control register defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_SET_TRANSMIT

Sets the TRANSMIT Register defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_SET_TRANSMIT_BUFFER

Sets the TRANSMIT_BUFER Register defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_SET_RECEIVE_DETECT

Sets the RECEIVE_DETECT Register defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_SET_CONFIG_STANDARD_OUTPUT

Sets the CONFIG_STANDARD_OUTPUT Register defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_SET_COMMAND

Sets the value of a command register defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_SET_MESSAGE_HEADER_INFO

Sets the value of the MESSAGE_HEADER_INFO Register defined as per the Universal Serial Bus Type-C Port Controller Interface Specification.

IOCTL_UCMTCPCI_PORT_CONTROLLER_ALTERNATE_MODE_ENTERED

Notifies the client driver that an alternate mode is entered so that the driver can perform additional tasks.

IOCTL_UCMTCPCI_PORT_CONTROLLER_ALTERNATE_MODE_EXITED

Notifies the client driver that an alternate mode is exited so that the driver can perform additional tasks.

IOCTL_UCMTCPCI_PORT_CONTROLLER_DISPLAYPORT_CONFIGURED

Notifies the client driver that the DisplayPort alternate mode on the partner device has been configured with pin assignment so that the driver can perform additional tasks.

IOCTL_UCMTCPCI_PORT_CONTROLLER_DISPLAYPORT_DISPLAY_OUT_STATUS_CHANGED

Notifies the client driver that the display out status of the DisplayPort connection has changed so that the driver can perform additional tasks.

IOCTL_UCMTCPCI_PORT_CONTROLLER_DISPLAYPORT_HPD_STATUS_CHANGED

Notifies the client driver that the hot-plug detect status of the DisplayPort connection has changed so that the driver can perform additional tasks.

Send comments about this topic to Microsoft