Skip to content

imbushuo/DFRDisplayKm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Touch Bar (DFR) Display Driver for Windows

This driver implements custom display functionality for Apple Touch Bar (DFR) on Windows 10. Touch Bar is a USB composite device with two configurations. The first configuration implements basic function and media key input. Windows always takes the first configuration by default.

With proper configuration in the USB composite device driver stack, it is possible to select the second configuration for achieving advanced display and input functionalities.

This driver implements the display (iBridge Display). The composition device also exposes a HID-compliant Touch Pad (actually, a Touch Screen). It does report Y-axis data but such data are useless due to the form factor of Touch Bar. For more information about the HID digitizer, see DFRContentHost for further details.

Motivation

Keep myself busy during the last few weeks of my internship (thank you LinkedIn & Microsoft)

I should register this project to //oneweek/ next time

Installation

No official signed binary will be built at this moment. To build the driver, a few software needs to be installed including Visual Studio 2019 (with C/C++ workload) and Windows 10 Driver Kit, Version 1903. Install DFRUsbCcgp.inf for the "Apple Touch Bar" device first, then install DFRDisplayKm.inf for the "iBridge Display" device.

You need to turn off Secure Boot as described in the Apple Knowledge Base.

IOCTLs

Two IOCTLs are provided:

  • IOCTL_DFR_UPDATE_FRAMEBUFFER: Update the FrameBuffer.
  • IOCTL_DFR_CLEAR_FRAMEBUFFER: Clear the FrameBuffer.

Check the badly-written user-mode application example DFRDisplayUm.Utility.Console for detailed usage.

Known Caveats

  • Only Apple T2-based MacBook Pro(s) are confirmed supported. T1 support is added but not yet tested.
  • The driver might fails to load on T2 cold boot. Reboot the computer once and it should work.
  • UDCL read acknowledgement is implemented, but I have not yet intensively tested.
  • FrameBuffer update/clear are synchronous calls.

License

Copyright (c) Bingxing Wang. All rights reserved.

Licensed under the MIT License.

About

Windows infrastructure support for Apple DFR (Touch Bar)

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published