From d65f1726675a91ae9302189dc0fefe2d839ffb7e Mon Sep 17 00:00:00 2001 From: Daniel Tsur Date: Sun, 25 Jan 2026 20:41:03 +0200 Subject: [PATCH 1/6] Initial Autonomous --- .../autos/Depot-Trench-Neutral-Bump.auto | 93 +++++++++++++++++++ .../deploy/pathplanner/autos/New Auto.auto | 12 +++ src/main/deploy/pathplanner/navgrid.json | 1 + .../pathplanner/paths/Alliance-Climb.path | 54 +++++++++++ .../pathplanner/paths/Alliance-DepotD.path | 54 +++++++++++ .../pathplanner/paths/Alliance-Outpost.path | 54 +++++++++++ .../pathplanner/paths/Alliance-TrenchUL.path | 54 +++++++++++ .../pathplanner/paths/BumpL-Alliance.path | 54 +++++++++++ .../pathplanner/paths/DepotD-DepotU.path | 54 +++++++++++ .../pathplanner/paths/DepotU-TrenchUL.path | 54 +++++++++++ .../pathplanner/paths/NeutralM-BumpL.path | 70 ++++++++++++++ .../pathplanner/paths/NeutralU-NeutralM.path | 54 +++++++++++ .../deploy/pathplanner/paths/New Path.path | 54 +++++++++++ .../pathplanner/paths/Outpost-TrenchDL.path | 70 ++++++++++++++ .../pathplanner/paths/TrenchUL-NeutralU.path | 75 +++++++++++++++ src/main/deploy/pathplanner/settings.json | 32 +++++++ .../autonomous/AutonomousConstants.java | 15 +++ 17 files changed, 854 insertions(+) create mode 100644 src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto create mode 100644 src/main/deploy/pathplanner/autos/New Auto.auto create mode 100644 src/main/deploy/pathplanner/navgrid.json create mode 100644 src/main/deploy/pathplanner/paths/Alliance-Climb.path create mode 100644 src/main/deploy/pathplanner/paths/Alliance-DepotD.path create mode 100644 src/main/deploy/pathplanner/paths/Alliance-Outpost.path create mode 100644 src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path create mode 100644 src/main/deploy/pathplanner/paths/BumpL-Alliance.path create mode 100644 src/main/deploy/pathplanner/paths/DepotD-DepotU.path create mode 100644 src/main/deploy/pathplanner/paths/DepotU-TrenchUL.path create mode 100644 src/main/deploy/pathplanner/paths/NeutralM-BumpL.path create mode 100644 src/main/deploy/pathplanner/paths/NeutralU-NeutralM.path create mode 100644 src/main/deploy/pathplanner/paths/New Path.path create mode 100644 src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path create mode 100644 src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path create mode 100644 src/main/deploy/pathplanner/settings.json create mode 100644 src/main/java/frc/robot/subsystems/autonomous/AutonomousConstants.java diff --git a/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto new file mode 100644 index 0000000..2a54a2e --- /dev/null +++ b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto @@ -0,0 +1,93 @@ +{ + "version": "2025.0", + "command": { + "type": "sequential", + "data": { + "commands": [ + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + }, + { + "type": "path", + "data": { + "pathName": "Alliance-DepotD" + } + }, + { + "type": "sequential", + "data": { + "commands": [ + { + "type": "path", + "data": { + "pathName": "DepotD-DepotU" + } + }, + { + "type": "named", + "data": { + "name": "Intake.intake" + } + } + ] + } + }, + { + "type": "path", + "data": { + "pathName": "DepotU-TrenchUL" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + }, + { + "type": "path", + "data": { + "pathName": "TrenchUL-NeutralU" + } + }, + { + "type": "sequential", + "data": { + "commands": [ + { + "type": "path", + "data": { + "pathName": "NeutralU-NeutralM" + } + }, + { + "type": "named", + "data": { + "name": "Intake.intake" + } + } + ] + } + }, + { + "type": "path", + "data": { + "pathName": "NeutralM-BumpL" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + } + ] + } + }, + "resetOdom": true, + "folder": null, + "choreoAuto": false +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/autos/New Auto.auto b/src/main/deploy/pathplanner/autos/New Auto.auto new file mode 100644 index 0000000..440a1ea --- /dev/null +++ b/src/main/deploy/pathplanner/autos/New Auto.auto @@ -0,0 +1,12 @@ +{ + "version": "2025.0", + "command": { + "type": "sequential", + "data": { + "commands": [] + } + }, + "resetOdom": true, + "folder": null, + "choreoAuto": false +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/navgrid.json b/src/main/deploy/pathplanner/navgrid.json new file mode 100644 index 0000000..ac5f521 --- /dev/null +++ b/src/main/deploy/pathplanner/navgrid.json @@ -0,0 +1 @@ +{"field_size":{"x":16.54,"y":8.07},"nodeSizeMeters":0.3,"grid":[[true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true],[true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,true,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,true,true,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true],[true,true,true,true,true,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,true,true,true],[true,true,true,true,true,true,false,false,false,false,false,true,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,true,true,true,true,false,false,false,false,false,true,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,true,true,true,true,true],[true,true,true,true,true,true,false,false,false,false,false,true,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,false,false,false,false,false,false,true,true,true,true,true,true],[true,true,true,true,true,true,false,false,false,false,false,true,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,false,false,false,false,false,false,true,true,true,true,true,true],[true,true,true,true,true,true,false,false,false,false,false,true,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,false,false,false,false,false,false,true,true,true,true,true,true],[true,true,true,true,true,false,false,false,false,false,false,true,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,false,false,false,false,false,false,true,true,true,true,true,true],[true,true,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,true,false,false,false,false,false,false,true,true,true,true,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,true,true,true,true,true],[true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,true,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true,true,true,true,true,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,false,true,true],[true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true],[true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true,true]]} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Alliance-Climb.path b/src/main/deploy/pathplanner/paths/Alliance-Climb.path new file mode 100644 index 0000000..6fe8acd --- /dev/null +++ b/src/main/deploy/pathplanner/paths/Alliance-Climb.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 2.230697062724346, + "y": 4.699098054676632 + }, + "prevControl": null, + "nextControl": { + "x": 2.2353915259659463, + "y": 4.449142134532953 + }, + "isLocked": false, + "linkedName": "Alliance" + }, + { + "anchor": { + "x": 1.812909969457193, + "y": 3.7744484270396033 + }, + "prevControl": { + "x": 2.0559676755271257, + "y": 3.8329544226299883 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "Climb" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 0.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Alliance-DepotD.path b/src/main/deploy/pathplanner/paths/Alliance-DepotD.path new file mode 100644 index 0000000..92b0d42 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/Alliance-DepotD.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 2.230697062724346, + "y": 4.699098054676632 + }, + "prevControl": null, + "nextControl": { + "x": 1.9806970627243459, + "y": 4.699098054676632 + }, + "isLocked": false, + "linkedName": "Alliance" + }, + { + "anchor": { + "x": 0.482, + "y": 4.951 + }, + "prevControl": { + "x": 0.5879311285557767, + "y": 4.7245522223493905 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "DepotD" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": -90.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Alliance-Outpost.path b/src/main/deploy/pathplanner/paths/Alliance-Outpost.path new file mode 100644 index 0000000..5ab510e --- /dev/null +++ b/src/main/deploy/pathplanner/paths/Alliance-Outpost.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 2.230697062724346, + "y": 4.699098054676632 + }, + "prevControl": null, + "nextControl": { + "x": 1.9890863260359186, + "y": 2.902645853645024 + }, + "isLocked": false, + "linkedName": "Alliance" + }, + { + "anchor": { + "x": 0.5, + "y": 0.6766148524443565 + }, + "prevControl": { + "x": 2.3019494066170747, + "y": 1.0862829356949055 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "Outpost" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 0.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path b/src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path new file mode 100644 index 0000000..bdc3487 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 2.230697062724346, + "y": 4.699098054676632 + }, + "prevControl": null, + "nextControl": { + "x": 2.2437708907013545, + "y": 4.948755970677763 + }, + "isLocked": false, + "linkedName": "Alliance" + }, + { + "anchor": { + "x": 3.610745262546267, + "y": 7.389868890128567 + }, + "prevControl": { + "x": 3.6450588608640397, + "y": 7.637502847756528 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "TrenchL" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 180.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/BumpL-Alliance.path b/src/main/deploy/pathplanner/paths/BumpL-Alliance.path new file mode 100644 index 0000000..283f937 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/BumpL-Alliance.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 3.1424354841902455, + "y": 5.654 + }, + "prevControl": null, + "nextControl": { + "x": 2.697546376573046, + "y": 5.341605019928494 + }, + "isLocked": false, + "linkedName": "BumpL" + }, + { + "anchor": { + "x": 2.230697062724346, + "y": 4.699098054676632 + }, + "prevControl": { + "x": 2.3790429660943966, + "y": 4.900328005114741 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "Alliance" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": -90.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/DepotD-DepotU.path b/src/main/deploy/pathplanner/paths/DepotD-DepotU.path new file mode 100644 index 0000000..2bf2549 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/DepotD-DepotU.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 0.482, + "y": 4.951 + }, + "prevControl": null, + "nextControl": { + "x": 0.482, + "y": 5.201 + }, + "isLocked": false, + "linkedName": "DepotD" + }, + { + "anchor": { + "x": 0.482, + "y": 6.51 + }, + "prevControl": { + "x": 0.482, + "y": 6.76 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "DepotU" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": -90.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/DepotU-TrenchUL.path b/src/main/deploy/pathplanner/paths/DepotU-TrenchUL.path new file mode 100644 index 0000000..b5c8094 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/DepotU-TrenchUL.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 0.482, + "y": 6.51 + }, + "prevControl": null, + "nextControl": { + "x": 1.1240891992420388, + "y": 6.828710641299977 + }, + "isLocked": false, + "linkedName": "DepotU" + }, + { + "anchor": { + "x": 3.6, + "y": 7.39 + }, + "prevControl": { + "x": 2.8655257504316123, + "y": 7.258988001934107 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "TrenchUL" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 180.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/NeutralM-BumpL.path b/src/main/deploy/pathplanner/paths/NeutralM-BumpL.path new file mode 100644 index 0000000..f1dea81 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/NeutralM-BumpL.path @@ -0,0 +1,70 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 7.733767772001379, + "y": 4.591418859242256 + }, + "prevControl": null, + "nextControl": { + "x": 6.493069507495777, + "y": 5.782383896868634 + }, + "isLocked": false, + "linkedName": "NeutralM" + }, + { + "anchor": { + "x": 5.652266590500484, + "y": 5.654 + }, + "prevControl": { + "x": 5.402266590500484, + "y": 5.654 + }, + "nextControl": { + "x": 5.902266590500484, + "y": 5.654 + }, + "isLocked": false, + "linkedName": null + }, + { + "anchor": { + "x": 3.1424354841902455, + "y": 5.654 + }, + "prevControl": { + "x": 3.391869822275747, + "y": 5.637191936939436 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "BumpL" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": -90.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": 96.944 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/NeutralU-NeutralM.path b/src/main/deploy/pathplanner/paths/NeutralU-NeutralM.path new file mode 100644 index 0000000..554ada7 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/NeutralU-NeutralM.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 7.0069443142016095, + "y": 6.631213852438146 + }, + "prevControl": null, + "nextControl": { + "x": 7.225329169697595, + "y": 6.509525500941392 + }, + "isLocked": false, + "linkedName": "NeutralU" + }, + { + "anchor": { + "x": 7.733767772001379, + "y": 4.591418859242256 + }, + "prevControl": { + "x": 7.869332796469781, + "y": 5.879501338406852 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "NeutralM" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 96.94434252981222 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": 133.91160391206455 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/New Path.path b/src/main/deploy/pathplanner/paths/New Path.path new file mode 100644 index 0000000..bb93d95 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/New Path.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 3.6, + "y": 0.6766148524443565 + }, + "prevControl": null, + "nextControl": { + "x": 4.6, + "y": 0.6766148524443567 + }, + "isLocked": false, + "linkedName": "TrenchDL" + }, + { + "anchor": { + "x": 7.007, + "y": 6.631 + }, + "prevControl": { + "x": 6.089196860397296, + "y": 6.233964237208511 + }, + "nextControl": null, + "isLocked": false, + "linkedName": null + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 0.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path b/src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path new file mode 100644 index 0000000..8127059 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path @@ -0,0 +1,70 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 0.5, + "y": 0.6766148524443565 + }, + "prevControl": null, + "nextControl": { + "x": 1.5, + "y": 0.6766148524443567 + }, + "isLocked": false, + "linkedName": "Outpost" + }, + { + "anchor": { + "x": 2.143, + "y": 0.8 + }, + "prevControl": { + "x": 1.8929999999999998, + "y": 0.8000000000000002 + }, + "nextControl": { + "x": 2.393, + "y": 0.7999999999999999 + }, + "isLocked": false, + "linkedName": null + }, + { + "anchor": { + "x": 3.6, + "y": 0.6766148524443565 + }, + "prevControl": { + "x": 3.1618596615943186, + "y": 0.6766148524443565 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "TrenchDL" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": -90.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0.0, + "rotation": 0.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path b/src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path new file mode 100644 index 0000000..80b3d4f --- /dev/null +++ b/src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path @@ -0,0 +1,75 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 3.610745262546267, + "y": 7.389868890128567 + }, + "prevControl": null, + "nextControl": { + "x": 4.144993723761676, + "y": 7.454781805381108 + }, + "isLocked": false, + "linkedName": "TrenchL" + }, + { + "anchor": { + "x": 6.192141591664908, + "y": 7.389868890128567 + }, + "prevControl": { + "x": 5.952390083217673, + "y": 7.460715302862561 + }, + "nextControl": { + "x": 6.431893100112142, + "y": 7.319022477394573 + }, + "isLocked": false, + "linkedName": null + }, + { + "anchor": { + "x": 7.0069443142016095, + "y": 6.631213852438146 + }, + "prevControl": { + "x": 6.969006340429836, + "y": 6.878318506676167 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "NeutralU" + } + ], + "rotationTargets": [ + { + "waypointRelativePos": 0.757914225260417, + "rotationDegrees": 180.0 + } + ], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0.0, + "rotation": 133.91160391206455 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": 180.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/settings.json b/src/main/deploy/pathplanner/settings.json new file mode 100644 index 0000000..5bf438c --- /dev/null +++ b/src/main/deploy/pathplanner/settings.json @@ -0,0 +1,32 @@ +{ + "robotWidth": 0.9, + "robotLength": 0.9, + "holonomicMode": true, + "pathFolders": [], + "autoFolders": [], + "defaultMaxVel": 3.0, + "defaultMaxAccel": 3.0, + "defaultMaxAngVel": 540.0, + "defaultMaxAngAccel": 720.0, + "defaultNominalVoltage": 12.0, + "robotMass": 74.088, + "robotMOI": 6.883, + "robotTrackwidth": 0.546, + "driveWheelRadius": 0.048, + "driveGearing": 5.143, + "maxDriveSpeed": 5.45, + "driveMotorType": "krakenX60", + "driveCurrentLimit": 60.0, + "wheelCOF": 1.2, + "flModuleX": 0.273, + "flModuleY": 0.273, + "frModuleX": 0.273, + "frModuleY": -0.273, + "blModuleX": -0.273, + "blModuleY": 0.273, + "brModuleX": -0.273, + "brModuleY": -0.273, + "bumperOffsetX": 0.0, + "bumperOffsetY": 0.0, + "robotFeatures": [] +} \ No newline at end of file diff --git a/src/main/java/frc/robot/subsystems/autonomous/AutonomousConstants.java b/src/main/java/frc/robot/subsystems/autonomous/AutonomousConstants.java new file mode 100644 index 0000000..161953b --- /dev/null +++ b/src/main/java/frc/robot/subsystems/autonomous/AutonomousConstants.java @@ -0,0 +1,15 @@ +package frc.robot.subsystems.autonomous; + +import static edu.wpi.first.units.Units.Meters; + +import edu.wpi.first.math.controller.PIDController; +import edu.wpi.first.units.measure.Distance; + +public class AutonomousConstants { + public static final PIDController kTranslationPID = new PIDController(5, 0, 0); + public static final PIDController kAnglePID = new PIDController(2, 0, 0); + public static final Distance kMinDistanceToPathfind = Meters.of(1); + public static final Distance kDistanceFromHub = Meters.of(2); + public static final String kDefaultAuto = "DefaultAuto"; + public static Distance kDistanceFromOutpost = Meters.of(0.7); +} From 530a35ce5db2327407aaee0d40aa4c2159edd348 Mon Sep 17 00:00:00 2001 From: Daniel Tsur Date: Thu, 5 Feb 2026 19:15:35 +0200 Subject: [PATCH 2/6] Added some autonomous paths according to Ifergan's request --- .../autos/Depot-Trench-Neutral-Bump.auto | 6 +- .../deploy/pathplanner/autos/New Auto.auto | 12 --- .../autos/Outpost-Trench-Neutral-Bump.auto | 74 ++++++++++++++++++ ...{New Path.path => NeutralD-NeutralMD.path} | 24 +++--- .../pathplanner/paths/NeutralMD-BumperDL.path | 75 +++++++++++++++++++ ...utralM-BumpL.path => NeutralMU-BumpL.path} | 29 ++++--- ...-NeutralM.path => NeutralU-NeutralMU.path} | 18 ++--- .../pathplanner/paths/Outpost-TrenchDL.path | 2 +- .../pathplanner/paths/TrenchDL-NeutralD.path | 75 +++++++++++++++++++ .../pathplanner/paths/TrenchUL-NeutralU.path | 24 +++--- 10 files changed, 278 insertions(+), 61 deletions(-) delete mode 100644 src/main/deploy/pathplanner/autos/New Auto.auto create mode 100644 src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto rename src/main/deploy/pathplanner/paths/{New Path.path => NeutralD-NeutralMD.path} (66%) create mode 100644 src/main/deploy/pathplanner/paths/NeutralMD-BumperDL.path rename src/main/deploy/pathplanner/paths/{NeutralM-BumpL.path => NeutralMU-BumpL.path} (70%) rename src/main/deploy/pathplanner/paths/{NeutralU-NeutralM.path => NeutralU-NeutralMU.path} (74%) create mode 100644 src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path diff --git a/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto index 2a54a2e..8863bfc 100644 --- a/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto +++ b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto @@ -54,13 +54,13 @@ } }, { - "type": "sequential", + "type": "deadline", "data": { "commands": [ { "type": "path", "data": { - "pathName": "NeutralU-NeutralM" + "pathName": "NeutralU-NeutralMU" } }, { @@ -75,7 +75,7 @@ { "type": "path", "data": { - "pathName": "NeutralM-BumpL" + "pathName": "NeutralMU-BumpL" } }, { diff --git a/src/main/deploy/pathplanner/autos/New Auto.auto b/src/main/deploy/pathplanner/autos/New Auto.auto deleted file mode 100644 index 440a1ea..0000000 --- a/src/main/deploy/pathplanner/autos/New Auto.auto +++ /dev/null @@ -1,12 +0,0 @@ -{ - "version": "2025.0", - "command": { - "type": "sequential", - "data": { - "commands": [] - } - }, - "resetOdom": true, - "folder": null, - "choreoAuto": false -} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto b/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto new file mode 100644 index 0000000..02a15c8 --- /dev/null +++ b/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto @@ -0,0 +1,74 @@ +{ + "version": "2025.0", + "command": { + "type": "sequential", + "data": { + "commands": [ + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + }, + { + "type": "path", + "data": { + "pathName": "Alliance-Outpost" + } + }, + { + "type": "path", + "data": { + "pathName": "Outpost-TrenchDL" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + }, + { + "type": "path", + "data": { + "pathName": "TrenchDL-NeutralD" + } + }, + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "path", + "data": { + "pathName": "NeutralD-NeutralMD" + } + }, + { + "type": "named", + "data": { + "name": "Intake.intake" + } + } + ] + } + }, + { + "type": "path", + "data": { + "pathName": "NeutralMD-BumperDL" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + } + ] + } + }, + "resetOdom": true, + "folder": null, + "choreoAuto": false +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/New Path.path b/src/main/deploy/pathplanner/paths/NeutralD-NeutralMD.path similarity index 66% rename from src/main/deploy/pathplanner/paths/New Path.path rename to src/main/deploy/pathplanner/paths/NeutralD-NeutralMD.path index bb93d95..3bd1aae 100644 --- a/src/main/deploy/pathplanner/paths/New Path.path +++ b/src/main/deploy/pathplanner/paths/NeutralD-NeutralMD.path @@ -3,29 +3,29 @@ "waypoints": [ { "anchor": { - "x": 3.6, - "y": 0.6766148524443565 + "x": 7.442304680718316, + "y": 1.9429927967212826 }, "prevControl": null, "nextControl": { - "x": 4.6, - "y": 0.6766148524443567 + "x": 7.655103216100622, + "y": 2.416507084599248 }, "isLocked": false, - "linkedName": "TrenchDL" + "linkedName": "NeutralD" }, { "anchor": { - "x": 7.007, - "y": 6.631 + "x": 7.756220323350695, + "y": 3.3657628303810405 }, "prevControl": { - "x": 6.089196860397296, - "y": 6.233964237208511 + "x": 7.679015179669417, + "y": 2.412192166928892 }, "nextControl": null, "isLocked": false, - "linkedName": null + "linkedName": "NeutralMD" } ], "rotationTargets": [], @@ -42,13 +42,13 @@ }, "goalEndState": { "velocity": 0, - "rotation": 0.0 + "rotation": -98.11710595229022 }, "reversed": false, "folder": null, "idealStartingState": { "velocity": 0, - "rotation": -90.0 + "rotation": -110.47222947446986 }, "useDefaultConstraints": true } \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/NeutralMD-BumperDL.path b/src/main/deploy/pathplanner/paths/NeutralMD-BumperDL.path new file mode 100644 index 0000000..1d2bf0f --- /dev/null +++ b/src/main/deploy/pathplanner/paths/NeutralMD-BumperDL.path @@ -0,0 +1,75 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 7.756220323350695, + "y": 3.3657628303810405 + }, + "prevControl": null, + "nextControl": { + "x": 7.157829714174624, + "y": 2.495566750985605 + }, + "isLocked": false, + "linkedName": "NeutralMD" + }, + { + "anchor": { + "x": 5.874267289903429, + "y": 2.4661024961118345 + }, + "prevControl": { + "x": 6.124267289903429, + "y": 2.4661024961118345 + }, + "nextControl": { + "x": 5.624267289903429, + "y": 2.4661024961118345 + }, + "isLocked": false, + "linkedName": null + }, + { + "anchor": { + "x": 3.4309254246464485, + "y": 2.4661024961118345 + }, + "prevControl": { + "x": 4.312563365178831, + "y": 2.5058140914139555 + }, + "nextControl": null, + "isLocked": false, + "linkedName": null + } + ], + "rotationTargets": [ + { + "waypointRelativePos": 0.7649885751668688, + "rotationDegrees": 180.0 + } + ], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 180.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -98.117 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/NeutralM-BumpL.path b/src/main/deploy/pathplanner/paths/NeutralMU-BumpL.path similarity index 70% rename from src/main/deploy/pathplanner/paths/NeutralM-BumpL.path rename to src/main/deploy/pathplanner/paths/NeutralMU-BumpL.path index f1dea81..ebaa729 100644 --- a/src/main/deploy/pathplanner/paths/NeutralM-BumpL.path +++ b/src/main/deploy/pathplanner/paths/NeutralMU-BumpL.path @@ -3,28 +3,28 @@ "waypoints": [ { "anchor": { - "x": 7.733767772001379, - "y": 4.591418859242256 + "x": 7.7933333310727715, + "y": 5.253605946858724 }, "prevControl": null, "nextControl": { - "x": 6.493069507495777, - "y": 5.782383896868634 + "x": 7.1601158311631945, + "y": 5.61453717436614 }, "isLocked": false, "linkedName": "NeutralM" }, { "anchor": { - "x": 5.652266590500484, + "x": 5.905539935076678, "y": 5.654 }, "prevControl": { - "x": 5.402266590500484, + "x": 6.730088725999998, "y": 5.654 }, "nextControl": { - "x": 5.902266590500484, + "x": 5.655539935076681, "y": 5.654 }, "isLocked": false, @@ -36,15 +36,20 @@ "y": 5.654 }, "prevControl": { - "x": 3.391869822275747, - "y": 5.637191936939436 + "x": 2.892435484190245, + "y": 5.654 }, "nextControl": null, "isLocked": false, - "linkedName": "BumpL" + "linkedName": null + } + ], + "rotationTargets": [ + { + "waypointRelativePos": 0.9677713634898372, + "rotationDegrees": 180.0 } ], - "rotationTargets": [], "constraintZones": [], "pointTowardsZones": [], "eventMarkers": [], @@ -58,7 +63,7 @@ }, "goalEndState": { "velocity": 0, - "rotation": -90.0 + "rotation": 180.0 }, "reversed": false, "folder": null, diff --git a/src/main/deploy/pathplanner/paths/NeutralU-NeutralM.path b/src/main/deploy/pathplanner/paths/NeutralU-NeutralMU.path similarity index 74% rename from src/main/deploy/pathplanner/paths/NeutralU-NeutralM.path rename to src/main/deploy/pathplanner/paths/NeutralU-NeutralMU.path index 554ada7..7f5e230 100644 --- a/src/main/deploy/pathplanner/paths/NeutralU-NeutralM.path +++ b/src/main/deploy/pathplanner/paths/NeutralU-NeutralMU.path @@ -3,25 +3,25 @@ "waypoints": [ { "anchor": { - "x": 7.0069443142016095, - "y": 6.631213852438146 + "x": 7.203352146855107, + "y": 6.74392458654333 }, "prevControl": null, "nextControl": { - "x": 7.225329169697595, - "y": 6.509525500941392 + "x": 7.573420153582537, + "y": 6.307320836385092 }, "isLocked": false, "linkedName": "NeutralU" }, { "anchor": { - "x": 7.733767772001379, - "y": 4.591418859242256 + "x": 7.7933333310727715, + "y": 5.253605946858724 }, "prevControl": { - "x": 7.869332796469781, - "y": 5.879501338406852 + "x": 7.780415232340495, + "y": 6.116668418601708 }, "nextControl": null, "isLocked": false, @@ -42,7 +42,7 @@ }, "goalEndState": { "velocity": 0, - "rotation": 96.94434252981222 + "rotation": 96.94434252981223 }, "reversed": false, "folder": null, diff --git a/src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path b/src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path index 8127059..6e76f9f 100644 --- a/src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path +++ b/src/main/deploy/pathplanner/paths/Outpost-TrenchDL.path @@ -58,7 +58,7 @@ }, "goalEndState": { "velocity": 0, - "rotation": -90.0 + "rotation": 180.0 }, "reversed": false, "folder": null, diff --git a/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path b/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path new file mode 100644 index 0000000..1888a68 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path @@ -0,0 +1,75 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 3.6, + "y": 0.677 + }, + "prevControl": null, + "nextControl": { + "x": 4.6, + "y": 0.6770000000000003 + }, + "isLocked": false, + "linkedName": "TrenchDL" + }, + { + "anchor": { + "x": 6.192, + "y": 0.677 + }, + "prevControl": { + "x": 5.946161451913672, + "y": 0.6315752460127169 + }, + "nextControl": { + "x": 7.395477213541667, + "y": 0.8993721901222511 + }, + "isLocked": false, + "linkedName": null + }, + { + "anchor": { + "x": 7.442304680718316, + "y": 1.9429927967212826 + }, + "prevControl": { + "x": 7.168346877486617, + "y": 1.0319485224971072 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "NeutralD" + } + ], + "rotationTargets": [ + { + "waypointRelativePos": 0.7662643877047933, + "rotationDegrees": 180.0 + } + ], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": -110.47222947446986 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": 180.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path b/src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path index 80b3d4f..344e92c 100644 --- a/src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path +++ b/src/main/deploy/pathplanner/paths/TrenchUL-NeutralU.path @@ -4,40 +4,40 @@ { "anchor": { "x": 3.610745262546267, - "y": 7.389868890128567 + "y": 7.39 }, "prevControl": null, "nextControl": { "x": 4.144993723761676, - "y": 7.454781805381108 + "y": 7.454912915252541 }, "isLocked": false, "linkedName": "TrenchL" }, { "anchor": { - "x": 6.192141591664908, - "y": 7.389868890128567 + "x": 6.192, + "y": 7.39 }, "prevControl": { - "x": 5.952390083217673, - "y": 7.460715302862561 + "x": 5.952248027478147, + "y": 7.460844842239082 }, "nextControl": { - "x": 6.431893100112142, - "y": 7.319022477394573 + "x": 6.4317519725218535, + "y": 7.3191551577609175 }, "isLocked": false, "linkedName": null }, { "anchor": { - "x": 7.0069443142016095, - "y": 6.631213852438146 + "x": 7.203352146855107, + "y": 6.74392458654333 }, "prevControl": { - "x": 6.969006340429836, - "y": 6.878318506676167 + "x": 6.957989258942781, + "y": 6.9069793178417065 }, "nextControl": null, "isLocked": false, From 1c8ac9fa49766b6a4fb0c6a348f5b0b38830fc57 Mon Sep 17 00:00:00 2001 From: Daniel Tsur Date: Thu, 5 Feb 2026 20:05:06 +0200 Subject: [PATCH 3/6] Fixed some problems with the paths --- .../pathplanner/paths/Alliance-DepotD.path | 8 ++++---- .../pathplanner/paths/NeutralD-NeutralMD.path | 10 +++++----- .../pathplanner/paths/TrenchDL-NeutralD.path | 18 +++++++++--------- 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/main/deploy/pathplanner/paths/Alliance-DepotD.path b/src/main/deploy/pathplanner/paths/Alliance-DepotD.path index 92b0d42..e7ec5c2 100644 --- a/src/main/deploy/pathplanner/paths/Alliance-DepotD.path +++ b/src/main/deploy/pathplanner/paths/Alliance-DepotD.path @@ -8,8 +8,8 @@ }, "prevControl": null, "nextControl": { - "x": 1.9806970627243459, - "y": 4.699098054676632 + "x": 1.6108769536901408, + "y": 5.018044144807038 }, "isLocked": false, "linkedName": "Alliance" @@ -20,8 +20,8 @@ "y": 4.951 }, "prevControl": { - "x": 0.5879311285557767, - "y": 4.7245522223493905 + "x": 0.7216803717177473, + "y": 4.879913296508823 }, "nextControl": null, "isLocked": false, diff --git a/src/main/deploy/pathplanner/paths/NeutralD-NeutralMD.path b/src/main/deploy/pathplanner/paths/NeutralD-NeutralMD.path index 3bd1aae..94359e4 100644 --- a/src/main/deploy/pathplanner/paths/NeutralD-NeutralMD.path +++ b/src/main/deploy/pathplanner/paths/NeutralD-NeutralMD.path @@ -3,13 +3,13 @@ "waypoints": [ { "anchor": { - "x": 7.442304680718316, - "y": 1.9429927967212826 + "x": 7.293889555754486, + "y": 1.5788881722909434 }, "prevControl": null, "nextControl": { - "x": 7.655103216100622, - "y": 2.416507084599248 + "x": 7.506688091136792, + "y": 2.0524024601689086 }, "isLocked": false, "linkedName": "NeutralD" @@ -48,7 +48,7 @@ "folder": null, "idealStartingState": { "velocity": 0, - "rotation": -110.47222947446986 + "rotation": -110.47222947446987 }, "useDefaultConstraints": true } \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path b/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path index 1888a68..29f253e 100644 --- a/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path +++ b/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path @@ -20,24 +20,24 @@ "y": 0.677 }, "prevControl": { - "x": 5.946161451913672, - "y": 0.6315752460127169 + "x": 5.94223538895092, + "y": 0.6661538454971256 }, "nextControl": { - "x": 7.395477213541667, - "y": 0.8993721901222511 + "x": 6.87098866780599, + "y": 0.7064854261610243 }, "isLocked": false, "linkedName": null }, { "anchor": { - "x": 7.442304680718316, - "y": 1.9429927967212826 + "x": 7.293889555754486, + "y": 1.5788881722909434 }, "prevControl": { - "x": 7.168346877486617, - "y": 1.0319485224971072 + "x": 7.16190986915871, + "y": 1.0372516988118488 }, "nextControl": null, "isLocked": false, @@ -63,7 +63,7 @@ }, "goalEndState": { "velocity": 0, - "rotation": -110.47222947446986 + "rotation": -110.47222947446987 }, "reversed": false, "folder": null, From 38c1f62a5aab9647fa6f35d3aeaa3d35be6ec75b Mon Sep 17 00:00:00 2001 From: Daniel Tsur Date: Sun, 8 Feb 2026 19:12:03 +0200 Subject: [PATCH 4/6] Added climbing autos according to Ifergan's request --- .../deploy/pathplanner/autos/Depot-Climb.auto | 76 +++++++++++++++++++ .../autos/Depot-Trench-Neutral-Bump.auto | 2 +- .../pathplanner/autos/Outpost-Climb.auto | 50 ++++++++++++ .../pathplanner/paths/DepotU-Climb.path | 75 ++++++++++++++++++ .../pathplanner/paths/Outpost-Climb.path | 54 +++++++++++++ 5 files changed, 256 insertions(+), 1 deletion(-) create mode 100644 src/main/deploy/pathplanner/autos/Depot-Climb.auto create mode 100644 src/main/deploy/pathplanner/autos/Outpost-Climb.auto create mode 100644 src/main/deploy/pathplanner/paths/DepotU-Climb.path create mode 100644 src/main/deploy/pathplanner/paths/Outpost-Climb.path diff --git a/src/main/deploy/pathplanner/autos/Depot-Climb.auto b/src/main/deploy/pathplanner/autos/Depot-Climb.auto new file mode 100644 index 0000000..8a92899 --- /dev/null +++ b/src/main/deploy/pathplanner/autos/Depot-Climb.auto @@ -0,0 +1,76 @@ +{ + "version": "2025.0", + "command": { + "type": "sequential", + "data": { + "commands": [ + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "path", + "data": { + "pathName": "Alliance-DepotD" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + } + ] + } + }, + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "path", + "data": { + "pathName": "DepotD-DepotU" + } + }, + { + "type": "named", + "data": { + "name": "Intake.intake" + } + } + ] + } + }, + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + }, + { + "type": "path", + "data": { + "pathName": "DepotU-Climb" + } + } + ] + } + }, + { + "type": "named", + "data": { + "name": "Climber.climb" + } + } + ] + } + }, + "resetOdom": true, + "folder": null, + "choreoAuto": false +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto index 8863bfc..263531a 100644 --- a/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto +++ b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto @@ -17,7 +17,7 @@ } }, { - "type": "sequential", + "type": "deadline", "data": { "commands": [ { diff --git a/src/main/deploy/pathplanner/autos/Outpost-Climb.auto b/src/main/deploy/pathplanner/autos/Outpost-Climb.auto new file mode 100644 index 0000000..9d1d9d2 --- /dev/null +++ b/src/main/deploy/pathplanner/autos/Outpost-Climb.auto @@ -0,0 +1,50 @@ +{ + "version": "2025.0", + "command": { + "type": "sequential", + "data": { + "commands": [ + { + "type": "deadline", + "data": { + "commands": [ + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + }, + { + "type": "path", + "data": { + "pathName": "Alliance-Outpost" + } + } + ] + } + }, + { + "type": "path", + "data": { + "pathName": "Outpost-Climb" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + }, + { + "type": "named", + "data": { + "name": "Climber.climb" + } + } + ] + } + }, + "resetOdom": true, + "folder": null, + "choreoAuto": false +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/DepotU-Climb.path b/src/main/deploy/pathplanner/paths/DepotU-Climb.path new file mode 100644 index 0000000..86b8a8d --- /dev/null +++ b/src/main/deploy/pathplanner/paths/DepotU-Climb.path @@ -0,0 +1,75 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 0.482, + "y": 6.51 + }, + "prevControl": null, + "nextControl": { + "x": 1.9836971313090879, + "y": 6.594117147195584 + }, + "isLocked": false, + "linkedName": "DepotU" + }, + { + "anchor": { + "x": 1.9150188789548475, + "y": 4.994547914622519 + }, + "prevControl": { + "x": 1.8713712652231864, + "y": 5.535179507711039 + }, + "nextControl": { + "x": 1.9467514148971299, + "y": 4.601499818919395 + }, + "isLocked": false, + "linkedName": null + }, + { + "anchor": { + "x": 1.812909969457193, + "y": 3.7744484270396033 + }, + "prevControl": { + "x": 2.110974033349687, + "y": 4.120037984019396 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "Climb" + } + ], + "rotationTargets": [ + { + "waypointRelativePos": 0.5, + "rotationDegrees": -90.0 + } + ], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 0.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": -90.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Outpost-Climb.path b/src/main/deploy/pathplanner/paths/Outpost-Climb.path new file mode 100644 index 0000000..077b028 --- /dev/null +++ b/src/main/deploy/pathplanner/paths/Outpost-Climb.path @@ -0,0 +1,54 @@ +{ + "version": "2025.0", + "waypoints": [ + { + "anchor": { + "x": 0.5, + "y": 0.6766148524443565 + }, + "prevControl": null, + "nextControl": { + "x": 1.5450037532282108, + "y": 0.6894989351149048 + }, + "isLocked": false, + "linkedName": "Outpost" + }, + { + "anchor": { + "x": 1.812909969457193, + "y": 3.7744484270396033 + }, + "prevControl": { + "x": 2.1167587309200058, + "y": 3.2763672386036866 + }, + "nextControl": null, + "isLocked": false, + "linkedName": "Climb" + } + ], + "rotationTargets": [], + "constraintZones": [], + "pointTowardsZones": [], + "eventMarkers": [], + "globalConstraints": { + "maxVelocity": 3.0, + "maxAcceleration": 3.0, + "maxAngularVelocity": 540.0, + "maxAngularAcceleration": 720.0, + "nominalVoltage": 12.0, + "unlimited": false + }, + "goalEndState": { + "velocity": 0, + "rotation": 0.0 + }, + "reversed": false, + "folder": null, + "idealStartingState": { + "velocity": 0, + "rotation": 0.0 + }, + "useDefaultConstraints": true +} \ No newline at end of file From 272753fb3fbd8b8d9481ede2d3441f759d98a9f9 Mon Sep 17 00:00:00 2001 From: Daniel Tsur Date: Tue, 17 Feb 2026 18:48:07 +0200 Subject: [PATCH 5/6] Fixed the autos to have the wait command when going to the outpost Changed the starting position to be legal (on the starting line) --- .../autos/Depot-Trench-Neutral-Bump.auto | 23 ++++++---- .../pathplanner/autos/Outpost-Climb.auto | 6 +++ .../autos/Outpost-Trench-Neutral-Bump.auto | 23 +++++++--- .../pathplanner/paths/Alliance-Climb.path | 16 +++---- .../pathplanner/paths/Alliance-DepotD.path | 43 +++++++++++++++---- .../pathplanner/paths/Alliance-Outpost.path | 16 +++---- .../pathplanner/paths/Alliance-TrenchUL.path | 2 +- .../pathplanner/paths/TrenchDL-NeutralD.path | 4 +- 8 files changed, 92 insertions(+), 41 deletions(-) diff --git a/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto index 263531a..994150d 100644 --- a/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto +++ b/src/main/deploy/pathplanner/autos/Depot-Trench-Neutral-Bump.auto @@ -36,15 +36,22 @@ } }, { - "type": "path", - "data": { - "pathName": "DepotU-TrenchUL" - } - }, - { - "type": "named", + "type": "deadline", "data": { - "name": "Shooter.shoot" + "commands": [ + { + "type": "path", + "data": { + "pathName": "DepotU-TrenchUL" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + } + ] } }, { diff --git a/src/main/deploy/pathplanner/autos/Outpost-Climb.auto b/src/main/deploy/pathplanner/autos/Outpost-Climb.auto index 9d1d9d2..b8b6010 100644 --- a/src/main/deploy/pathplanner/autos/Outpost-Climb.auto +++ b/src/main/deploy/pathplanner/autos/Outpost-Climb.auto @@ -29,6 +29,12 @@ "pathName": "Outpost-Climb" } }, + { + "type": "wait", + "data": { + "waitTime": 2.0 + } + }, { "type": "named", "data": { diff --git a/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto b/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto index 02a15c8..832429d 100644 --- a/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto +++ b/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto @@ -11,21 +11,34 @@ } }, { - "type": "path", + "type": "wait", "data": { - "pathName": "Alliance-Outpost" + "waitTime": 2.0 } }, { "type": "path", "data": { - "pathName": "Outpost-TrenchDL" + "pathName": "Alliance-Outpost" } }, { - "type": "named", + "type": "parallel", "data": { - "name": "Shooter.shoot" + "commands": [ + { + "type": "path", + "data": { + "pathName": "Outpost-TrenchDL" + } + }, + { + "type": "named", + "data": { + "name": "Shooter.shoot" + } + } + ] } }, { diff --git a/src/main/deploy/pathplanner/paths/Alliance-Climb.path b/src/main/deploy/pathplanner/paths/Alliance-Climb.path index 6fe8acd..a23aa5a 100644 --- a/src/main/deploy/pathplanner/paths/Alliance-Climb.path +++ b/src/main/deploy/pathplanner/paths/Alliance-Climb.path @@ -3,16 +3,16 @@ "waypoints": [ { "anchor": { - "x": 2.230697062724346, - "y": 4.699098054676632 + "x": 3.531310051812067, + "y": 3.7744484270396033 }, "prevControl": null, "nextControl": { - "x": 2.2353915259659463, - "y": 4.449142134532953 + "x": 3.281310051812067, + "y": 3.7744484270396033 }, "isLocked": false, - "linkedName": "Alliance" + "linkedName": "AllianceM" }, { "anchor": { @@ -20,8 +20,8 @@ "y": 3.7744484270396033 }, "prevControl": { - "x": 2.0559676755271257, - "y": 3.8329544226299883 + "x": 2.062909969457193, + "y": 3.7744484270396033 }, "nextControl": null, "isLocked": false, @@ -48,7 +48,7 @@ "folder": null, "idealStartingState": { "velocity": 0, - "rotation": -90.0 + "rotation": 0.0 }, "useDefaultConstraints": true } \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Alliance-DepotD.path b/src/main/deploy/pathplanner/paths/Alliance-DepotD.path index e7ec5c2..51d6d85 100644 --- a/src/main/deploy/pathplanner/paths/Alliance-DepotD.path +++ b/src/main/deploy/pathplanner/paths/Alliance-DepotD.path @@ -3,16 +3,32 @@ "waypoints": [ { "anchor": { - "x": 2.230697062724346, - "y": 4.699098054676632 + "x": 3.531310051812067, + "y": 3.7744484270396033 }, "prevControl": null, "nextControl": { - "x": 1.6108769536901408, - "y": 5.018044144807038 + "x": 2.816114611417779, + "y": 4.489643867433892 }, "isLocked": false, - "linkedName": "Alliance" + "linkedName": "AllianceM" + }, + { + "anchor": { + "x": 1.7500771306355798, + "y": 4.951 + }, + "prevControl": { + "x": 2.1500771306355797, + "y": 4.951 + }, + "nextControl": { + "x": 1.5000771306355798, + "y": 4.951 + }, + "isLocked": false, + "linkedName": null }, { "anchor": { @@ -20,15 +36,24 @@ "y": 4.951 }, "prevControl": { - "x": 0.7216803717177473, - "y": 4.879913296508823 + "x": 0.732, + "y": 4.951 }, "nextControl": null, "isLocked": false, "linkedName": "DepotD" } ], - "rotationTargets": [], + "rotationTargets": [ + { + "waypointRelativePos": 0.15, + "rotationDegrees": 0.0 + }, + { + "waypointRelativePos": 0.95, + "rotationDegrees": -90.0 + } + ], "constraintZones": [], "pointTowardsZones": [], "eventMarkers": [], @@ -48,7 +73,7 @@ "folder": null, "idealStartingState": { "velocity": 0, - "rotation": -90.0 + "rotation": 0.0 }, "useDefaultConstraints": true } \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Alliance-Outpost.path b/src/main/deploy/pathplanner/paths/Alliance-Outpost.path index 5ab510e..12b3acc 100644 --- a/src/main/deploy/pathplanner/paths/Alliance-Outpost.path +++ b/src/main/deploy/pathplanner/paths/Alliance-Outpost.path @@ -3,16 +3,16 @@ "waypoints": [ { "anchor": { - "x": 2.230697062724346, - "y": 4.699098054676632 + "x": 3.6, + "y": 0.6766148524443565 }, "prevControl": null, "nextControl": { - "x": 1.9890863260359186, - "y": 2.902645853645024 + "x": 2.5509742132116244, + "y": 0.7606059140889831 }, "isLocked": false, - "linkedName": "Alliance" + "linkedName": "AllianceD" }, { "anchor": { @@ -20,8 +20,8 @@ "y": 0.6766148524443565 }, "prevControl": { - "x": 2.3019494066170747, - "y": 1.0862829356949055 + "x": 1.4940456113409608, + "y": 0.834401360414214 }, "nextControl": null, "isLocked": false, @@ -48,7 +48,7 @@ "folder": null, "idealStartingState": { "velocity": 0, - "rotation": -90.0 + "rotation": 0.0 }, "useDefaultConstraints": true } \ No newline at end of file diff --git a/src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path b/src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path index bdc3487..a891022 100644 --- a/src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path +++ b/src/main/deploy/pathplanner/paths/Alliance-TrenchUL.path @@ -12,7 +12,7 @@ "y": 4.948755970677763 }, "isLocked": false, - "linkedName": "Alliance" + "linkedName": null }, { "anchor": { diff --git a/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path b/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path index 29f253e..9b32d8d 100644 --- a/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path +++ b/src/main/deploy/pathplanner/paths/TrenchDL-NeutralD.path @@ -20,8 +20,8 @@ "y": 0.677 }, "prevControl": { - "x": 5.94223538895092, - "y": 0.6661538454971256 + "x": 5.942235388950917, + "y": 0.6661538454971255 }, "nextControl": { "x": 6.87098866780599, From f5d9679f05cbcd3fa9462bc7d79a6dcb8af9ad4c Mon Sep 17 00:00:00 2001 From: Daniel Tsur Date: Tue, 17 Feb 2026 19:33:28 +0200 Subject: [PATCH 6/6] Fixed some logical mistakes with the autos --- .../deploy/pathplanner/autos/Depot-Climb.auto | 8 +++--- .../autos/Outpost-Trench-Neutral-Bump.auto | 27 ++++++++++++------- 2 files changed, 21 insertions(+), 14 deletions(-) diff --git a/src/main/deploy/pathplanner/autos/Depot-Climb.auto b/src/main/deploy/pathplanner/autos/Depot-Climb.auto index 8a92899..a4efee2 100644 --- a/src/main/deploy/pathplanner/autos/Depot-Climb.auto +++ b/src/main/deploy/pathplanner/autos/Depot-Climb.auto @@ -47,15 +47,15 @@ "data": { "commands": [ { - "type": "named", + "type": "path", "data": { - "name": "Shooter.shoot" + "pathName": "DepotU-Climb" } }, { - "type": "path", + "type": "named", "data": { - "pathName": "DepotU-Climb" + "name": "Shooter.shoot" } } ] diff --git a/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto b/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto index 832429d..7e3e855 100644 --- a/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto +++ b/src/main/deploy/pathplanner/autos/Outpost-Trench-Neutral-Bump.auto @@ -10,12 +10,6 @@ "name": "Shooter.shoot" } }, - { - "type": "wait", - "data": { - "waitTime": 2.0 - } - }, { "type": "path", "data": { @@ -27,15 +21,28 @@ "data": { "commands": [ { - "type": "path", + "type": "named", "data": { - "pathName": "Outpost-TrenchDL" + "name": "Shooter.shoot" } }, { - "type": "named", + "type": "sequential", "data": { - "name": "Shooter.shoot" + "commands": [ + { + "type": "wait", + "data": { + "waitTime": 2.0 + } + }, + { + "type": "path", + "data": { + "pathName": "Outpost-TrenchDL" + } + } + ] } } ]