Attempts to create methods for the gyro to work, but testing has failed
authorEvanYap <evanyap.14@gmail.com>
Thu, 11 Feb 2016 05:15:04 +0000 (21:15 -0800)
committerCindy Zhang <cindyzyx9@gmail.com>
Sat, 13 Feb 2016 19:55:54 +0000 (11:55 -0800)
src/org/usfirst/frc/team3501/robot/FirebotGyro.java
src/org/usfirst/frc/team3501/robot/Robot.java

index fefa59085a589c0d77a9d1785cd141049a04ecb8..c1d1552d513b95bec639f4a8bdb58d92afd7e2d5 100644 (file)
@@ -705,7 +705,7 @@ public class FirebotGyro extends SensorBase
    * @see ITG3200_RA_GYRO_ZOUT_H
    */
   public short getRotationZ() {
-    return ReadShortFromRegister(ITG3200_RA_GYRO_ZOUT_H, 2);
+    return ReadShortFromRegister(ITG3200_RA_GYRO_ZOUT_H, 0);
   }
 
   // PWR_MGM register
index 9e5980437f33774cb3c4723ba972b4b360f8a420..ea981e5b7126b51bf14db4e559b142d9203ba091 100644 (file)
@@ -32,11 +32,7 @@ public class Robot extends IterativeRobot {
   short rawValue;
   public FirebotGyro gyro;
 
-  double initialSpeedNanoseconds;
-  double finalSpeedNanoseconds;
-  double initialSpeedSeconds;
-  double finalSpeedSeconds;
-  double deltaSpeed;
+  double degreesIncreased;
   double degrees;
 
   @Override
@@ -54,10 +50,10 @@ public class Robot extends IterativeRobot {
     // and the positions of the defenses from a drop-down menu on the Smart
     // Dashboard
     // make the Sendable Choosers
-    initializeSendableChoosers();
-    addPositionChooserOptions();
-    addDefensesToAllDefenseSendableChooosers();
-    sendSendableChoosersToSmartDashboard();
+    // initializeSendableChoosers();
+    // addPositionChooserOptions();
+    // addDefensesToAllDefenseSendableChooosers();
+    // sendSendableChoosersToSmartDashboard();
 
   }
 
@@ -107,12 +103,14 @@ public class Robot extends IterativeRobot {
         positionFourDefense);
     SmartDashboard.putData("Position Five Defense Chooser",
         positionFiveDefense);
+
     SmartDashboard.putData("Position Four Defense Chooser",
         positionFourDefense);
     SmartDashboard.putData("Position Five Defense Chooser",
         positionFiveDefense);
 
     shooter = new Shooter();
+
   }
 
   @Override
@@ -153,4 +151,5 @@ public class Robot extends IterativeRobot {
   public void teleopPeriodic() {
     Scheduler.getInstance().run();
   }
+
 }