I did in fact stumble upon finding how to run the motors in reverse.
For sake of discussion let's assume that we are trying to make a Jaguar motor called wheel in port 3 go half speed backwards...
For some reason, if we code it like this, the motors only accepted forward values, thus doing nothing when going backwards:
Code:
Jaguar Wheel = new Jaguar(3);
Wheel->Set(-0.5);
I was experimenting with the code in the WPI library and found that the correct way to set motor speeds or use any other functions for that matter was:
<Object Name>.<Function Name>(<Parameters>);
Therefore, the above example would be coded something like this:
Code:
Jaguar Wheel = new Jaguar(3);
Wheel.Set(-0.5);
... where
Wheel is your object name...
Set is your function name... and
-0.5 is your parameters (as specified in the WPI library function for setting motor speeds).
I hope this solved the problem for you. If not, it could be a hardware issue (maybe check to see if your Jaguar or Victor has jumpers that allow forward/backward movement).
- Daniel