Quote:
Originally Posted by robot_rover
Currently I was trying to get the control mode to see if it needed to be changed in teleop. When our bot is in auto it sets the mode to position. What I was trying to do was set the mode to speed in the teleop vi only if it wasn't already in Speed mode. Right now I have a workaround where it only runs the change mode code if the bot has been disabled since the last time the teleop vi was called.
|
If you always want speed mode in teleop, you could just set it to speed regardless of mode. There's no issue with redundant mode change calls.
Edit: what Mark said above would also work for the way you're trying to go about it.
Edit again: Additionally, if you're only changing out of speed mode in auto, another solution would be to set the talons to speed mode at the very end of the routine.