Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   General Forum (http://www.chiefdelphi.com/forums/forumdisplay.php?f=16)
-   -   Programming With an XBOX Controller (http://www.chiefdelphi.com/forums/showthread.php?t=125343)

awehunter 27-01-2014 19:29

Programming With an XBOX Controller
 
Hey guys, my team had a question. We want to use an Xbox 360 controller to control our robot, but we have no idea how to. We're going to need step-by-step instructions as to how to program it. We're using Labview, so if you have any video tutorials, or even just can go through it in text with us, it would be really really appreciated. None of us really know how to code because our "programmers" have all graduated. I say it like that because they struggled quite a lot too. Thank you a ton in advance.

dellagd 27-01-2014 20:44

Re: Programming With an XBOX Controller
 
Microsoft has the drivers for using an XBOX controller (a usb one, mind you) with a computer. From that point, just do standard joystick control.

Im guessing this? http://www.microsoft.com/hardware/en...indows#support

MrTechCenter 27-01-2014 21:39

Re: Programming With an XBOX Controller
 
You would program an Xbox Controller in Labview just like an ordinary joystick. Take a look at the example code for a joystick and do the same. There's a bit more to it that's hard to explain and I won't have access to our programming laptop until tomorrow to show an example. Message me and I'll make a video tutorial for you tomorrow.

geomapguy 27-01-2014 22:01

Re: Programming With an XBOX Controller
 
This is very helpful.....will help you determine which axis is which and same for buttons.


http://firstforge.wpi.edu/sf/frs/do/downloadFile/projects.wpilib/frs.joystick_explorer.joystick_explorer/frs1934;jsessionid=F88BF8A83468C604414BF26D99540C2 8?dl=1

omsahmad 27-01-2014 22:38

Re: Programming With an XBOX Controller
 
I have no familiarity with LabVIEW, but here are the button id's.

Code:

/** XBOX Controller Notes

* Buttons:
        * A=1
        * B=2
        * X=3
        * Y=4
        * LB=5
        * RB=6
        * Back=7
        * Start=8
        * LeftAnalog=9
        * RightAnalog=10

* Axis:
        * LeftX=1
        * LeftY=2
        * RightX=4
        * RightY=5
        * Trigger=3 (Left moves -, Right moves +)
 */


apalrd 28-01-2014 09:21

Re: Programming With an XBOX Controller
 
Quote:

Originally Posted by omsahmad (Post 1333470)
I have no familiarity with LabVIEW, but here are the button id's.

Code:

/** XBOX Controller Notes

* Buttons:
        * A=1
        * B=2
        * X=3
        * Y=4
        * LB=5
        * RB=6
        * Back=7
        * Start=8
        * LeftAnalog=9
        * RightAnalog=10

* Axis:
        * LeftX=1
        * LeftY=2
        * RightX=4
        * RightY=5
        * Trigger=3 (Left moves -, Right moves +)
 */


D-Pad X is on axis 6 also.

Previously, LeftAnalog and RightAnalog were only on Trigger (not Digitals). Has this changed?

cgmv123 28-01-2014 10:47

Re: Programming With an XBOX Controller
 
Quote:

Originally Posted by apalrd (Post 1333613)
Previously, LeftAnalog and RightAnalog were only on Trigger (not Digitals). Has this changed?

If you push the joysticks straight down, they both register as additional buttons.

apalrd 28-01-2014 11:01

Re: Programming With an XBOX Controller
 
Quote:

Originally Posted by cgmv123 (Post 1333643)
If you push the joysticks straight down, they both register as additional buttons.

Hrm.

I mapped out that controller in 2011 and could not find those buttons. Maybe they changed something since then.


All times are GMT -5. The time now is 02:11.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi