/
Touch Touch

Touch - PowerPoint Presentation

celsa-spraggs
celsa-spraggs . @celsa-spraggs
Follow
410 views
Uploaded On 2016-05-05

Touch - PPT Presentation

Firmware d evelopment talking HID to Windows Olumuyiwa Durojaiye Senior Software Engineer Microsoft Corporation HW182P Agenda Touch digitizer data delivery Driver stack Human Interface Devices HID specification ID: 306347

usage report 0x09 0x02 report usage 0x02 0x09 count data microsoft maximum 0x00 abs input logical 0x01 windows usb http var hid

Share:

Link:

Embed:

Download Presentation from below link

Download Presentation The PPT/PDF document "Touch" is the property of its rightful owner. Permission is granted to download and print the materials on this web site for personal, non-commercial use only, and to display it on your personal computer provided you do not modify the materials and that you retain all copyright notices contained in the materials. By downloading content from our website, you accept the terms of this agreement.


Presentation Transcript

Slide1

Touch Firmware development: talking HID to Windows

Olumuyiwa DurojaiyeSenior Software EngineerMicrosoft Corporation

HW-182PSlide2

Agenda

Touch digitizer data deliveryDriver stackHuman Interface Devices (HID) specificationUSB and I2CYou’ll leave withUnderstanding of touch HW data delivery to Windows

Where to get more information on this topicSlide3

The good news? No driver development!

Why?

Independent

Hardware Vendors (IHVs )

can focus on firmware development

Reduces production and maintenance costs

How?

Taking advantage of Human Interface Device

(HID

) Specification

Windows drivers for HID over I2C /USBSlide4

Touch input architecture

Win32k.sys

HIDCLASS.sys

HIDCLASS.sys

USB

I2C

USB Device

I2C Device

HIDUSB.sys

HIDI2C.sys

Host

Firmware

Input component

Class Driver

Mini-driver

Bus specific lower drivers

Digitizer FirmwareSlide5

Communicating with the host

New in Win 8No more serial (UART) devices

Stricter

rules

New

certification requirements

Bus

USB

or I2C

HID Rules

USB HID Specification:http://www.usb.org/developers/devclass_docs/HID1_11.pdf

USB HID Usage Table:http://www.usb.org/developers/devclass_docs/Hut1_11.pdf

Protocol Document:http://go.microsoft.com/fwlink/p/?LinkId=226808Slide6

Device and report descriptors

Required Usages

Values: X, Y, Contact id, Contact Count Maximum

Button: Tip

Optional Usages

Values: Pressure, Width Height, Azimuth

Button: In Range

Reporting Modes

Parallel

HybridSlide7

Report descriptor

0x05, 0x0d, // USAGE_PAGE (Digitizers)

0x09, 0x04,

// USAGE (Touch Screen)

0xa1, 0x01,

// COLLECTION (Application)

0x85, 0x01,

// REPORT_ID (Touch)

0x09, 0x22, // USAGE (Finger) 0xa1, 0x02,

// COLLECTION (Logical) 0x09, 0x42, // USAGE (Tip Switch) 0x15, 0x00, // LOGICAL_MINIMUM (0)

0x25, 0x01, // LOGICAL_MAXIMUM (1) 0x75, 0x01, // REPORT_SIZE (1) 0x95, 0x01, // REPORT_COUNT (1)

0x81, 0x02, // INPUT (Data,Var,Abs)

0x95, 0x07, // REPORT_COUNT (7)

0x81, 0x03, // INPUT (Cnst,Ary,Abs) 0x75, 0x08, // REPORT_SIZE (8)

0x09, 0x51, // USAGE (Contact Identifier) 0x95, 0x01, // REPORT_COUNT (1)

0x81, 0x02, // INPUT (Data,Var,Abs)

0x05, 0x01, // USAGE_PAGE (Generic Desk..

0x26, 0xff, 0x0f, // LOGICAL_MAXIMUM (4095)

0x75, 0x10, // REPORT_SIZE (16) 0x55, 0x0e, // UNIT_EXPONENT (-2)

0x65, 0x13, // UNIT(

Inch,EngLinear)

0x09, 0x30, // USAGE (X)

0x35, 0x00, // PHYSICAL_MINIMUM (0)

0x46, 0xb5, 0x04, // PHYSICAL_MAXIMUM (1205)

