Last Updated: 1/27/2017
When a laptop or a convertible is attached to a USB dock it is essential that the operating system can identify the attached hardware device as “Dock” so that it can deliver the correct user experience. Example: Continuum hinting when a convertible is docked.
To qualify as a dock, it is essential that the hardware device allows projection to external displays along with support for additional peripherals such as mouse, keyboard, storage etc. Thus, a USB hub alone or a port replicator does not quality as a dock.
MS OS Descriptor is only recommended for docks with USB only or USB and Video over standard or proprietary connectors. (E.g. Surface dock, USB Type C dock).
To indicate that a device is dock to the Windows OS the Extended Properties OS Descriptor can be used. The Extended properties descriptor will create a bitmasked registry key, MSOSDockProperties, which indicates different dock properties, these properties are listed in table 1.
|0||IsDock||This value is set to 1 to indicate that the device is the dock|
|1||DockHasIntegratedScreen||This value is set to 1 to indicate that the dock has a built-in screen|
|2||DockHasIntegratedKeyboard||This value is set to 1 to indicate that the dock has a built-in keyboard|
|3||DockHasIntegratedMouse||This value is set to 1 to indicate that the dock has a built-in mouse|
|4-31||Reserved||These values are reserved and should be set to zero|
All docks should have the “IsDock” property set properly, and the additional custom properties as needed. The “DockHasIntegratedScreen/Keyboard/Mouse” property should only be used if such a device is physically built into the dock (not if the dock supports this type of connection.)
This example demonstrates how an Extended Properties OS Descriptor is used to indicate a device is a dock with a built in mouse, keyboard and monitor to the OS. In this example, by using the returned extended properties descriptors, the MSOSDockProperties DWORD is created under the following registry keys:
HKLM\SYSTEM\CurrentControlSet\Enum\USB<DeviceVID&PID> <DeviceInstance>\Device Parameters
DWORD: MSOSDockProperties = 1
This section illustrates the layout of the header section, which includes the length of the entire descriptor, the number of function sections, and the version number.
|0||dwLength||4||DWORD||0x042||The length of this custom property section is 66 bytes.|
|6||wIndex||2||WORD||0x0005||Extended property OS descriptor|
Custom property example
|0||dwSize||4||0x00000038||Length of this custom property section is 56 bytes.|
|4||dwPropertyDataType||42||0x00000004 ||Property value stores a little-endian 32-bit integer.|
|10||wPropertyNameLength||38||WORD||0x00000026||Extended property OS descriptor|