File tree 9 files changed +24
-31
lines changed
src/com/stuypulse/frc2017/robot/commands/auton
9 files changed +24
-31
lines changed Original file line number Diff line number Diff line change 11
11
*
12
12
*/
13
13
public class ApproachAllianceHopperFromBoiler extends CommandGroup {
14
- //TODO: Math (not priority)
15
- private static final double TURN_TO_HOPPER = -1 ;
16
- private static final double DRIVE_TO_HOPPER = -1 ;
14
+ private static final double TURN_TO_HOPPER = -45 ;
15
+ private static final double DRIVE_TO_HOPPER = 77 ;
17
16
18
17
public ApproachAllianceHopperFromBoiler () {
19
18
int direction ;
Original file line number Diff line number Diff line change 12
12
*/
13
13
public class ApproachHPFromBoilerGearCommand extends CommandGroup {
14
14
public static final double BOILER_GEAR_TO_NEUTRAL_ZONE_ANGLE = 60 ;
15
- public static final double BOILER_GEAR_TO_NEUTRAL_ZONE_DISTANCE = 374 ; // TODO: maybe subtract 12 inches
16
- public static final double BOILER_GEAR_NEUTRAL_ZONE_TO_HP_ANGLE = -45 ;
17
- //TODO: Math (priority)
18
- public static final double BOILER_GEAR_NEUTRAL_ZONE_TO_HP_DISTANCE = -1 ;
15
+ public static final double BOILER_GEAR_TO_NEUTRAL_ZONE_DISTANCE = 71 ;
16
+ public static final double BOILER_GEAR_NEUTRAL_ZONE_TO_HP_ANGLE = -43 ;
17
+ public static final double BOILER_GEAR_NEUTRAL_ZONE_TO_HP_DISTANCE = 361 ;
19
18
20
19
public ApproachHPFromBoilerGearCommand () {
21
20
int direction ;
Original file line number Diff line number Diff line change 12
12
*/
13
13
public class ApproachHPFromHPGearCommand extends CommandGroup {
14
14
public static final double HP_GEAR_TO_NEUTRAL_ZONE_ANGLE = -60 ;
15
- public static final double HP_GEAR_TO_NEUTRAL_ZONE_DISTANCE = 374 ; // TODO: maybe subtract 12 inches here
15
+ public static final double HP_GEAR_TO_NEUTRAL_ZONE_DISTANCE = 362 ; //374- 12 inches deviation
16
16
17
17
public ApproachHPFromHPGearCommand () {
18
18
// Add Commands here:
Original file line number Diff line number Diff line change 11
11
*
12
12
*/
13
13
public class ApproachHPFromMiddleGearCommand extends CommandGroup {
14
- //TODO: Math (priority)
15
14
public static final double MIDDLE_GEAR_TO_AIRSHIP_HP_SIDE_ANGLE = -90 ;
16
- public static final double MIDDLE_GEAR_TO_AIRSHIP_HP_SIDE_DISTANCE = - 1 ;
15
+ public static final double MIDDLE_GEAR_TO_AIRSHIP_HP_SIDE_DISTANCE = 46.6 ; //TODO: check value
17
16
public static final double AIRSHIP_HP_SIDE_TO_NEUTRAL_ZONE_ANGLE = 90 ;
18
- public static final double AIRSHIP_HP_SIDE_TO_NEUTRAL_ZONE_DISTANCE = -1 ;
19
-
17
+ public static final double AIRSHIP_HP_SIDE_TO_NEUTRAL_ZONE_DISTANCE = 362 ; //374- 12 inches deviation
20
18
public ApproachHPFromMiddleGearCommand () {
21
19
int direction ;
22
20
if (DriverStation .getInstance ().getAlliance () == DriverStation .Alliance .Red ) {
Original file line number Diff line number Diff line change 12
12
*/
13
13
public class ApproachNeutralHopperFromBoiler extends CommandGroup {
14
14
15
- double TURN_AWAY_FROM_BOILER = 45 ;
16
- double MOVE_TOWARD_HOPPER = 206 .3 ;
15
+ double TURN_AWAY_FROM_BOILER = - 45 ;
16
+ double MOVE_TOWARD_HOPPER = 249 .3 ;
17
17
double TURN_TO_HOPPER = 90 ;
18
- double MOVE_TO_HOPPER = 112 ;
18
+ double MOVE_TO_HOPPER = 77 ;
19
19
20
20
public ApproachNeutralHopperFromBoiler () {
21
21
int direction ;
Original file line number Diff line number Diff line change 10
10
*
11
11
*/
12
12
public class MiddleGearMobilityMinimalCommand extends CommandGroup {
13
- //TODO: Math (priority)
14
- private double FIRST_MOBILITY_TURN_DISTANCE = -1 ;
15
- private double FIRST_MOBILITY_TURN_ANGLE = -1 ;
16
- private double SECOND_MOBILITY_TURN_DISTANCE = -1 ;
17
- private double SECOND_MOBILITY_TURN_ANGLE = -1 ;
18
- private double FINAL_MOBILITY_TURN_DISTANCE = -1 ;
13
+ private double FIRST_MOBILITY_TURN_DISTANCE = 53.3 ; //baseline-robot length
14
+ private double FIRST_MOBILITY_TURN_ANGLE = -90 ;
15
+ private double SECOND_MOBILITY_TURN_DISTANCE = 61.1 ;
16
+ private double SECOND_MOBILITY_TURN_ANGLE = 90 ;
17
+ private double FINAL_MOBILITY_TURN_DISTANCE = 52 ; //robot length + 12 inches deviation
19
18
20
19
public MiddleGearMobilityMinimalCommand () {
21
20
// Add Commands here:
Original file line number Diff line number Diff line change 8
8
*
9
9
*/
10
10
public class MobilityMinimalCommand extends CommandGroup {
11
- //TODO: Math (priority)
12
- public static final double MOBILITY_TO_BASELINE_DISTANCE = - 1 ;
11
+
12
+ public static final double MOBILITY_TO_BASELINE_DISTANCE = 93.3 ;
13
13
14
14
public MobilityMinimalCommand () {
15
15
// Add Commands here:
Original file line number Diff line number Diff line change 8
8
*
9
9
*/
10
10
public class MobilityToHPCommand extends CommandGroup {
11
- //TODO: Math (priority)
12
- public static final double MOBILITY_TO_NEUTRAL_ZONE_DISTANCE = -1 ;
11
+ public static final double MOBILITY_TO_NEUTRAL_ZONE_DISTANCE = 415.3 ;//427.3 - 12 inches deviation
13
12
14
13
public MobilityToHPCommand () {
15
14
Original file line number Diff line number Diff line change 13
13
*
14
14
*/
15
15
public class ScoreMiddleGearFromBoilerCommand extends CommandGroup {
16
- private static final double BACK_UP_FROM_BOILER_DISTANCE = -127.3 ;
17
- private static final double TURN_AWAY_FROM_BOILER = -45 ;
18
- //TODO: Set numbers from testing
19
- private static final double MOVE_TOWARDS_LIFT = -1 ; // :(
16
+ private static final double BACK_UP_FROM_BOILER_DISTANCE = -131.9 ;
17
+ private static final double TURN_AWAY_FROM_BOILER = 135 ;
18
+ private static final double MOVE_TOWARDS_LIFT = 80.7 ;
20
19
private static final double TURN_TOWARDS_LIFT = 90 ;
21
- private static final double MOVE_TO_LIFT = - 1 ; // :(
20
+ private static final double MOVE_TO_LIFT = 21 ;
22
21
23
22
public ScoreMiddleGearFromBoilerCommand () {
24
23
int direction ;
@@ -37,7 +36,7 @@ public ScoreMiddleGearFromBoilerCommand() {
37
36
addSequential (new DriveForwardEncodersCommand (ScoreMiddleGearCommand .MIDDLE_GEAR_REVERSE_DISTANCE ));
38
37
addSequential (new GearPusherRetractGearCommand ());
39
38
addSequential (new GearTrapTrapGearCommand ());
40
-
39
+
41
40
// Add Commands here:
42
41
// e.g. addSequential(new Command1());
43
42
// addSequential(new Command2());
You can’t perform that action at this time.
0 commit comments