two peice auto right

This commit is contained in:
Tylr-J42 2025-03-21 00:25:18 -04:00
parent 3e6fa986e7
commit 17143ffffb
5 changed files with 128 additions and 36 deletions

View File

@ -0,0 +1,49 @@
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "path",
"data": {
"pathName": "Right Start to E"
}
},
{
"type": "named",
"data": {
"name": "Shoot Coral L4"
}
},
{
"type": "named",
"data": {
"name": "HP Pickup"
}
},
{
"type": "path",
"data": {
"pathName": "E to HP"
}
},
{
"type": "named",
"data": {
"name": "Collect Coral"
}
},
{
"type": "path",
"data": {
"pathName": "HP to D"
}
}
]
}
},
"resetOdom": true,
"folder": null,
"choreoAuto": false
}

View File

@ -3,35 +3,54 @@
"waypoints": [
{
"anchor": {
"x": 5.289041095890411,
"y": 2.9732020547945206
"x": 4.958476027397261,
"y": 2.837970890410959
},
"prevControl": null,
"nextControl": {
"x": 5.950171232876712,
"y": 1.6208904109589037
"x": 5.619606164383562,
"y": 1.455607876712329
},
"isLocked": false,
"linkedName": null
"linkedName": "E"
},
{
"anchor": {
"x": 1.4424657534246574,
"y": 0.7944777397260271
"x": 1.1569777397260272,
"y": 1.0198630136986298
},
"prevControl": {
"x": 2.389083904109589,
"y": 2.5374571917808213
"x": 2.7647260273972605,
"y": 1.485659246575342
},
"nextControl": null,
"isLocked": false,
"linkedName": null
"linkedName": "Right HP"
}
],
"rotationTargets": [],
"constraintZones": [],
"pointTowardsZones": [],
"eventMarkers": [],
"eventMarkers": [
{
"name": "HP Pickup",
"waypointRelativePos": 0.22857142857142831,
"endWaypointRelativePos": null,
"command": {
"type": "parallel",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "HP Pickup"
}
}
]
}
}
}
],
"globalConstraints": {
"maxVelocity": 4.0,
"maxAcceleration": 2.5,
@ -48,7 +67,7 @@
"folder": null,
"idealStartingState": {
"velocity": 0,
"rotation": 120.96375653207336
"rotation": 120.25643716352937
},
"useDefaultConstraints": true
}

View File

@ -3,25 +3,25 @@
"waypoints": [
{
"anchor": {
"x": 2.5773565573770494,
"y": 6.506454918032786
"x": 1.187029109589041,
"y": 0.9747859589041092
},
"prevControl": null,
"nextControl": {
"x": 3.5773565573770494,
"y": 6.506454918032786
"x": 2.268878424657535,
"y": 1.0949914383561645
},
"isLocked": false,
"linkedName": null
},
{
"anchor": {
"x": 7.060758196721312,
"y": 6.506454918032786
"x": 4.011857876712329,
"y": 2.837970890410959
},
"prevControl": {
"x": 6.060758196721312,
"y": 6.506454918032786
"x": 3.3657534246575342,
"y": 1.9364297945205475
},
"nextControl": null,
"isLocked": false,
@ -34,9 +34,21 @@
"eventMarkers": [
{
"name": "Lift L4",
"waypointRelativePos": 0.351851851851855,
"waypointRelativePos": 0.27142857142857096,
"endWaypointRelativePos": null,
"command": null
"command": {
"type": "parallel",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "Lift L4"
}
}
]
}
}
}
],
"globalConstraints": {
@ -49,13 +61,13 @@
},
"goalEndState": {
"velocity": 0,
"rotation": 90.0
"rotation": 58.57043438516136
},
"reversed": false,
"folder": null,
"idealStartingState": {
"velocity": 0,
"rotation": -90.0
"rotation": 54.24611274556325
},
"useDefaultConstraints": true
}

View File

@ -3,29 +3,29 @@
"waypoints": [
{
"anchor": {
"x": 7.602996575342465,
"y": 2.0115582191780823
"x": 7.572945205479453,
"y": 0.4939640410958907
},
"prevControl": null,
"nextControl": {
"x": 6.491095890410959,
"y": 1.9965325342465756
"x": 6.461044520547946,
"y": 0.478938356164384
},
"isLocked": false,
"linkedName": null
},
{
"anchor": {
"x": 5.289041095890411,
"y": 2.9882277397260277
"x": 4.958476027397261,
"y": 2.837970890410959
},
"prevControl": {
"x": 6.130479452054795,
"y": 2.11673801369863
"x": 5.799914383561644,
"y": 1.9664811643835614
},
"nextControl": null,
"isLocked": false,
"linkedName": null
"linkedName": "E"
}
],
"rotationTargets": [],
@ -34,9 +34,21 @@
"eventMarkers": [
{
"name": "Lift L4",
"waypointRelativePos": 0.7142857142857124,
"waypointRelativePos": 0.4261904761904757,
"endWaypointRelativePos": null,
"command": null
"command": {
"type": "parallel",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "Lift L4"
}
}
]
}
}
}
],
"globalConstraints": {

View File

@ -237,7 +237,7 @@ public class RobotContainer {
new EventTrigger("HP Pickup").onTrue(safeMoveManipulator(ElevatorConstants.kL4Position, ManipulatorPivotConstants.kL4Position));
NamedCommands.registerCommand("Drivetrain Set X", drivetrain.setXCommand());
NamedCommands.registerCommand("Shoot Coral L4", Commands.race(manipulator.runManipulator(() -> 0.4, true).withTimeout(3).andThen(manipulator.runUntilCollected(() -> 0.0).withTimeout(0.1)), Commands.parallel(elevator.maintainPosition(), manipulatorPivot.maintainPosition())));
NamedCommands.registerCommand("Shoot Coral L4", Commands.race(manipulator.runManipulator(() -> 0.4, true).withTimeout(1).andThen(manipulator.runUntilCollected(() -> 0.0).withTimeout(0.1)), Commands.parallel(elevator.maintainPosition(), manipulatorPivot.maintainPosition())));
NamedCommands.registerCommand("Collect Coral", manipulator.runUntilCollected(() -> 0.30).andThen(manipulator.runUntilCollected(() -> 0)).withTimeout(0.5));
NamedCommands.registerCommand("Lift L4", safeMoveManipulator(ElevatorConstants.kL4Position, ManipulatorPivotConstants.kL4Position));
NamedCommands.registerCommand("HP Pickup", safeMoveManipulator(ElevatorConstants.kCoralIntakePosition, ManipulatorPivotConstants.kStartingPosition));