[haiku-development] Re: Joysticks in Haiku

  • From: Disreali <mdisreali@xxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Wed, 16 Mar 2011 18:05:49 -0700 (PDT)

Hi,

--- On Wed, 3/16/11, Carwyn <cdj1000@xxxxxxx> wrote:

> Hi All,
> 
> I've been doing some experimenting and have thought of an
> idea,  how  about using the USBKit from userland to get the
> info for joysticks, gamepads etc. Any thoughts on this idea?.
> 
> I've tested my idea and can read a Gravis Gamepad Pro status
> and also a Xbox 360 controller using the USBKit InterruptTransfer
> function.  Would this be an acceptable way to implement BJoystick
> etc at least for USB devices.
> 
> This is done in linux's Xbox/Xbox360 USB Gamepad Userspace
> Driver which was made by Ingo Ruhnke.  All that needs to be
> done is get the endpoint for the device and InterruptTransfer
> 32 bytes, and all the buttons, axes etc are available.
> 
> I'll upload my code to haiku dev so someone can test
> it,  i've only tested a wired Xbox 360 controller.
 
It is preferred that you attach a patch to a ticket. See
http://dev.haiku-os.org/wiki/SubmittingPatches#Preparingtocreatepatchfile

Regarding your previous code attachments, did you write the GamepadDevice.cpp 
and header?  If so, you assigned the copyright to Michael Lotz instead of to 
Haiku, Inc. or yourself.  Either would be fine.

Also, Kirilla and I made a working patch from the zipped code that you attached 
to http://dev.haiku-os.org/ticket/7354, but we were uncertain as to what the 
patch/code actually did. I applied the patch to r40968 but did not see any 
change in how Haiku handled gamepads. I could not setup a gamepad in neither 
BeSMSPlus 0.94, nor BeSnesx 1.41.

Thanks for your contributions. Please let me know how I could help test your 
changes.

-D

-- 
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?



      

Other related posts: