none
win10 mult-touch hid设备,无法被正确被识别。 RRS feed

  • 问题

  • 10点触摸屏,report id 配置如下:

       

    static struct hidg_func_descriptor touch_screen = {
    .subclass           = 0,
    .protocol           = 8,
    .report_length      = (64),
    .report_desc_length = (69+63*9+40),
    .report_desc = {
    0x05, 0x0D,    //   Usage Page (Digitizer)
    0x09, 0x04,    //   Usage (Touch Screen)
    0xA1, 0x01,    //   Collection (Application)
    0x85, 0x01,    //   Report ID (1)
    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,NWrp,Lin,Pref,NNul,Bit)
    0x95, 0x01, //  Report Count (1)
    0x81, 0x03, //  Input (Cnst,Var,Abs,NWrp,Lin,Pref,NNul,Bit)
    0x09, 0x51, //  Usage (Contact Identifier)
    0x25, 0x3F, //  Logical Maximum (63)
    0x75, 0x06, //  Report Size (6)
    0x95, 0x01, //  Report Count (1)
    0x81, 0x02, //  Input (Data,Var,Abs,NWrp,Lin,Pref,NNul,Bit)
    0x05, 0x01,    //   Usage Page (Generic Desktop)
    0x75, 0x10,    //   Report Size (16)
    0x55, 0x0E,    //   Unit Exponent (-2)
    0x65, 0x11,    //   Unit (SI Lin: Length (cm)
    0x09, 0x30,    //   Usage (X)
    0x26, 0x00, 0x40,    //   Logical Maximum (16384)
    0x35, 0x00,    //   Physical Minimum (0)
    0x46, 0x48, 0x1B,    //   Physical Maximum (6984)
    0x81, 0x42,    //   Input (Data,Var,Abs,NWrp,Lin,Pref,Null,Bit)
    0x09, 0x31,    //   Usage (Y)
    0x26, 0x80, 0x25,    //   Logical Maximum (9600)
    0x46, 0x58, 0x0F,    //   Physical Maximum (3928)
    0x81, 0x42,    //   Input (Data,Var,Abs,NWrp,Lin,Pref,Null,Bit)
    0xC0,    //   End Collection

    0x05, 0x0D,     //  Usage Page (Digitizer)
    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,NWrp,Lin,Pref,NNul,Bit)
    0x95, 0x01, //  Report Count (1)
    0x81, 0x03, //  Input (Cnst,Var,Abs,NWrp,Lin,Pref,NNul,Bit)
    0x09, 0x51, //  Usage (Contact Identifier)
    0x25, 0x3F, //  Logical Maximum (63)
    0x75, 0x06, //  Report Size (6)
    0x95, 0x01, //  Report Count (1)
    0x81, 0x02, //  Input (Data,Var,Abs,NWrp,Lin,Pref,NNul,Bit)
    0x05, 0x01,    //   Usage Page (Generic Desktop)
    0x75, 0x10,    //   Report Size (16)
    0x55, 0x0E,    //   Unit Exponent (-2)
    0x65, 0x11,    //   Unit (SI Lin: Length (cm)
    0x09, 0x30,    //   Usage (X)
    0x26, 0x00, 0x40,    //   Logical Maximum (16384)
    0x35, 0x00,    //   Physical Minimum (0)
    0x46, 0x48, 0x1B,    //   Physical Maximum (6984)
    0x81, 0x42,    //   Input (Data,Var,Abs,NWrp,Lin,Pref,Null,Bit)
    0x09, 0x31,    //   Usage (Y)
    0x26, 0x80, 0x25,    //   Logical Maximum (9600)
    0x46, 0x58, 0x0F,    //   Physical Maximum (3928)
    0x81, 0x42,    //   Input (Data,Var,Abs,NWrp,Lin,Pref,Null,Bit)
    0xC0,    //   End Collection

    ... (其他8个finger)

    0x05, 0x0D,                    //  Usage Page (Digitizer)
    0x09, 0x56,                    //  Usage (Scan Time)
    0x55, 0x00,                    //  Unit Exponent (0)
    0x65, 0x00,                    //  Unit (None)
    0x27, 0xFF, 0xFF, 0x00, 0x00,  //  Logical Maximum (65535)
    0x95, 0x01,                    //  Report Count (1)
    0x75, 0x10,                    //  Report Size (16)
    0x81, 0x02,                    //  Input (Data,Var,Abs,NWrp,Lin,Pref,NNul,Bit)
    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,NWrp,Lin,Pref,NNul,Bit)
    0x85, 0x02,    //  Report ID(2)
    0x09, 0x55,    //  Usage (Contact Count Maximum)
    0x95, 0x01,     //  Report Count (1)
    0x25, 0x0A,    //  LOGIC MAX(10)
    0xB1, 0x02,     //  Feature (Data,Var,Abs,NWrp,Lin,Pref,NNul,NVol,Bit)
    0xC0,                        //  End Collection
    }
    };

    如果上面黑色粗斜体的描述字段不加上,则能被win10识别,但是只有一个finger工作,不能10点触摸。

    如果加上上述字段,则win10无法识别设备。



    • 已编辑 rayveil 2019年8月13日 3:07
    2019年8月12日 10:22

全部回复