getting my new graphic tablet cooperating with gimp
chuckr at chuckr.org
Thu Feb 14 11:28:35 PST 2008
-----BEGIN PGP SIGNED MESSAGE-----
Markus Brueffer wrote:
>> I appreciate the extra information. In fact, I am having one heck of a
>> time trying to figure out exactly how to parse this. I am reading with the
>> HID1_11 spec on my knee at all times, but I swear, I have never seen such a
>> poorly written document!
> It's not _that_ bad, but it surely lacks several clarifications in some areas
> and some information on specific topics is scattered across the whole
Maybe I'm not used to the style, but reading this reminds me of the first
few times I plowed my way thru the sgml spec, before I finally realized
those guys weren't trying to get anything done, they were trying only to
lay a foundation for a foundation for a way to get things done. Getting
past that was difficult, and I find specific sections of the usbhid spec
just as difficult. There is little or no linkage between the sections that
describe features, and the sections that demonstrate how to use those
features. As one example (which I think I've finally figured out), section
4.2 (Subclass), the subparagraph below that titled ""Subclass Codes" uses
the term (in italics) of bInterfaceSubClass. It describes one usagfe where
it would be zero (0), but doesn't bother to say what the other use would
be, nor give any example of what context you'd want to use this statement.
I've written specs myself, but never one that did such a great job of
obfuscation. I doubt, strongly, that any of you could do as badly (unless
you were going thru perhaps 3 levels of language translation, that would do
it). Anyhow, that's the reason why I am not yet finished in figuring out
the parsing of my own unit's config dump.
> Best thing to get started is IMHO to get an idea about what reports are and to
> get the raw report descriptor of a simple device (e.g. a mouse if it's not
> from a keyboard/mouse combo) and start decoding it by hand. The sources of
> the libusbhid parser might be of help as well, although it contains several
> bugs and isn't spec compliant in several cases, but it might get you an idea
> of what's going on. Furthermore playing with usbhidctl might be of help.
> I have written a completly new fully spec compliant HID parser which is soon
> ready for public consumption as part of a new libhid. It contains many
> comments and should be easy to understand. The data representation directly
> takes the tree-like structure of a decoded report descriptor into account so
> that it's easy to write drivers that only handle one or more specific
> application collections. Furthermore physical descriptors are supported and
> the data handling functions hide the concept of report IDs so that it's less
> error prone to develop HID drivers (ums(4) e.g. doesn't support reports other
> than report 0 which is the reason that many of todays mice don't work). The
> parser itself will hopefully replace our current in-kernel HID parser.
OK, couple more questions: would the state of your new libhid be far enough
along that it might be possible for me to study it? If it were, could I
get a copy, if I agreed that you are giving me the copy for study only,
that I'm not to release it anywhere myself?
Another thing, is there any way, beyond my forcing the action in patched
code, to get the uhid driver to claim my device? I mean, some system
configuration method to force this, like it used to be possible back a long
time ago in the old usbd.conf? I might be able to figure some things out,
if I could experiment with usbhidctl, if I could use it thru uhid.
>> I am having a terrible time trying to figure out
>> the actual scope of each statement, which refers to what. I don't run any
>> piece of Windows stuff here, so many of the pieces of demo software I have
>> found on the web do me no good.
> I didn't find any windows software that really made it easier to understand
> the spec. It's IMHO easier to directly get your hands dirty and to read the
> code of an HID parser.
You;'re going to tell me it's easier to read the code than read the spec,
and in the same breath tell me that the spec isn't so badly written?
>> I'm not giving up, I keep on making new discoveries, but if anyone knows of
>> a description of HID that involves some real use of English, I sure would
>> appreciate a pointer to it.
> If you have any specific questions, please drop me a mail.
Look, I'll be honest, I'm kinda embarrassed at the level questions I need
answered, I'm probagbly not going to ask them here on the mail list. If I
were to start up a usbhid channel on freenode, anyone might come up there
and answer questions?
If not, don't worry, I'm going to keep at this until I di understand it,
I'm rather stubborn.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.4 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the freebsd-usb