From: Nuno Santos <nsantos@displax.com>
To: linux-input@vger.kernel.org
Subject: Mixed HID descriptors
Date: Thu, 20 Feb 2014 11:12:39 +0000 [thread overview]
Message-ID: <5305E327.2020504@displax.com> (raw)
Hi,
We are developing an HID multitouch device and we want to make it fully
compatible with Linux and Windows.
The device descriptor describes a mouse, keyboard and multitouch
digitizer as well as a set of features. When we have mouse or keyboard
descriptor along the touch device I can no longer get or set features.
It gives me a timeout error:
ioctl (GFEATURE): Connection timed out
This only happens in Linux.
I would like to know if this is normal, or if there is anyway of getting
more information about the parsing itself in order to understand the
problem.
Below is the device report descriptor
__ALIGN_BEGIN
static uint8_t HID_ReportDesc[]
__ALIGN_END =
{
#if 0 // IS MESSING HID ON LINUX
0x05, 0x01, // Usage Page (Generic Desktop)
0x09, 0x06, // Usage (Keyboard)
0xA1, 0x01, // Collection (Application)
0x85, REPORTID_KEYBOARD, // REPORT_ID (Mouse)
0x05, 0x07, // Usage page (Key Codes)
0x19, 0xE0, // Usage minimum (224)
0x29, 0xE7, // Usage maximum (231)
0x15, 0x00, // Logical minimum (0)
0x25, 0x01, // Logical maximum (1)
0x75, 0x01, // Report size (1)
0x95, 0x08, // Report count (8)
0x81, 0x02, // Input (data, variable,
absolute)
0x95, 0x01, // Report count (1)
0x75, 0x08, // Report size (8)
0x81, 0x01, // Input (constant)
0x95, 0x06, // Report count (6)
0x75, 0x08, // Report size (8)
0x15, 0x00, // Logical minimum (0)
0x25, 0x65, // Logical maximum (101)
0x05, 0x07, // Usage page (key codes)
0x19, 0x00, // Usage minimum (0)
0x29, 0x65, // Usage maximum (101)
0x81, 0x00, // Input (data, array)
0xC0,
#endif
#if 0 // IS MESSING HID ON LINUX
0x05, 0x01, // USAGE_PAGE (Generic Desktop)
0x09, 0x01, // USAGE (Pointer)
0xa1, 0x01, // COLLECTION (Application)
0x85, REPORTID_MOUSE, // REPORT_ID (Mouse)
0x09, 0x01, // USAGE (Pointer)
0xa1, 0x00, // COLLECTION (Physical)
0x05, 0x09, // USAGE_PAGE (Buttons)
0x09, 0x01, // USAGE (Button 1)
0x95, 0x01, // REPORT_COUNT (1)
0x75, 0x01, // REPORT_SIZE (1)
0x15, 0x00, // LOGICAL_MINIMUM (0)
0x25, 0x01, // LOGICAL_MAXIMUM (1)
0x81, 0x02, // INPUT (Data,Var,Abs)
0x95, 0x07, // REPORT_COUNT (7)
0x75, 0x01, // REPORT_SIZE (1)
0x81, 0x03, // INPUT (Const,Var,Abs)
0x95, 0x08, // REPORT_COUNT (8)
0x75, 0x01, // REPORT_SIZE (1)
0x81, 0x03, // INPUT (Const,Var,Abs)
0x05, 0x01, // USAGE_PAGE (Generic Desktop)
0x09, 0x30, // USAGE (X)
0x09, 0x31, // USAGE (Y)
0x15, 0x00, // LOGICAL_MINIMUM (0)
0x26, 0xff, 0x7f, // LOGICAL_MAXIMUM (32767)
0x35, 0x00, // PHYSICAL_MINIMUM (0)
0x46, 0x00, 0x00, // PHYSICAL_MAXIMUM (0)
0x95, 0x02, // REPORT_COUNT (2)
0x75, 0x10, // REPORT_SIZE (16)
0x81, 0x02, // INPUT (Data,Var,Abs)
0xc0, // END_COLLECTION
0xa1, 0x02, // COLLECTION (Logical)
0x15, 0x00, // LOGICAL_MINIMUM (0)
0x26, 0xff, 0x00, // LOGICAL_MAXIMUM (255)
0x09, 0x01, // USAGE (Pointer)
0x95, 0x39, // REPORT_COUNT (57)
0x75, 0x08, // REPORT_SIZE (8)
0x81, 0x01, // INPUT (Data,Var,Abs)
0xc0, // END_COLLECTION
0xc0, // END_COLLECTION
#endif
#if 1
0x05, 0x0d, // USAGE_PAGE (Digitizers)
0x09, 0x0E, // USAGE (Configuration)
0xa1, 0x01, // COLLECTION (Application)
0x85, REPORTID_MODE, // REPORT_ID (Feature)
0x09, 0x23, // USAGE (Device Settings)
0xa1, 0x02, // COLLECTION (logical)
0x09, 0x52, // USAGE (Device Mode)
0x09, 0x53, // USAGE (Device Index)
0x15, 0x00, // LOGICAL_MINIMUM (0)
0x25, 0x28, // LOGICAL_MAXIMUM (40)
0x75, 0x08, // REPORT_SIZE (8)
0x95, 0x02, // REPORT_COUNT (2)
0xb1, 0x02, // FEATURE (Data,Var,Abs)
0xc0, // END_COLLECTION
0xc0, // END_COLLECTION
0x09, 0x04, // USAGE (Touch Screen)
0xa1, 0x01, // COLLECTION (Application)
0x85, REPORTID_TOUCH, // REPORT_ID (Touch)
0x09, 0x22, // USAGE (Finger)
0x05, 0x0d, /* USAGE_PAGE
(Digitizers) */
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) */
0x09, 0x32, /* USAGE (In
Range) */
0x81, 0x02, /* INPUT
(Data,Var,Abs) */
0x09, 0x47, /* USAGE
(Confidence) */
0x81, 0x02, /* INPUT
(Data,Var,Abs) */
0x95, 0x05, /* REPORT_COUNT
(5) */
0x81, 0x03, /* INPUT
(Cnst,Ary,Abs) */
0x09, 0x51, /* USAGE (Contact
Identifier) */
0x75, 0x08, /* REPORT_SIZE
(8) */
0x95, 0x01, /* REPORT_COUNT
(1) */
0x81, 0x02, /* INPUT
(Data,Var,Abs) */
0xa1, 0x00, /* COLLECTION
(Physical) */
0x05, 0x01, /* USAGE_PAGE (Generic
Desktop) */
0x15, 0x00, /* LOGICAL_MINIMUM
(0) */
0x26, 0x3A, 0x20, /* LOGICAL_MAXIMUM
(8200) */
0x75, 0x10, /* REPORT_SIZE
(16) */
0x09, 0x30, /* USAGE
(X) */
0x81, 0x02, /* INPUT
(Data,Var,Abs) */
0x15, 0x00, /* LOGICAL_MINIMUM
(0) */
0x26, 0x5C, 0x12, /* LOGICAL_MAXIMUM
(4700) */
0x09, 0x31, /* USAGE
(Y) */
0x81, 0x02, /* INPUT
(Data,Var,Abs) */
0x05, 0x0d, /* USAGE_PAGE
(Digitizers) */
0x09, 0x30, /* USAGE
(X) */
0x75, 0x10, /* REPORT_SIZE
(16) */
0x95, 0x01, /* REPORT_COUNT
(1) */
0x81, 0x02, /* INPUT
(Data,Var,Abs) */
0xc0, /*
END_COLLECTION */
0xc0, /*
END_COLLECTION */
0x05, 0x0d, // USAGE_PAGE (Digitizers)
0x09, 0x54, // USAGE (Actual count)
0x15, 0x00, // LOGICAL_MAXIMUM (0)
0x25, 0x14, // LOGICAL_MAXIMUM (20)
0x95, 0x01, // REPORT_COUNT (1)
0x75, 0x08, // REPORT_SIZE (8)
0x81, 0x02, // INPUT (Data,Var,Abs)
0x85, REPORTID_MAX_COUNT, // REPORT_ID (Feature)
0x09, 0x55, // USAGE(Maximum Count)
0x15, 0x00, // LOGICAL_MINIMUM (0)
0x25, 0x14, // LOGICAL_MAXIMUM (20)
0x95, 0x01, // REPORT_COUNT (1)
0x75, 0x08, // REPORT_SIZE (8)
0xb1, 0x02, // FEATURE (Data,Var,Abs)
0xc0, // END_COLLECTION
#endif
#if 1
0x09, 0x00, // USAGE (Undefined)
0xa1, 0x01, // COLLECTION (Application)
0x85, REPORTID_ENABLE, // REPORT_ID (Feature)
0x09, 0x00, // USAGE(Undefined)
0x95, 0x01, // REPORT_COUNT (1)
0x75, 0x08, // REPORT_SIZE (8)
0xb1, 0x02, // FEATURE (Data,Var,Abs)
0x85, REPORTID_GAIN, // REPORT_ID (Feature)
0x09, 0x00, // USAGE(Undefined)
0x15, 0x00, // LOGICAL_MINIMUM (0)
0x25, 0x07, // LOGICAL_MAXIMUM (7)
0x95, 0x01, // REPORT_COUNT (1)
0x75, 0x08, // REPORT_SIZE (8)
0xb1, 0x02, // FEATURE (Data,Var,Abs)
0xc0, // END_COLLECTION
#endif
};
With my best regards,
Nuno Santos
www.displax.com
next reply other threads:[~2014-02-20 11:12 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-20 11:12 Nuno Santos [this message]
2014-02-22 17:04 ` Mixed HID descriptors David Herrmann
2014-02-25 14:10 ` Benjamin Tissoires
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5305E327.2020504@displax.com \
--to=nsantos@displax.com \
--cc=linux-input@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).