View Single Post
  #7   Spotlight this post!  
Unread 20-01-2015, 17:33
team-4480's Avatar
team-4480 team-4480 is offline
Debug? What's that?
FRC #4480
 
Join Date: Jan 2015
Rookie Year: 2013
Location: Minnesooota
Posts: 229
team-4480 will become famous soon enoughteam-4480 will become famous soon enough
Re: How to use Xbox controller with RobotPy?

Quote:
Originally Posted by virtuald View Post
Yeah, the docs aren't super clear on that, I'll need to update. When AxisType is specified, what it really means is pass in one of the constants that is defined in the class, or you can also just pass in a number. So something like...

Code:
joystick = wpilib.Joystick(0)
rightX = joystick.getAxis(4)
rightY = joystick.getAxis(5)
That might work. It might not.
The joystick didn't work sadly. Is that the best way to do it or is there other ways? Thanks!