Enter brake mode for swerve when robot disables
This commit is contained in:
parent
c0900490a9
commit
dc2f483c7d
|
|
@ -1 +1 @@
|
|||
Subproject commit cd9dee709893a27de40fb86e441223dd4c068b12
|
||||
Subproject commit 191af3083de1139f70fb3496b77f299b9a7e98a8
|
||||
|
|
@ -14,6 +14,8 @@ import org.littletonrobotics.junction.Logger;
|
|||
import org.littletonrobotics.junction.networktables.NT4Publisher;
|
||||
import org.littletonrobotics.junction.wpilog.WPILOGWriter;
|
||||
|
||||
import com.ctre.phoenix6.swerve.SwerveModule;
|
||||
|
||||
import edu.wpi.first.wpilibj.Filesystem;
|
||||
import edu.wpi.first.wpilibj.PowerDistribution;
|
||||
import edu.wpi.first.wpilibj.PowerDistribution.ModuleType;
|
||||
|
|
@ -90,6 +92,9 @@ public class Robot extends LoggedRobot {
|
|||
|
||||
// Run all POST tests after robot has been initialized
|
||||
PostyManager.getInstance().runAllPOSTs();
|
||||
|
||||
|
||||
m_robotContainer.driveSubsystem.driveSystem.setBrakeMode(false);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -117,6 +122,7 @@ public class Robot extends LoggedRobot {
|
|||
/** This function is called once each time the robot enters Disabled mode. */
|
||||
@Override
|
||||
public void disabledInit() {
|
||||
m_robotContainer.driveSubsystem.driveSystem.setBrakeMode(true);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ public class DriveSubsystem extends TestableSubsystem {
|
|||
private SendableChooser<Command> autoChooser;
|
||||
|
||||
private SwerveBuilder swerveBuilder = new SwerveBuilder();
|
||||
private SwerveDriveSystem driveSystem;
|
||||
public SwerveDriveSystem driveSystem;
|
||||
|
||||
private double driveP = 0.1;
|
||||
private double driveI = 0.0;
|
||||
|
|
|
|||
Loading…
Reference in New Issue