@@ -14,8 +14,11 @@ that the tuners require you to push the robot or the tuners output will say "inc
1414measurements will be in centimeters.
1515
1616## Tuning
17- * To start with, we need the mass of the robot in kg. This is used for the centripetal force correction,
18- and the mass, with the variable name ` mass ` , should be put on line ` 86 ` in the ` FollowerConstants `
17+ * First, make sure that your motor names and directions, located at the top of ` FollowerConstants ` ,
18+ are correct.
19+
20+ * After that, we need the mass of the robot in kg. This is used for the centripetal force correction,
21+ and the mass, with the variable name ` mass ` , should be put on line ` 92 ` in the ` FollowerConstants `
1922 class under the ` tuning ` package.
2023
2124* Next, we need to find the preferred mecanum drive vectors. The rollers on mecanum wheels point at a
@@ -27,8 +30,8 @@ measurements will be in centimeters.
2730 Dashboard under the dropdown for each respective class, but higher distances work better. After the
2831 distance has finished running, the end velocity will be output to telemetry. The robot may continue
2932 to drift a little bit after the robot has finished running the distance, so make sure you have
30- plenty of room. Once you're done, put the velocity for the ` Forward Velocity Tuner ` on line ` 33 ` in
31- the ` FollowerConstants ` class, and the velocity for the ` Strafe Velocity Tuner ` on line ` 34 ` in the
33+ plenty of room. Once you're done, put the velocity for the ` Forward Velocity Tuner ` on line ` 39 ` in
34+ the ` FollowerConstants ` class, and the velocity for the ` Strafe Velocity Tuner ` on line ` 40 ` in the
3235 ` FollowerConstants ` class. The variable names should be ` xMovement ` and ` yMovement ` , respectively.
3336
3437* The last set of automatic tuners you'll need to run are the zero power acceleration tuners. These
@@ -42,8 +45,8 @@ measurements will be in centimeters.
4245 which point it will display the deceleration in telemetry. This robot will need to drift to a stop
4346 to properly work, and the higher the velocity the greater the drift distance, so make sure you have
4447 enough room. Once you're done, put the zero power acceleration for the
45- ` Forward Zero Power Acceleration Tuner ` on line ` 94 ` in the ` FollowerConstants ` class and the zero
46- power acceleration for the ` Lateral Zero Power Acceleration Tuner ` on line ` 98 ` in the
48+ ` Forward Zero Power Acceleration Tuner ` on line ` 100 ` in the ` FollowerConstants ` class and the zero
49+ power acceleration for the ` Lateral Zero Power Acceleration Tuner ` on line ` 104 ` in the
4750 ` FollowerConstants ` class. The variable names should be ` forwardZeroPowerAcceleration ` and
4851 ` lateralZeroPowerAcceleration ` , respectively.
4952
@@ -78,7 +81,7 @@ measurements will be in centimeters.
7881 ` zeroPowerAccelerationMultiplier ` . This determines how fast your robot will decelerate as a factor
7982 of how fast your robot will coast to a stop. Honestly, this is up to you. I personally used 4, but
8083 what works best for you is most important. Higher numbers will cause a faster brake, but increase
81- oscillations at the end. Lower numbers will do the opposite. This can be found on line ` 107 ` in
84+ oscillations at the end. Lower numbers will do the opposite. This can be found on line ` 113 ` in
8285 ` FollowerConstants ` , named ` zeroPowerAccelerationMultiplier ` . The drive PID is much, much more sensitive than the others. For reference,
8386 my P values were in the hundredths and thousandths place values, and my D values were in the hundred
8487 thousandths and millionths place values. To tune this, enable ` useDrive ` , ` useHeading ` , and
@@ -104,7 +107,7 @@ measurements will be in centimeters.
104107* Finally, we will want to tune the centripetal force correction. This is a pretty simple tune. Open
105108 up FTC Dashboard and enable everything under the ` Follower ` tab. Then, run ` CurvedBackAndForth `
106109 and turn off its timer. If you notice the robot is correcting towards the inside of the curve
107- as/after running a path, then increase ` centripetalScaling ` , which can be found on line ` 89 ` of
110+ as/after running a path, then increase ` centripetalScaling ` , which can be found on line ` 95 ` of
108111 ` FollowerConstants ` . If the robot is correcting towards the outside of the curve, then decrease
109112 ` centripetalScaling ` .
110113
@@ -117,7 +120,7 @@ measurements will be in centimeters.
117120## Note About the PIDs
118121In versions of Pedro Pathing before early August 2024, there were 2 PIDs used in the translational,
119122heading, and drive control. However, now there is only one main PID. The old system can still be used.
120- Scroll down to the bottom of ` FollowerConstants ` and set all the booleans from lines ` 157 ` to ` 159 `
123+ Scroll down to the bottom of ` FollowerConstants ` and set all the booleans from lines ` 163 ` to ` 165 `
121124to true. They should be named ` useSecondaryTranslationalPID ` , ` useSecondaryHeadingPID ` , and ` useSecondaryDrivePID ` .
122125This will enable the two PID system that Pedro Pathing originally used. From there, scroll
123126down and all the values pertaining to the secondary PIDs will be there. The two PID system works with
0 commit comments