This commit is contained in:
parent
40b23cf3f1
commit
36859ec3ad
@ -84,11 +84,15 @@ public class RobotContainer {
|
|||||||
NamedCommands.registerCommand("lancer", new LancerNote(lanceur, accumulateur));
|
NamedCommands.registerCommand("lancer", new LancerNote(lanceur, accumulateur));
|
||||||
NamedCommands.registerCommand("piston", new PistonFerme(grimpeur));
|
NamedCommands.registerCommand("piston", new PistonFerme(grimpeur));
|
||||||
autoChooser = AutoBuilder.buildAutoChooser();
|
autoChooser = AutoBuilder.buildAutoChooser();
|
||||||
|
|
||||||
|
//manette
|
||||||
|
manette.start().whileTrue(new RestGyro(drive));
|
||||||
manette.a().whileTrue(new GuiderBas(guideur));
|
manette.a().whileTrue(new GuiderBas(guideur));
|
||||||
manette.b().whileTrue(new GuiderHaut(guideur));
|
manette.b().whileTrue(new GuiderHaut(guideur));
|
||||||
manette.x().whileTrue(new PistonFerme(grimpeur));
|
manette.x().whileTrue(new PistonFerme(grimpeur));
|
||||||
manette.y().whileTrue(new PistonOuvre(grimpeur));
|
manette.y().whileTrue(new PistonOuvre(grimpeur));
|
||||||
|
|
||||||
|
//joystick
|
||||||
joystick.button(3).whileTrue(new Balayer(balayeuse, accumulateur));
|
joystick.button(3).whileTrue(new Balayer(balayeuse, accumulateur));
|
||||||
joystick.button(1).whileTrue(new LancerNote(lanceur, accumulateur));
|
joystick.button(1).whileTrue(new LancerNote(lanceur, accumulateur));
|
||||||
joystick.button(5).whileTrue(new LancerAmp(lanceur, accumulateur));
|
joystick.button(5).whileTrue(new LancerAmp(lanceur, accumulateur));
|
||||||
@ -96,7 +100,7 @@ public class RobotContainer {
|
|||||||
joystick.button(2).whileTrue(new ParallelCommandGroup(new Lancerampli(lanceur,limelight),new Limelight_tracker(limelight,drive)));
|
joystick.button(2).whileTrue(new ParallelCommandGroup(new Lancerampli(lanceur,limelight),new Limelight_tracker(limelight,drive)));
|
||||||
joystick.button(6).whileTrue(new LancerTrape(lanceur, accumulateur));
|
joystick.button(6).whileTrue(new LancerTrape(lanceur, accumulateur));
|
||||||
joystick.button(7).whileTrue(new Limelight_tracker(limelight, drive));
|
joystick.button(7).whileTrue(new Limelight_tracker(limelight, drive));
|
||||||
manette.start().whileTrue(new RestGyro(drive));
|
|
||||||
// deplacement
|
// deplacement
|
||||||
configureBindings();
|
configureBindings();
|
||||||
drive.setDefaultCommand(new RunCommand(()->{
|
drive.setDefaultCommand(new RunCommand(()->{
|
||||||
|
@ -18,13 +18,13 @@ public class RestGyro extends Command {
|
|||||||
|
|
||||||
// Called when the command is initially scheduled.
|
// Called when the command is initially scheduled.
|
||||||
@Override
|
@Override
|
||||||
public void initialize() {}
|
public void initialize() {
|
||||||
|
drive.restgyroscope();
|
||||||
|
}
|
||||||
|
|
||||||
// Called every time the scheduler runs while the command is scheduled.
|
// Called every time the scheduler runs while the command is scheduled.
|
||||||
@Override
|
@Override
|
||||||
public void execute() {
|
public void execute() {}
|
||||||
drive.restgyroscope();
|
|
||||||
}
|
|
||||||
|
|
||||||
// Called once the command ends or is interrupted.
|
// Called once the command ends or is interrupted.
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
x
Reference in New Issue
Block a user