Quote:
Originally Posted by YairZiv
Hey, so as we get close to the season, there's one thing we wanna understand how to do. We wanna understand how to drive straight using autonomous period. Using a PIDController for distance will not work since the two sides of the chassis may drive in a different speed. Using a PIDController for speed might work a little better though it will be hard to land in the distance we tried to go to. So how do we go into doing something like that?
Good luck in the season everybody!
|
You can also look at our library in which you will find a PidDrive class that provides a method named "setTarget". It allows you to set the target distances in X or the Y direction. It also let you specified the "heading" you want to maintain relative to current heading. Don't worry about it being a FTC project. Our library is shared between FTC and FRC, so the TrcLib portion of the library is platform independent. So it would be identical code between FTC and FRC.
https://github.com/trc492/FtcSamples...cPidDrive.java