Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
X-Box Controller using the xpad
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2, 3, 4  Next  
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Sat Sep 11, 2004 12:49 am    Post subject: Reply with quote

D-Pad works for me. Are you getting anything at all from the joystick with jstest and/or jscalibrator?
Back to top
View user's profile Send private message
flazz
Guru
Guru


Joined: 22 Nov 2003
Posts: 496
Location: Florida

PostPosted: Sat Sep 11, 2004 1:43 am    Post subject: Reply with quote

yep, but i cant use them in a game or zsnes
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Sun Sep 12, 2004 12:02 am    Post subject: Reply with quote

How did you set zsnes to use the D-Pad? I found that if I define 'Up' as 'left analogue stick up', then D-Pad up worked as Up as well, if that makes sense. So try setting the games up with the analogue stick, and then use the D-Pad anyway, that might work. Apart from that, we'll need to hack the module code, because the D-Pad isn't the first set of axes (axis?), the left analogue is.
Back to top
View user's profile Send private message
bungernut
Apprentice
Apprentice


Joined: 24 Jan 2004
Posts: 173

PostPosted: Mon Sep 13, 2004 4:46 am    Post subject: Does any one have a good method to patch Reply with quote

someone plaease post a link to a forum on how to patch manually, i dont know how and could not find one in the fourms. Thanks
_________________
Two idiots make a wrong
Back to top
View user's profile Send private message
flazz
Guru
Guru


Joined: 22 Nov 2003
Posts: 496
Location: Florida

PostPosted: Mon Sep 13, 2004 5:14 am    Post subject: Reply with quote

when i set up zsnes to use the stick the dpad does nothing whatsoever.

btw i think we need to set up some sort of xpad community, its too good of a pad not to
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Mon Sep 13, 2004 6:47 am    Post subject: Reply with quote

flazz: If jstest and/or jscalibrator find all the correct buttons/axis but some programs won't, I think it's more likely an issue with that program. I'm using zsnes v1.36 here and it seems to work fine however. Are you using an official MS controller, an S-type controller, or some 3rd party? I've got an S-type personally.

bungernut: See http://www.linuxhq.com/patch-howto.html
If any issues arise, contact me.
Back to top
View user's profile Send private message
flazz
Guru
Guru


Joined: 22 Nov 2003
Posts: 496
Location: Florida

PostPosted: Mon Sep 13, 2004 12:34 pm    Post subject: Reply with quote

i have the s-controller and zsnes 1.36; i have never gotten the dpad to work. but it comes up as axi 6 and 7, should the patch fix this?
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Mon Sep 13, 2004 12:44 pm    Post subject: Reply with quote

Well I had it working both with and without the patch. I clicked on Up or whatever, and then moved the analogue stick up, or pressed up on the D-Pad. They seem to be synonymous in zsnes at least.

I've got the dpad coming up as axis 4 & 5. Actually, try the patch out, if you feel like it. Without the patch, L+R triggers are treated as two axis, which is why your dpad is at 6/7. Maybe zsnes only supports 5 axis, I dunno.
Also, just check in jstest that the values in axes 6/7 go from -32767(left) to 32767(right), and the same values for up/down. With the patch, up is -32767. I didn't change anything with the D-Pad, but check to see if you get the same results.
Back to top
View user's profile Send private message
flazz
Guru
Guru


Joined: 22 Nov 2003
Posts: 496
Location: Florida

PostPosted: Tue Sep 14, 2004 1:58 pm    Post subject: Reply with quote

first where did you get jtest?, i dont have it.

(and now the dumb questions)
second i used to be able to modprobe xpad and the permission on /dev/input/js0 was readable to all, now i have to change the permission of it. why would i ahve to change the permission?

thrid how can i have the xpad module loaded when i boot?
Back to top
View user's profile Send private message
flazz
Guru
Guru


Joined: 22 Nov 2003
Posts: 496
Location: Florida

PostPosted: Thu Sep 16, 2004 4:01 am    Post subject: Reply with quote

i patched it and got L & R to work, but i still cant get the D-pad to work at all. it comes up fine as axi 4 & 5 in js calibrator.

anyone have any ideas?
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Fri Sep 17, 2004 8:50 am    Post subject: Reply with quote

Well the big issue is that it shows up in jstest/jscalibrator. If it shows up there, then the module is loading it fine. I don't know how or why, but I'd be guessing at userland-software issues. Have you tried any other programs, like some other emulator, mame maybe?

Edit: Gah, what am I thinking, hardware error? userland-software's what I meant.
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Fri Sep 17, 2004 9:00 am    Post subject: Reply with quote

Anyway, as to autoloading, it should autoload when you plug it in.. actually, yeah it might not do that either.
There's a text file /etc/modules.autoload.d/kernel-2.6 which lists all the modules you want loaded. Try that to autoload on bootup.

Also can you do the following for me
Unplug the xpad device.
Code:
cd /proc/bus/usb
cat devices >> ~/noxpad

## Plug the xpad device in to the USB port

cat devices >> ~/xpadhere
diff ~/xpadhere ~/noxpad

And then post the output
That should show just two or 3 sections where your xbox is listed. I need the Vendor & ProdID sections, so I can updated the driver, so it knows what devices are xpads.
Oh, also a quick description of your device, i.e. 'Microsoft X-Box pad (USA)' or something similar.

Thanks
Back to top
View user's profile Send private message
Xylene
Tux's lil' helper
Tux's lil' helper


Joined: 01 Sep 2003
Posts: 111

PostPosted: Mon Oct 04, 2004 7:22 pm    Post subject: Reply with quote

Has the axises on the joystick thing on the pad ever been fixed?
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Mon Oct 04, 2004 10:38 pm    Post subject: Reply with quote

