View Single Post
  #2   Spotlight this post!  
Unread 08-03-2014, 21:22
RufflesRidge RufflesRidge is offline
Registered User
no team
 
Join Date: Jan 2012
Location: USA
Posts: 990
RufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant future
Re: Get joystick name and index in wpilib C++

Quote:
Originally Posted by DarthCoder View Post
Is there any way to get an identifier to tell which stick is shown as which index?
Unless you can find a unique value to key off of (The throttle on the joystick may be an option here) there is no great way to do this. The best bet may be to use the throttle on the logitech joystick to identify it. Secure it all the way down with tape and then look for that value.

EDIT: Just re-read and realized you're talking about harvesting the joystick internals for a custom device. The same thought applies, just tie one of the axes to 0 or 5V (or whatever the max voltage on the internal pots is) and key off of that.

Quote:
Also, I'm not incorrect in interpreting the rules as meaning that a box of switches set before the match during strategy talks would be fine to use because no human is touching the driver station or moving beyond the white line during autonomous mode am I?
Nope, lots of teams use this type of technique to select autonomous modes.