0x95, 0x02, // REPORT_COUNT (2) 0x81, 0x02, // INPUT (

Data,Var,Abs) 0x46, 0x8a, 0x03, // PHYSICAL_MAXIMUM (906)

0x09, 0x31, // USAGE (Y) 0x81, 0x02, // INPUT (Data,Var,Abs)

Required Usages

Optional UsagesSlide8

Report descriptor

0x05, 0x0d, // USAGE_PAGE (Digitizers)

0x09, 0x48,

// USAGE (Width)

0x09, 0x49,

// USAGE (Height)

0x81, 0x02,

// INPUT (

Data,Var,Abs

) 0x95, 0x01, // REPORT_COUNT (1)

0x55, 0x0C, // UNIT_EXPONENT (-4) 0x65, 0x12, // UNIT (Radians,SIROtation)

0x35, 0x00, // PHYSICAL_MINIMUM (0) 0x47, 0x6f, 0xf5, 0x00, 0x00, // PHYSICAL_MAXIMUM (62831)

0x15, 0x00, // LOGICAL_MINIMUM (0) 0x27, 0x6f, 0xf5, 0x00, 0x00, // LOGICAL_MAXIMUM (62831)

0x09, 0x3f, // USAGE (Azimuth[Orientation])

0x81, 0x02, // INPUT (Data,Var,Abs)

0xc0, // END_COLLECTION 0x05, 0x0d, // USAGE_PAGE (Digitizers)

0x27, 0xff, 0xff, 0xff, 0x0f, // LOGICAL_MAXIMUM (268435455) 0x75, 0x20, // REPORT_SIZE (32)

0x95, 0x01, // REPORT_COUNT (1) 0x09, 0x56, // USAGE (Scan Time) 0x81, 0x02, // INPUT (

Data,Var,Abs)

0x09, 0x54, // USAGE (Contact count)

0x25, 0x7f, // LOGICAL_MAXIMUM (127)

0x95, 0x01, // REPORT_COUNT (1) 0x75, 0x08, // REPORT_SIZE (8)

0x81, 0x02, // INPUT (

Data,Var,Abs)

Slide9

Report descriptor

0x85, REPORTID_MAX_COUNT, // REPORT_ID (Feature)

0x09, 0x55, // USAGE(Contact Count Maximum)

0x09, 0x53, // USAGE (

Device

Identifier)

0x95, 0x02, // REPORT_COUNT (2)

0x25, 0x02, // LOGICAL_MAXIMUM (2)

0xb1, 0x02, // FEATURE (

Data,Var,Abs

) 0x85, 0x44, // REPORT_ID (Feature) 0x06, 0x00, 0xff, // USAGE_PAGE (Vendor Defined)

0x09, 0xC5, // USAGE (Vendor Usage 0xC5) 0x15, 0x00, // LOGICAL_MINIMUM (0)

0x26, 0xff, 0x00, // LOGICAL_MAXIMUM (0xff) 0x75, 0x08, // REPORT_SIZE (8) 0x96, 0x00, 0x01, // REPORT_COUNT (0x100 (256))

0xb1, 0x02, // FEATURE (

Data,Var,Abs) 0xc0, // END_COLLECTION Slide10

Related sessions

[

HW-181T] Building great touch systems

[APP-185T] Make great Metro style apps that are touch-optimized using HTML5

[APP-186T] Build advanced touch apps in Windows 8 Slide11

Further reading and documentation

Name of further readingHID Specification http://www.usb.org/developers/devclass_docs/HID1_11.pdfHID Usage Table

http

://www.usb.org/developers/devclass_docs/Hut1_11.pdf

Link to MSDN

The HID Class Driver for

Sensors

http

://go.microsoft.com/fwlink/p/?LinkId=226798

Windows Pointer Device Data Delivery Protocol  http://go.microsoft.com/fwlink/p/?LinkId=226808Windows Hardware Dev Centerhttp://go.microsoft.com/fwlink/p/?LinkId=227308Windows Dev

Centerhttp://msdn.microsoft.com/windows/Slide12

Feedback and questions

http://forums.dev.windows.com Session f

eedback

http

://bldw.in/SessionFeedback

t

hank youSlide13

©

2011 Microsoft

Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.

The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation.

MICROSOFT

MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.Slide14