From: Andres Esteban Echeverria G Date: Sun, 5 Feb 2017 01:09:59 +0000 (-0800) Subject: added command for toggling camera feeds X-Git-Url: http://challenge-bot.com/repos/?p=3501%2F2017steamworks;a=commitdiff_plain;h=338130b6ad701e4a5f3f6217186d9cb45cd91895 added command for toggling camera feeds --- diff --git a/src/org/usfirst/frc/team3501/robot/OI.java b/src/org/usfirst/frc/team3501/robot/OI.java index 935c4c6..77791cd 100644 --- a/src/org/usfirst/frc/team3501/robot/OI.java +++ b/src/org/usfirst/frc/team3501/robot/OI.java @@ -1,5 +1,7 @@ package org.usfirst.frc.team3501.robot; +import org.usfirst.frc.team3501.robot.commands.accessories.ToggleCameraFeed; + import edu.wpi.first.wpilibj.Joystick; import edu.wpi.first.wpilibj.buttons.Button; import edu.wpi.first.wpilibj.buttons.JoystickButton; @@ -12,6 +14,8 @@ public class OI { public static Button toggleIndexWheel; public static Button toggleFlyWheel; + + public static Button toggleCameraFeeds; public OI() { leftJoystick = new Joystick(Constants.OI.LEFT_STICK_PORT); @@ -22,6 +26,10 @@ public class OI { Constants.OI.TOGGLE_INDEXWHEEL_PORT); toggleFlyWheel = new JoystickButton(leftJoystick, Constants.OI.TOGGLE_FLYWHEEL_PORT); + + toggleCameraFeeds = new JoystickButton(leftJoystick, Constants.OI.TOGGLE_CAMERA_FEEDS); + + toggleCameraFeeds.whenReleased(new ToggleCameraFeed()); } public static OI getOI() {