View Single Post
  #3   Spotlight this post!  
Unread 05-01-2009, 16:13
DavidAllen DavidAllen is offline
Registered User
FRC #2415 (The Westminster Wiredcats)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Atlanta
Posts: 5
DavidAllen is an unknown quantity at this point
Re: Programming a joystick button...

By going to WPI Robotics Library -> RobotDrive -> Joystick -> Get and placing it down in your main loop, there is an output called "buttons". This output is a bundle, which can be unbundled with Cluster, Class, ... -> Unbundle. Connect the wires and you should see a rectangle with 12 slots, representing the 12 buttons on the default controller. Then, you would link each of the slots with a case structure (Structures -> Case Structure) and add your drive code in it.

Here's a picture of what it should look like (sorry if its not the convention for posting LabVIEW code on the site. I'm not sure what it is)


This topic might also be helpful:
http://www.chiefdelphi.com/forums/sh...ad.php?t=70564