Named commands not running

Hello. We’ve been trying to implement Pathplanner into our code rewrite, but we can’t seem to get the named commands to run during auton. We’ve looked at the other posts about named commands and tried their solutions, but nothing seems to work. Any help would be greatly appreciated. Here is the link to our code: https://github.com/richardson-area-wide-robotics/Frc24-Crescendo-1745-OffSeason-AdvantageKit/tree/pathplanner

So far as I can see, the only autonomous routines you’re calling are in AutoTrajectory, which is only concerned with following paths. You should maybe try executing the PathPlannerAuto as a command instead of just calling getPathGroupFromAutoFile on it. When you call getPathGroupFromAutoFile, you’re saying “throw out all the named commands and just give me the paths”.

Or consider calling AutoBuilder.buildAutoChooser instead of autoModeChooser.

1 Like

To add an option to the auto chooser, you should use this pattern:
automodeChooser.addOption(“displayed name”, AutoBuilde.runAuto(“auto name”));

Thanks, using AutoBuilder.buildAutoChooser() worked. However, we needed a path named null.path for some strange reason for the autoBuilder to build. That’s probably something that needs to be fixed, but named commands work for now.

1 Like