Arduino reading data from a HID

Hello all,

I am trying to use a usb HID device as the interface for a little hack I'm working on. Does anyone know how to read and interpret the signal from a usb HID? I've seen lots of threads where people are trying to get the arduino to act like a HID but non where they are receiving and parsing data that comes from a HID.

basically I want to receive button presses and convert them to other types of data or actions. Can anyone help me? A whitepaper for USB-HID would even be quite useful though I didn't find any via google search.

thanks, Jim

Hi, info about HID is here http://www.lvr.com/hidpage.htm. But there is no way to turn the Arduino into an USB-HostController (This is what you are asking for) with the extra burdon of interpreting the HID-Reports coming from the device. The Ardunio is simply much too slow for that.

Sorry for the bad news Eberhard

basically I want to receive button presses and convert them to other types of data or actions.

Care to be more specific about your device/requirements?

--Phil.

I’m just trying to get the data from key presses on a gamepad… that way I could make it plug and play for any USB game pad, instead of needing to hack apart the guts every time I want to switch.

Investigate the FTDI Vinculum. It implements a USB HID Host interface which can interface to flash driver, printers, and HID among other things. It's a very generic interface, you'll still need to know about report descriptors, and won't be that easy. But far easier than implementing it from scratch.

I decided to just hack the game pads. I'm just going to add a switch that toggles between the standard USB interface and the hacked interface for my application. That way it's still usable with computers/etc in the future.

Investigate the FTDI Vinculum.

Heh, I had almost written a comment about the Vinculum...

It implements a USB HID Host interface which can interface to flash driver, printers, and HID among other things. It's a very generic interface, you'll still need to know about report descriptors, and won't be that easy.

The main reason I decided not to mention it was that from my cursory reading it seems that once you get past the popular things (like Flash Drives etc) you've got to do a fair bit of work to get it functioning. By which point I wonder if you're actually just better-off with a more powerful microcontroller. (Maybe some needs to port Arduino to one of Atmel's USB host capable devices? :-) )

--Phil.

Maybe some needs to port Arduino to one of Atmel's USB host capable devices? :-)

how hard would that really be? isn't it just a matter of detecting the new microcontroller in the IDE and then implementing the c compiler for said microcontroller?

Maybe some needs to port Arduino to one of Atmel's USB host capable devices?

Aren't those 8051 architecture devices? If so, it's a bit of a stretch, seeing as we don't haven have most of the AVR list supported yet. (:

-j

Maybe some needs to port Arduino to one of Atmel’s USB host capable devices?

Aren’t those 8051 architecture devices? If so, it’s a bit of a stretch, seeing as we don’t haven have most of the AVR list supported yet. (:

It seems they have both AVR and 8051 architecture USB host-capable devices:

Maybe some needs to port Arduino to one of Atmel's USB host capable devices? :-)

how hard would that really be? isn't it just a matter of detecting the new microcontroller in the IDE and then implementing the c compiler for said microcontroller?

Be my guest. :-)

--Phil.

Maybe some needs to port Arduino to one of Atmel's USB host capable devices? :-)

how hard would that really be? isn't it just a matter of detecting the new microcontroller in the IDE and then implementing the c compiler for said microcontroller?

Be my guest. :-)

--Phil.

if only I could

if only I could

Then you know how hard it really is. ;)

I think I could do it if I knew how the existing IDE worked... but I really don't have time to learn that :-/