As in up being down, and down being up? If so, download and apply my patch, I've had a few reported successess, and no bad reports yet.
Back to top
View user's profile Send private message
Xylene
Tux's lil' helper
Tux's lil' helper


Joined: 01 Sep 2003
Posts: 111

PostPosted: Tue Oct 05, 2004 9:26 pm    Post subject: Reply with quote

the_enigma wrote:
As in up being down, and down being up? If so, download and apply my patch, I've had a few reported successess, and no bad reports yet.

Does it work on the 2.6.8-gentoo-r3 kernel sources?
Back to top
View user's profile Send private message
fldc
n00b
n00b


Joined: 23 Feb 2004
Posts: 17
Location: Sweden

PostPosted: Tue Oct 12, 2004 9:02 pm    Post subject: Reply with quote

Anyone with a working copy of the patch, host seems down?
Back to top
View user's profile Send private message
woodwizzle
Apprentice
Apprentice


Joined: 30 Nov 2003
Posts: 225

PostPosted: Wed Oct 13, 2004 6:05 pm    Post subject: Reply with quote

Host seems to be back up. At least for me. This patch is a clear improvement over the default patch. I don't know if the_enigma still plans on maintaining it, but what can we do to at least get this one revision into the official linux kernel?
Back to top
View user's profile Send private message
fldc
n00b
n00b


Joined: 23 Feb 2004
Posts: 17
Location: Sweden

PostPosted: Thu Oct 14, 2004 10:11 pm    Post subject: Reply with quote

You're right, only my host is unable to reach it for some reason.
The controller is behaving a bit better now. Works fine in some programs, but for most of the programs/emulators i've tested with the controller goes wild when trying to use the analogue stick to configure the controls, and i'm still not able to use the d-pad.
Well it's a start anyway :)
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Thu Nov 04, 2004 2:02 am    Post subject: Reply with quote

Hmm, I'm not getting emails when people respond here again ...
Yes, the file did go missing for a few days when I cleaned out my website, but it's back up.
fldc, does the joystick work well with jscalibrator and/or jstest?
Check the dpad with those as well, and I'll see what I can do.
Back to top
View user's profile Send private message
fldc
n00b
n00b


Joined: 23 Feb 2004
Posts: 17
Location: Sweden

PostPosted: Sat Nov 13, 2004 3:11 pm    Post subject: Reply with quote

the_enigma wrote:
Hmm, I'm not getting emails when people respond here again ...
Yes, the file did go missing for a few days when I cleaned out my website, but it's back up.
fldc, does the joystick work well with jscalibrator and/or jstest?
Check the dpad with those as well, and I'll see what I can do.


yes, jscalibrator shows both dpad and anaouloge stick to seem function correctly.
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Sat Nov 13, 2004 9:55 pm    Post subject: Reply with quote

fldc wrote:
the_enigma wrote:
Hmm, I'm not getting emails when people respond here again ...
Yes, the file did go missing for a few days when I cleaned out my website, but it's back up.
fldc, does the joystick work well with jscalibrator and/or jstest?
Check the dpad with those as well, and I'll see what I can do.


yes, jscalibrator shows both dpad and anaouloge stick to seem function correctly.



Strange. In that case, I'd be tempted to say that it's more of an issue with programs/emulators, since jscalibrator show the stick and dpad working, but I'm not sure. Exactly what programs/emulators are giving you issues?
Back to top
View user's profile Send private message
darklegion
Guru
Guru


Joined: 14 Nov 2004
Posts: 468

PostPosted: Sun Nov 14, 2004 2:15 am    Post subject: Reply with quote

Here is a patch that was designed for DDR games that sets the d-pad directions as buttons rather than axes.It may help with the inverting problems also: http://einsteinsbreakfast.com/demos/xpad.c
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Sun Nov 14, 2004 7:58 am    Post subject: Reply with quote

I just checked that patch. It doesn't invert the axes. Mine does. This doesn't mean that the patch is broken. I don't know exactly why, but it might only be sometimes that the axes are inverted. Anyway, I like his idea of using parameters to decide which 'mode' to use. Might fiddle with that some day, so you can choose to invert/noninvert the axes, and use the Triggers as axes or buttons etc.
Back to top
View user's profile Send private message
the_enigma
Apprentice
Apprentice


Joined: 23 Aug 2004
Posts: 210
Location: Brisbane, Aus

PostPosted: Sat Jan 22, 2005 3:46 am    Post subject: Reply with quote

Finally :)
Patch is updated now. It now allows you to choose via module options whether to invert the axes. It also allows you to choose to use DDR mode (dpad as buttons) and to set the triggers as buttons as opposed to axes.
The options are passed as number, but really each bit represents an option.
Lowest to highest bits:
Bit 1: Invert left y axis
Bit 2: Invert right y axis
Bit 3: Use DDR mode
Bit 4: Use triggers as buttons
For example, to just invert both axes you'll want 0011, or 3
modprobe xpad options=3
To use DDR mode, you want 0100, or 4
modprobe xpad options=4
And so forth

http://www.strudel-hound.com/xpad-0.0.7.patch

It should patch cleanly against any kernel pretty much. I've tested with 2.6.7, 2.6.8 and 2.6.10
Back to top
View user's profile Send private message
jesse_kahtava
n00b
n00b


Joined: 30 Nov 2004
Posts: 66
Location: Ontario, Canada

PostPosted: Sat Jan 22, 2005 3:56 am    Post subject: How about controlling X with an xpad? Reply with quote

Does anybody know how to use the xpad as an X pointer? i've heard it can be done, but i've tried many a time with no avail...
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Goto page Previous  1, 2, 3, 4  Next
Page 2 of 4

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum