Jump to content

  • Log In with Google      Sign In   
  • Create Account

Banner advertising on our site currently available from just $5!


1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!


Linux Xbox Controller


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
3 replies to this topic

#1 jeff8j   Members   -  Reputation: 771

Like
0Likes
Like

Posted 09 July 2013 - 08:10 PM

I would like to use a xbox 360 controller for my game in linux just like in windows. I can find some information about a driver but from what I hear it doesnt need it after kernel 2.6. My problem though is I dont know where to start I cant find any examples or apis to use to access the controllers. Can anyone help point me in the right direction? Thanks


Firefox youtube video and audio downloader MP3 MP4 OGG WEBM

https://addons.mozilla.org/en-US/firefox/addon/simple-youtube-converter/


Sponsor:

#2 shadowisadog   Crossbones+   -  Reputation: 2706

Like
0Likes
Like

Posted 09 July 2013 - 09:59 PM

PyGame, SDL, ect can all read input from the Joystick. From there it is just a matter of knowing the button codes.

 

Reading Joystick input in SDL

 

PyGame Joystick API

 

SFML Joystick



#3 jeff8j   Members   -  Reputation: 771

Like
0Likes
Like

Posted 09 July 2013 - 10:45 PM

Ok so I guess it the same as a joystick apparently. Ill have to look into how to read the joystick. Thanks


Firefox youtube video and audio downloader MP3 MP4 OGG WEBM

https://addons.mozilla.org/en-US/firefox/addon/simple-youtube-converter/


#4 NightCreature83   Crossbones+   -  Reputation: 3448

Like
0Likes
Like

Posted 10 July 2013 - 02:41 AM

The only thing I am missing from that is the device packet number as it will only change that value when actual input on the pad has changed. This is an easy way of checking whether there is any input coming from an XInput device. Unless SDL or PyGame already deal with this.


Worked on titles: CMR:DiRT2, DiRT 3, DiRT: Showdown, GRID 2, Mad Max




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS