Quote:
Originally Posted by Trump
1) We are using mecanum wheels for our drive train, My assumption after looking through the CANJaguar code is that all I need to do is set the control mode to kSpeed, and then set m_maxoutput to the physical max RPM of our slowest motor.
|
You must be talking about RobotDrive. Just call SetMaxOutput() to set the speed that you want joystick full forward to mean. Remember that you may want to leave a little headroom for variations in battery voltage, chain tension, etc.
Quote:
Originally Posted by Trump
2) Does the CANJaguar class automatically use feedback from the encoders to correct its speed using PID? I'm assuming again that i would first need to set the speed reference to kSpeedRef_QuadEncoder, and then set the P, I, and D.
|
You need to SetSpeedReference() and ConfigEncoderCodesPerRev() and SetPID() and lastly EnableControl().
Quote:
Originally Posted by Trump
3) When the CANJag is set to KSpeed, the source code comments say the constructor will automatically set the speed reference to the quad encoder, but i don't see where in the constructor it does that.
|
That comment is outdated. It no longer does that since this year there is more than one option available. I just didn't notice that comment to delete it.
-Joe