a15008b56d2869cfe2305b5ec113ebde42f913e8
1 package org
.usfirst
.frc
.team3501
.robot
.commands
.driving
;
3 import org
.usfirst
.frc
.team3501
.robot
.Constants
.Direction
;
5 import edu
.wpi
.first
.wpilibj
.Timer
;
6 import edu
.wpi
.first
.wpilibj
.command
.Command
;
8 public class TurnForTime
extends Command
{
10 public TurnForTime(double seconds
, Direction direction
) {
11 Timer timer
= new Timer();
15 protected void initialize() {
19 protected void execute() {
21 * if direction is right make the left motor run forward make the right
22 * motor run backward if direction is left make right motor run forward make
23 * the left motor run backward
28 protected boolean isFinished() {
30 * when time is up return true
36 protected void end() {
40 protected void interrupted() {