From d66813a195a58ed2457f70162676495bd3f7574b Mon Sep 17 00:00:00 2001 From: samuel desharnais Date: Sat, 24 Feb 2024 12:03:52 -0500 Subject: [PATCH 1/3] --- .../deploy/pathplanner/autos/B.H.5.2.auto | 95 +++++++++++++++++++ src/main/deploy/pathplanner/autos/B.H.5.auto | 14 +-- ...{Copy of B.C.5.auto => Copy of B.H.5.auto} | 2 +- .../paths/Copy of Copy of 1.2.path | 49 ++++++++++ 4 files changed, 152 insertions(+), 8 deletions(-) create mode 100644 src/main/deploy/pathplanner/autos/B.H.5.2.auto rename src/main/deploy/pathplanner/autos/{Copy of B.C.5.auto => Copy of B.H.5.auto} (97%) create mode 100644 src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path diff --git a/src/main/deploy/pathplanner/autos/B.H.5.2.auto b/src/main/deploy/pathplanner/autos/B.H.5.2.auto new file mode 100644 index 0000000..c55ff2e --- /dev/null +++ b/src/main/deploy/pathplanner/autos/B.H.5.2.auto @@ -0,0 +1,95 @@ +{ + "version": 1.0, + "startingPose": { + "position": { + "x": 0.7, + "y": 6.7 + }, + "rotation": 150.0 + }, + "command": { + "type": "sequential", + "data": { + "commands": [ + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "wait", + "data": { + "waitTime": 3.0 + } + }, + { + "type": "named", + "data": { + "name": "lancer" + } + } + ] + } + }, + { + "type": "parallel", + "data": { + "commands": [ + { + "type": "path", + "data": { + "pathName": "3.1" + } + }, + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "wait", + "data": { + "waitTime": 3.7 + } + }, + { + "type": "named", + "data": { + "name": "balayer" + } + } + ] + } + } + ] + } + }, + { + "type": "path", + "data": { + "pathName": "3.2" + } + }, + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "wait", + "data": { + "waitTime": 3.0 + } + }, + { + "type": "named", + "data": { + "name": "lancer" + } + } + ] + } + } + ] + } + }, + "folder": "3", + "choreoAuto": false +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/autos/B.H.5.auto b/src/main/deploy/pathplanner/autos/B.H.5.auto index c55ff2e..9ba6bef 100644 --- a/src/main/deploy/pathplanner/autos/B.H.5.auto +++ b/src/main/deploy/pathplanner/autos/B.H.5.auto @@ -2,10 +2,10 @@ "version": 1.0, "startingPose": { "position": { - "x": 0.7, - "y": 6.7 + "x": 1.3, + "y": 5.55 }, - "rotation": 150.0 + "rotation": 90.0 }, "command": { "type": "sequential", @@ -37,7 +37,7 @@ { "type": "path", "data": { - "pathName": "3.1" + "pathName": "Copy of 1.1" } }, { @@ -47,7 +47,7 @@ { "type": "wait", "data": { - "waitTime": 3.7 + "waitTime": 6.0 } }, { @@ -65,7 +65,7 @@ { "type": "path", "data": { - "pathName": "3.2" + "pathName": "Copy of 1.2" } }, { @@ -90,6 +90,6 @@ ] } }, - "folder": "3", + "folder": "1", "choreoAuto": false } \ No newline at end of file diff --git a/src/main/deploy/pathplanner/autos/Copy of B.C.5.auto b/src/main/deploy/pathplanner/autos/Copy of B.H.5.auto similarity index 97% rename from src/main/deploy/pathplanner/autos/Copy of B.C.5.auto rename to src/main/deploy/pathplanner/autos/Copy of B.H.5.auto index 9ba6bef..bdb174c 100644 --- a/src/main/deploy/pathplanner/autos/Copy of B.C.5.auto +++ b/src/main/deploy/pathplanner/autos/Copy of B.H.5.auto @@ -65,7 +65,7 @@ { "type": "path", "data": { - "pathName": "Copy of 1.2" + "pathName": "Copy of Copy of 1.2" } }, { diff --git a/src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path b/src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path new file mode 100644 index 0000000..d38045f --- /dev/null +++ b/src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path @@ -0,0 +1,49 @@ +{ + "version": 1.0, + "waypoints": [ + { + "anchor": { + "x": 2.9961928869726684, + "y": 5.320840271310172 + }, + "prevControl": null, + "nextControl": { + "x": 3.022850290942747, + "y": 5.320840271310172 + }, + "isLocked": false, + "linkedName": null + }, + { + "anchor": { + "x": 1.3, + "y": 5.55 + }, + "prevControl": { + "x": 1.2354194138940418, + "y": 5.55 + }, + "nextControl": null, + "isLocked": false, + "linkedName": null + } + ], + "rotationTargets": [], + "constraintZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 1.0, + "maxAcceleration": 1.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0 + }, + "goalEndState": { + "velocity": 0, + "rotation": -78.51347446508561, + "rotateFast": false + }, + "reversed": false, + "folder": "1", + "previewStartingState": null, + "useDefaultConstraints": false +} \ No newline at end of file From 5bdfbf1297d50a7d82a8eed16d97928360ab0b9e Mon Sep 17 00:00:00 2001 From: samuel desharnais Date: Sat, 24 Feb 2024 12:05:44 -0500 Subject: [PATCH 2/3] --- .../pathplanner/autos/Copy of B.H.5.auto | 2 +- .../paths/Copy of Copy of 1.2.path | 49 ------------------- 2 files changed, 1 insertion(+), 50 deletions(-) delete mode 100644 src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path diff --git a/src/main/deploy/pathplanner/autos/Copy of B.H.5.auto b/src/main/deploy/pathplanner/autos/Copy of B.H.5.auto index bdb174c..9ba6bef 100644 --- a/src/main/deploy/pathplanner/autos/Copy of B.H.5.auto +++ b/src/main/deploy/pathplanner/autos/Copy of B.H.5.auto @@ -65,7 +65,7 @@ { "type": "path", "data": { - "pathName": "Copy of Copy of 1.2" + "pathName": "Copy of 1.2" } }, { diff --git a/src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path b/src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path deleted file mode 100644 index d38045f..0000000 --- a/src/main/deploy/pathplanner/paths/Copy of Copy of 1.2.path +++ /dev/null @@ -1,49 +0,0 @@ -{ - "version": 1.0, - "waypoints": [ - { - "anchor": { - "x": 2.9961928869726684, - "y": 5.320840271310172 - }, - "prevControl": null, - "nextControl": { - "x": 3.022850290942747, - "y": 5.320840271310172 - }, - "isLocked": false, - "linkedName": null - }, - { - "anchor": { - "x": 1.3, - "y": 5.55 - }, - "prevControl": { - "x": 1.2354194138940418, - "y": 5.55 - }, - "nextControl": null, - "isLocked": false, - "linkedName": null - } - ], - "rotationTargets": [], - "constraintZones": [], - "eventMarkers": [], - "globalConstraints": { - "maxVelocity": 1.0, - "maxAcceleration": 1.0, - "maxAngularVelocity": 540.0, - "maxAngularAcceleration": 720.0 - }, - "goalEndState": { - "velocity": 0, - "rotation": -78.51347446508561, - "rotateFast": false - }, - "reversed": false, - "folder": "1", - "previewStartingState": null, - "useDefaultConstraints": false -} \ No newline at end of file From faa906d6b754ef40cec4de238f071b955d854fdd Mon Sep 17 00:00:00 2001 From: samuel desharnais Date: Sat, 24 Feb 2024 13:36:13 -0500 Subject: [PATCH 3/3] --- .../java/frc/robot/command/GrimpeurDroit.java | 10 ---------- .../java/frc/robot/command/GrimpeurGauche.java | 15 --------------- 2 files changed, 25 deletions(-) diff --git a/src/main/java/frc/robot/command/GrimpeurDroit.java b/src/main/java/frc/robot/command/GrimpeurDroit.java index 44c937f..135a12e 100644 --- a/src/main/java/frc/robot/command/GrimpeurDroit.java +++ b/src/main/java/frc/robot/command/GrimpeurDroit.java @@ -30,16 +30,6 @@ public class GrimpeurDroit extends Command { @Override public void execute() { grimpeur.droit(doubleSupplier.getAsDouble()); - if(grimpeur.getpitch()<-15){ - grimpeur.droit(-doubleSupplier.getAsDouble()); - - } - else if(grimpeur.getpitch()>15){ - grimpeur.droit(doubleSupplier.getAsDouble()); - } - else{ - grimpeur.droit(0); - } } // Called once the command ends or is interrupted. diff --git a/src/main/java/frc/robot/command/GrimpeurGauche.java b/src/main/java/frc/robot/command/GrimpeurGauche.java index a1b071b..05b78ea 100644 --- a/src/main/java/frc/robot/command/GrimpeurGauche.java +++ b/src/main/java/frc/robot/command/GrimpeurGauche.java @@ -31,21 +31,6 @@ public class GrimpeurGauche extends Command { @Override public void execute() { grimpeur.gauche(doubleSupplier.getAsDouble()); - if(grimpeur.getpitch()<-15){ - grimpeur.gauche(doubleSupplier.getAsDouble()); - } - else if(grimpeur.getpitch()>15){ - grimpeur.gauche(-doubleSupplier.getAsDouble()); - } - else{ - grimpeur.gauche(0); - } - if(grimpeur.encoderg()<0){ - grimpeur.gauche(doubleSupplier.getAsDouble()); - } - else{ - grimpeur.gauche(0); - } } // Called once the command ends or is interrupted.