Rename DriveSetAngle to DriveAbsoluteTurnPID

This commit is contained in:
Keenan D. Buckley
2019-03-07 18:44:34 -07:00
parent 63f2ac14bd
commit 4a4b807ebb
2 changed files with 42 additions and 24 deletions
@@ -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() {
}
}
@@ -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;
}
}