View Single Post
  #17   Spotlight this post!  
Unread 02-03-2012, 12:10
AndrewD's Avatar
AndrewD AndrewD is offline
Programming/Electrical Mentor
AKA: Andrew Dolio
FRC #1243 (Dragons)
Team Role: Mentor
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Swartz Creek, MI
Posts: 23
AndrewD is an unknown quantity at this point
Re: Button programin C++

For the button, you could just use this:

Code:
if (leftStick.GetRawButton(1) == true) {

}
because the trigger on the joysticks is just button 1. All buttons on the Logitech ATK3's are labeled. That's why FIRST picked them. Also, that little roller thingy is the Z-axis. AKA, Axis 3.

X = 1
Y = 2
Z = 3

for controllers with 2 joysticks (like xbox or 360),

rotX = 4
rotY = 5
__________________



____________________________________________
Programming/Electrical Mentor
FRC Team #1243 - The Dragons
Reply With Quote