Skip to content

Commit

Permalink
Add autoDetect functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
vs2961 committed Apr 12, 2019
1 parent b905a5f commit ab33840
Show file tree
Hide file tree
Showing 3 changed files with 601 additions and 284 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id "java"
id "edu.wpi.first.GradleRIO" version "2019.1.1"
id "edu.wpi.first.GradleRIO" version "2019.3.2"
}

def ROBOT_MAIN_CLASS = "edu.stuy.robot.Main"
Expand Down
6 changes: 6 additions & 0 deletions src/main/java/edu/stuy/robot/Robot.java
Original file line number Diff line number Diff line change
Expand Up @@ -199,9 +199,13 @@ private void setupShootChooser() {

public void disabledPeriodic() {
Scheduler.getInstance().run();
oi.driverGamepad.resetGamepadType();
oi.operatorGamepad.resetGamepadType();
}

public void autonomousInit() {
oi.driverGamepad.resetGamepadType();
oi.operatorGamepad.resetGamepadType();
try {
Robot.cvSignalLight.stayOff();
debugMode = (Boolean) debugChooser.getSelected();
Expand Down Expand Up @@ -252,6 +256,8 @@ public void autonomousPeriodic() {
}

public void teleopInit() {
oi.operatorGamepad.resetGamepadType();
oi.driverGamepad.resetGamepadType();
try {
// This makes sure that the autonomous stops running when
// teleop starts running. If you want the autonomous to
Expand Down
Loading

0 comments on commit ab33840

Please sign in to comment.