AOA Forums AOA Forums AOA Forums Folding For Team 45 AOA Files Home Front Page Become an AOA Subscriber! UserCP Calendar Memberlist FAQ Search Forum Home


Go Back   AOA Forums > Hardware > Hardware Hacking

Hardware Hacking The hammer and tongs school of Overclocking. (NOT for the beginner and you assume all risks)


Reply
 
LinkBack Thread Tools Rate Thread
  #1 (permalink)  
Old 29th October, 2008, 05:22 PM
Chief Systems Administrator
 
Join Date: September 2001
Location: Europe
Posts: 13,075

Building HID descriptors

Wasn't sure where I should put this one...

Has anyone ever tried building descriptors for HID devices? In this case, I'm looking to build a descriptor for a gamepad type device, and I'm going nowhere fast.
__________________
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 29th October, 2008, 06:58 PM
Gizmo's Avatar
Chief BBS Administrator
BassTeroids Champion, Global Player Champion, Aim & Fire Champion, Puzzle Maniax Champion, Othello Champion, Canyon Glider Champion, Unicycle Challenge Champion, YetiSports 9: Final Spit Champion, Zed Champion
 
Join Date: May 2003
Location: Webb City, Mo
Posts: 16,178
Send a message via ICQ to Gizmo Send a message via AIM to Gizmo Send a message via MSN to Gizmo Send a message via Yahoo to Gizmo Send a message via Skype™ to Gizmo

Haven't done that. I rather thought it was a relatively simple process, from what little I've read.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 30th October, 2008, 09:23 AM
Chief Systems Administrator
 
Join Date: September 2001
Location: Europe
Posts: 13,075

I've been trying to get my head around it - for some reason the concepts seem simple, but putting them into practice hasn't been. I know that Windows is a bit picky about the descriptors, but even modifying existing examples haven't got me very far!
__________________
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 30th October, 2008, 09:26 AM
Chief Systems Administrator
 
Join Date: September 2001
Location: Europe
Posts: 13,075

For example, if I use this the following example (I forget where I found it sadly), then all is sweet.

Code:
 //Six button gamepad (length 47)
   {0x05,0x01,  // Usage Page (Generic Desktop) 	
	0x09,0x05,	// Usage (Gamepad)					
    0xa1,0x01,  // 2 Collection (Application)  
	0x09, 0x01, // USAGE (Pointer)
	0xa1, 0x00, // COLLECTION (Physical)
	0x09, 0x30, // USAGE (X)
	0x09, 0x31, // USAGE (Y)
	0x15, 0x00, // LOGICAL_MINIMUM (0)
	0x26, 0xFF, // LOGICAL_MAXIMUM (255)
	0x00, 0x75, 0x08,// REPORT_SIZE (8)	
	0x95, 0x02, // REPORT_COUNT (2)
	0x81, 0x02, // INPUT (Data,Var,Abs)
	0xc0,       // END_COLLECTION
	0x05, 0x09, // USAGE_PAGE (Button)
	0x19, 0x01, // USAGE_MINIMUM (Button 1)
	0x29, 0x06, // USAGE_MAXIMUM (Button 6)
	0x15, 0x00, // LOGICAL_MINIMUM (0)
	0x25, 0x01, // LOGICAL_MAXIMUM (1)
	0x75, 0x01, // REPORT_SIZE (1)
	0x95, 0x06, // REPORT_COUNT (6)
	0x81, 0x02, // INPUT (Data,Var,Abs)
	0x95, 0x02, // REPORT_COUNT (2)
	0x81, 0x03, // INPUT (Constant,Var,Abs)
	0xc0 }     // END_COLLECTION
If I attempt to tweek it (for example, 7 buttons rather than 6) then things break. For example, adjusting the usage page for buttons like this:

Code:
	0x19, 0x01, // USAGE_MINIMUM (Button 1)
	0x29, 0x07, // USAGE_MAXIMUM (Button 7)
	0x15, 0x00, // LOGICAL_MINIMUM (0)
	0x25, 0x01, // LOGICAL_MAXIMUM (1)
	0x75, 0x01, // REPORT_SIZE (1)
	0x95, 0x07, // REPORT_COUNT (7)
results in a device that windows claims it can't enumerate properly.

Am I just a bit thick, or am I missing something fundamental?
__________________

Last edited by Áedán; 30th October, 2008 at 09:27 AM. Reason: speeling
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Building a system WonderBread AMD Motherboards & CPUs 28 5th November, 2005 10:34 AM
Building Forum amarkarian Random Nonsense! 16 25th May, 2005 09:41 PM
Are you building a new Folder? LP ThunderRd's AOA FOLDING@HOME Team 34 23rd November, 2003 12:07 PM
Team building! Daniel ~ ThunderRd's AOA FOLDING@HOME Team 8 25th September, 2001 04:17 AM


All times are GMT +1. The time now is 01:39 AM.


Copyright ©2001 - 2010, AOA Forums
Don't Click Here Don't Click Here Either

Search Engine Friendly URLs by vBSEO 3.3.0