Quote:
Originally Posted by Andrew Schreiber
This is because you are using a PID controller on them. You are telling it to try to get to a certain value. Try not using the PID controller (try removing the cjag.EnableControl(); line and see if you get the same behavior)
|
He's right, it's due to the PID control. We also used CAN and C++ on our robot this year, and started with P as 1.0, I as 0.01 and D as 0. It will still loop, but will get to speed much quicker, although it may have significant overshoot until you tune it.
As far as I know, there is no way to control the Jaguars with encoders without a PID loop being involved.
I'm not a programmer so I'm not sure about this, but you might also need to construct the CANJaguar as CANJaguar::kSpeed instead of kPercentVbus.
Hope this helps!