FIRST Robotics Competition Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Buttons of Joysticks

Hi, I am using the Attack 3 controll, but when I want to control several actions by pushing the buttons they does not respond. I have checked all the PWM and the programming is the normal one with case structures. The problem is that the program does not detect the T of F constants when the buttons are pressed. Can anybody help me, please.

0 Kudos
Message 1 of 4
(6,201 Views)

When you run your code can you open the front panel of the Joystick Get VI (WPI_JoystickGet.vi) and watch the Button indicator?

Are you using the Unbuldle by Name function in your code.

Post your code for us to see just what it is that you are doing. Not sure what you mean by "T of F constants" when we or talking about something that will vary (change not constant)

Omar
0 Kudos
Message 2 of 4
(3,233 Views)

Yes, but the motor do not responds.

0 Kudos
Message 3 of 4
(3,233 Views)

Hey Sebastian,

You will need to take the Button input from the joystick into a LabVIEW Case structure which will have a true and false case. In the True case you will need to set your motor to do one thing and in the false case set it to do another. This can be done with the motor control VI's in the Advanced pallette of the WPI Robotics Library. If you continue to have issues post your project and we can take a look at it.

Kevin Fort
Principal Software Engineer
NI
0 Kudos
Message 4 of 4
(3,233 Views)