[haiku-development] Re: Joysticks in Haiku

  • From: Stephan Aßmus <superstippi@xxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Mon, 14 Mar 2011 09:34:23 +0100

Am 14.03.2011 02:38, schrieb Carwyn:
Here are my current shenanigans with the usb_hid and joystick after
reading mmlr's post on dev.haiku,  with these modifications it is now
possible to find out a device type by using the following,

HIDCollection *collection = device->Parser()->RootCollection();
if(collection->UsagePage() != B_HID_USAGE_PAGE_GENERIC_DESKTOP
                || collection->UsageID() != B_HID_UID_GD_GAMEPAD) return NULL;

I'm uploading my usb_hid folder so that someone could have a look and
see if these changes are acceptable or if there are any drawbacks to
this method.  I do have a gamepad working at the moment with the new
GamepadDevice.cpp in the zip file.

Thanks!

dev.haiku-os.org has a section about generating and submitting patches. Basically, you have to use "svn diff > patch.diff" from the command line, preferrably from the root folder, giving svn the path to your changed source folder(s).

Best regards,
-Stephan

Other related posts: