From 4a4b807ebbb08b7b161092d01cf72584abb627a3 Mon Sep 17 00:00:00 2001 From: "Keenan D. Buckley" Date: Thu, 7 Mar 2019 18:44:34 -0700 Subject: [PATCH] Rename DriveSetAngle to DriveAbsoluteTurnPID --- .../robot/commands/DriveAbsoluteTurnPID.java | 42 +++++++++++++++++++ .../frc4388/robot/commands/DriveSetAngle.java | 24 ----------- 2 files changed, 42 insertions(+), 24 deletions(-) create mode 100644 2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveAbsoluteTurnPID.java delete mode 100644 2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveSetAngle.java diff --git a/2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveAbsoluteTurnPID.java b/2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveAbsoluteTurnPID.java new file mode 100644 index 0000000..de1dbb3 --- /dev/null +++ b/2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveAbsoluteTurnPID.java @@ -0,0 +1,42 @@ +/*----------------------------------------------------------------------------*/ +/* Copyright (c) 2018 FIRST. All Rights Reserved. */ +/* Open Source Software - may be modified and shared by FRC teams. The code */ +/* must be accompanied by the FIRST BSD license file in the root directory of */ +/* the project. */ +/*----------------------------------------------------------------------------*/ + +package org.usfirst.frc4388.robot.commands; + + +import edu.wpi.first.wpilibj.command.Command; + +public class DriveAbsoluteTurnPID extends Command { + + public DriveAbsoluteTurnPID(double absoluteTurnAngleDeg, MPSoftwareTurnType turnType) { + } + + // Called just before this Command runs the first time + @Override + protected void initialize() { + } + + // Called repeatedly when this Command is scheduled to run + @Override + } + + // Make this return true when this Command no longer needs to run execute() + @Override + protected boolean isFinished() { + } + + // Called once after isFinished returns true + @Override + protected void end() { + } + + // Called when another command which requires one or more of the same + // subsystems is scheduled to run + @Override + protected void interrupted() { + } +} diff --git a/2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveSetAngle.java b/2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveSetAngle.java deleted file mode 100644 index 2b4db9a..0000000 --- a/2019robot/src/main/java/org/usfirst/frc4388/robot/commands/DriveSetAngle.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.usfirst.frc4388.robot.commands; - -import org.usfirst.frc4388.robot.Robot; - -import edu.wpi.first.wpilibj.command.Command; - -import org.usfirst.frc4388.utility.MPSoftwarePIDController.MPSoftwareTurnType; - -public class DriveSetAngle extends Command { - - private double targetAngle; - private double maxError; - private double maxPrevError; - private MPSoftwareTurnType turnType; - // Called just before this Command runs the first time - protected void initialize() { - turnToAngle(targetAngle, maxError, maxPrevError, turnType); - } - - // Make this return true when this Command no longer needs to run execute() - protected boolean isFinished() { - return true; - } -}