1212import edu .wpi .first .wpilibj .Joystick ;
1313import edu .wpi .first .wpilibj .buttons .JoystickButton ;
1414import frc .robot .commands .ActuateClimberRails ;
15- import frc .robot .commands .NormalDrive ;
1615import frc .robot .commands .Climb ;
1716import frc .robot .commands .EjectCargo ;
1817import frc .robot .commands .IntakeOnlyCargo ;
18+ import frc .robot .commands .NormalDrive ;
1919import frc .robot .commands .SetArcadeOrTank ;
20+ import frc .robot .commands .SetLight ;
2021import frc .robot .commands .SlowDrive ;
2122import frc .robot .commands .ToggleCamera ;
2223import frc .robot .commands .ToggleHatch ;
2526import frc .robot .subsystems .Climber ;
2627import frc .robot .subsystems .Drivetrain ;
2728import frc .robot .subsystems .HatchPanel ;
29+ import frc .robot .subsystems .Lights ;
2830
2931/**
3032 * This class is the glue that binds the controls on the physical operator
@@ -42,9 +44,10 @@ public class OI {
4244 JoystickButton climbBtn ;
4345 JoystickButton toggleCameraBtn ;
4446 JoystickButton wobbleDriveBtn ;
47+ JoystickButton cycleLightBtn ;
4548
46- OI (Drivetrain dt , HatchPanel hp , Cargo cargo , Climber climber , UsbCamera driveCamera , UsbCamera hatchCamera ,
47- VideoSink cameraServer ) {
49+ OI (Drivetrain dt , HatchPanel hp , Cargo cargo , Climber climber , Lights lights , UsbCamera driveCamera ,
50+ UsbCamera hatchCamera , VideoSink cameraServer ) {
4851 leftJoy = new Joystick (0 );
4952 rightJoy = new Joystick (1 );
5053 manipulator = new Joystick (2 );
@@ -77,6 +80,9 @@ public class OI {
7780
7881 toggleCameraBtn = new JoystickButton (leftJoy , 2 );
7982 toggleCameraBtn .whenPressed (new ToggleCamera (driveCamera , hatchCamera , cameraServer ));
83+
84+ cycleLightBtn = new JoystickButton (manipulator , Manip .START );
85+ cycleLightBtn .whenPressed (new SetLight (lights ));
8086 }
8187
8288 private class Manip {
0 commit comments