We’re trying to tune our auto to be close to precise but I’m stumped on how to tune autos. I’m changing the HolonomicPathFollowerConfig PID values but I don’t know how to fully tune these because I’m struggling to make any changes. Is there a sysid type routine that can give us good auto pid constants? Thanks!
Hi, welcome to CD!
Can you tell us what exactly is the problem right now? Is your robot not moving to the correct positions? You can open pathplanner telemetry to see if your robot is moving correctly.
The robot does move to the position but it’s off by a couple of inches consistently. I tried to use Pathplanner’s telemetry but it wasn’t connecting to the robot.
I don’t suppose you have colsons on the modules…
Worn colsons = different circumference. Therefore you ratios/conversion factor would be off.
Honestly that might be it. We switched to colsons before 2024 season and we haven’t swapped them out since. But still I guess in the future next time we make a new bot it would be nice to know what the right things are to do to make a good auto
Yeah we had bumpers a little under a quarter of an inch off the ground at the start of the season, by the end of the off season the fabric was touching the ground and wore through in a few spots. A quarter of an inch off the radius is over an inch and a half off the circumference on a 4" wheel. Absolutely noticeable, but should be uniform at least.
The experiment I’ve recommended in the past at this one, which you’ll want to do every now and then if wheels are wear components…
Measure out a fixed distance, ideally on carpet that looks/feels/acts like the field carpet. Drive the robot straight from one end of the distance to the other, and measure the number of wheel rotations it takes to get there. Be as precise as you can, but also try it at different speeds and different directions - the wisdom of the ancients says the direction of the carpet weave relative to the direction of travel makes a slight difference.
How that slight difference theoretically works in my brain
The fact that folded carpet yarn versus flat carpet yarn will compress different amounts will… theoretically… slightly change the rolling radius. The dynamic interaction of folding/unfolding as direction change probably doesn’t help either.
I know 254 and others have measured the effect experimentally, though I don’t know if anyone really drilled enough to determine true root cause.
Use c=2 \pi r and the total measured distance for each run to calculate r from your experimental data. Average everything out.
Extra credit: track the std dev’s of your results over different runs, and see if there’s correlation of the error to direction, speed, etc. See if that std dev will be meaningful to your autonomous routines. Contemplate a mitigation strategy if you believe it will be meaningful.