Package frc.robot
Class SubsystemManager
java.lang.Object
frc.robot.SubsystemManager
The SubsystemManager coordinates all of the classes and ensures only one sequence is run at at time.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassA class separating all of the command getters.static final recordStores a set of chassis speeds and acceleration feedforwards to accept PathPlanner output.class -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final SubsystemManagercom.ctre.phoenix6.Orchestraedu.wpi.first.math.estimator.SwerveDrivePoseEstimator -
Method Summary
Modifier and TypeMethodDescriptionedu.wpi.first.math.geometry.Pose3d[]edu.wpi.first.math.kinematics.ChassisSpeedsReturns the current robot speeds for reference for pid control.edu.wpi.first.math.geometry.Pose2dReturns the estimated pose.voidvoidsetupOrchestra(int tracks) Clears and refills the orchestra to play MIDI sequences.voidupdate(RobotContainer.JoystickInputs stick_inputs)
-
Field Details
-
instance
-
m_robot_state
-
commands
-
pose_estimator
public edu.wpi.first.math.estimator.SwerveDrivePoseEstimator pose_estimator -
tracked_target
-
orchestra
public com.ctre.phoenix6.Orchestra orchestra -
m_pathplanner_speeds
-
-
Method Details
-
getPoseEstimate
public edu.wpi.first.math.geometry.Pose2d getPoseEstimate()Returns the estimated pose. Updates PoseEstimator with odometry readings for most accurate estimate.- Returns:
- The updated pose estimate.
-
getComponentPoses
public edu.wpi.first.math.geometry.Pose3d[] getComponentPoses() -
getPidReferenceSpeeds
public edu.wpi.first.math.kinematics.ChassisSpeeds getPidReferenceSpeeds()Returns the current robot speeds for reference for pid control.- Returns:
- The current robot-relative chassis speeds.
-
update
-
setupOrchestra
public void setupOrchestra() -
setupOrchestra
public void setupOrchestra(int tracks) Clears and refills the orchestra to play MIDI sequences.- Parameters:
tracks- The number of tracks the midi file contains.
-