Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 266059
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T22:49:23+00:00 2026-05-11T22:49:23+00:00

I’m interested in using libhid to access a custom HID device that we are

  • 0

I’m interested in using libhid to access a custom HID device that we are developing on a PIC microcontroller. I have been able to successfully get the test_libhid code to run. The instructions for reading and writing to devices using this library are provided as comments in the test_libhid code.

I have attempted to follow the documented techniques for reading and writing, but so far, I have not been to successfully read or write to the device. I suspect the reason may be that the report descriptor for the device specifies a 64 byte array for both the input and output data reports.

I have read the details contained in the Device Class Definition for HID section from usb.org, and I think that I understand how descriptors work in general and how they translate to HID paths, but my attempts to read and write data to the device have failed.

I have verified that the device works in Windows, so my problem appears to lie on the Linux side. I don’t think that it should matter, but I should note that I’m currently working in a VMWare virtual machine, loaded with Ubuntu 8.04 server

Can anyone provide some guidance on how to specify he HID path for the following report descriptor (generated from lsusb –vvv):

Report Descriptor: (length is 29)
    Item(Global): Usage Page, data= [ 0x00 0xff ] 65280 
                        (null)
    Item(Local ): Usage, data= [ 0x01 ] 1
                        (null)
    Item(Main  ): Collection, data= [ 0x01 ] 1
                        Application
    Item(Local ): Usage Minimum, data= [ 0x01 ] 1
                        (null)
    Item(Local ): Usage Maximum, data= [ 0x40 ] 64
                        (null)
    Item(Global): Logical Minimum, data= [ 0x00 ] 0
    Item(Global): Logical Maximum, data= [ 0xff 0x00 ] 255
    Item(Global): Report Size, data= [ 0x08 ] 8
    Item(Global): Report Count, data= [ 0x40 ] 64
    Item(Main  ): Input, data= [ 0x02 ] 2
                  Data Variable Absolute No_Wrap Linear
                  Preferred_State No_Null_Position Non_Volatile Bitfield
    Item(Local ): Usage Minimum, data= [ 0x01 ] 1
                        (null)
    Item(Local ): Usage Maximum, data= [ 0x40 ] 64
                        (null)
    Item(Main  ): Output, data= [ 0x02 ] 2
                        Data Variable Absolute No_Wrap Linear
                        Preferred_State No_Null_Position Non_Volatile Bitfield
    Item(Main  ): End Collection, data=none

Also, when I run the test_libhid program, it dumps the parse tree as 64 identical entries that look like this:

path: 0xff000001.0x00000000; type: 0x80

These are presumably the inputs. This list is followed by another 64 entries that look like this:

path: 0xff000001.0x00000000; type: 0x90

I have posted to the libhid mailing list, but there has not been much activity there recently, so I thought that I would bring my question here. If anyone can provide guidance on how the HID path for this input and output report should be specified, it would be a tremendous help.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T22:49:23+00:00Added an answer on May 11, 2026 at 10:49 pm

    After much trial and error, I was never able to get libhid to work with the report descriptor for my target device. I did find that the HID Device Interface (hiddev) worked very well, and was actually very easy to understand. There is a good PDF Reference for hiddev that I highly recommend. Also, the include file hiddev.h in /usr/include/linux was also very helpful. In Ubuntu 8.04, the hiddev interface worked “out of the box” with no additional configuration required.

    Hopefully this will be of some help to the next person that has problems interfacing their HID device to a Linux host.

    Note: The link that I provided for the .PDF file above seems to have disappeared. I posted a copy of the .PDF file here. Its a free file sharing service, so you will need to endure a few advertisements in order to download it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 152k
  • Answers 152k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Why not get the Feedapi, along with feedapi mapper, and… May 12, 2026 at 10:03 am
  • Editorial Team
    Editorial Team added an answer Javascript function names are case sensitive. document.getElementById not document.getelementbyid alert(typeof… May 12, 2026 at 10:03 am
  • Editorial Team
    Editorial Team added an answer To select one option <h:selectOneMenu id="list1"> <f:selectItem itemLabel="Option 1" itemValue="1"></f:selectItem>… May 12, 2026 at 10:03 am

Related Questions

I'm interested in using Functional MetaPost on Mac OS X: http://cryp.to/funcmp/ I'm looking for
I'm interested in using an Object-Relational Mapping package for an upcoming project. This project
I'm interested in using a Reed-Solomon error correction [ http://en.wikipedia.org/wiki/Reed%E2%80%93Solomon_error_correction as a reference] to
I'm interested in using Python to hack on the data in Flash swf files.

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.