Hello,
This is the first season our team has experimented with Trajectory Path Following and we have had some issues with performance, which leads to some basic questions we need to get clarified.
First some details. We are driving multiple path segments broken up by command actions of other systems, so each of the trajectory building/following commands are executed in a separate Sequential Command Group. Our robot is Swerve Drive so we are using the SwerveControllerCommand path following command class.
What is the purpose of the ResetOdometry (Odometry. resetPostition()) command that is called at the beginning of the Path Following command? (We are instructed to do this in the Trajectory Path Following instructions.) Is this to set the home/ origin position (0,0,0°)? Or is this to set the current starting absolute field position? It is not clear to me on whether the SwerveControllerCommand class is Field Relative or Robot Relative.
Also, in this case of stacking multiple Trajectory Path Following commands together, should each command have a ResetOdometry invoked at the beginning of their SequentialCommandGroup, or only do a single ResetOdometry call at first Trajectory Path command and then not invoke ResetOdometry on the subsequent Trajectory Path commands since you just want to continue where you left off, not start over? Perhaps knowing the answer to the Absolute vs. Relative positioning question helps answer this.
Thank You