driver control updates + autonomous paths.

This commit is contained in:
Tyler-J42 2024-03-12 14:29:29 -04:00
parent 1754ee43a4
commit 5496d9177e
12 changed files with 372 additions and 130 deletions

View File

@ -0,0 +1,79 @@
{
"version": 1.0,
"startingPose": {
"position": {
"x": 0.4936438362905214,
"y": 6.981410202136645
},
"rotation": 180.0
},
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "path",
"data": {
"pathName": "Left Subwoofer"
}
},
{
"type": "named",
"data": {
"name": "Charge Shooter"
}
},
{
"type": "named",
"data": {
"name": "Speaker Note Shot"
}
},
{
"type": "path",
"data": {
"pathName": "L Sub to Note 1"
}
},
{
"type": "path",
"data": {
"pathName": "Note 1 to Speaker"
}
},
{
"type": "named",
"data": {
"name": "Charge Shooter"
}
},
{
"type": "named",
"data": {
"name": "Speaker Note Shot"
}
},
{
"type": "path",
"data": {
"pathName": "L Sub to Note 2"
}
},
{
"type": "named",
"data": {
"name": "Charge Shooter"
}
},
{
"type": "named",
"data": {
"name": "Speaker Note Shot"
}
}
]
}
},
"folder": null,
"choreoAuto": false
}

View File

@ -32,7 +32,7 @@
{
"type": "path",
"data": {
"pathName": "L Sub to Center"
"pathName": "L Sub to Note 1"
}
},
{

View File

@ -1,50 +0,0 @@
{
"version": 1.0,
"startingPose": null,
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "Speaker Note Shot"
}
},
{
"type": "path",
"data": {
"pathName": "Left Preloaded+Pickup"
}
},
{
"type": "deadline",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "Amp Handoff"
}
},
{
"type": "path",
"data": {
"pathName": "Note 1 to amp"
}
}
]
}
},
{
"type": "named",
"data": {
"name": "Amp Note Shot"
}
}
]
}
},
"folder": null,
"choreoAuto": false
}

View File

@ -2,41 +2,47 @@
"version": 1.0,
"startingPose": {
"position": {
"x": 1.1134340217398382,
"y": 6.525338178881486
"x": 0.4936438362905214,
"y": 4.092954054853979
},
"rotation": 42.79740183823424
"rotation": 180.0
},
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "path",
"data": {
"pathName": "Right Wall to Sub"
}
},
{
"type": "named",
"data": {
"name": "Charge Shooter"
}
},
{
"type": "named",
"data": {
"name": "Speaker Note Shot"
}
},
{
"type": "path",
"data": {
"pathName": "Left Preloaded+Pickup"
}
},
{
"type": "parallel",
"data": {
"commands": [
{
"type": "wait",
"type": "named",
"data": {
"waitTime": 2.0
"name": "Auto Intake"
}
},
{
"type": "named",
"type": "path",
"data": {
"name": "Amp Handoff"
"pathName": "Right Sub Note 3"
}
}
]
@ -45,25 +51,19 @@
{
"type": "path",
"data": {
"pathName": "Note 1 to amp"
"pathName": "Note 3 to Sub"
}
},
{
"type": "named",
"data": {
"name": "Amp Note Shot"
"name": "Charge Shooter"
}
},
{
"type": "path",
"type": "named",
"data": {
"pathName": "Leftmost Center Note"
}
},
{
"type": "path",
"data": {
"pathName": "Note 1 to amp"
"name": "Speaker Note Shot"
}
}
]

View File

@ -1,43 +0,0 @@
{
"version": 1.0,
"startingPose": {
"position": {
"x": 1.1134340217398382,
"y": 6.525338178881486
},
"rotation": 33.13560954871888
},
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "path",
"data": {
"pathName": "Left Preloaded+Pickup"
}
},
{
"type": "path",
"data": {
"pathName": "Note 1 to amp"
}
},
{
"type": "path",
"data": {
"pathName": "Leftmost Center Note"
}
},
{
"type": "path",
"data": {
"pathName": "Note 1 to amp"
}
}
]
}
},
"folder": null,
"choreoAuto": false
}

View File

@ -3,12 +3,12 @@
"waypoints": [
{
"anchor": {
"x": 1.1251281761822782,
"x": 1.0900457128549583,
"y": 6.560420642208806
},
"prevControl": null,
"nextControl": {
"x": 1.569506044994996,
"x": 1.5344235816676761,
"y": 7.098351746561042
},
"isLocked": false,

View File

@ -0,0 +1,92 @@
{
"version": 1.0,
"waypoints": [
{
"anchor": {
"x": 1.0900457128549583,
"y": 6.548726487766366
},
"prevControl": null,
"nextControl": {
"x": 1.4993411183403562,
"y": 6.490255715554167
},
"isLocked": false,
"linkedName": null
},
{
"anchor": {
"x": 2.247767002656512,
"y": 5.87046553010485
},
"prevControl": {
"x": 1.8852482149408738,
"y": 6.256372626705368
},
"nextControl": {
"x": 2.61028579037215,
"y": 5.484558433504332
},
"isLocked": false,
"linkedName": null
},
{
"anchor": {
"x": 1.0900457128549583,
"y": 6.548726487766366
},
"prevControl": {
"x": 2.095742994904793,
"y": 6.805997885500045
},
"nextControl": null,
"isLocked": false,
"linkedName": null
}
],
"rotationTargets": [
{
"waypointRelativePos": 1.1,
"rotationDegrees": 157.35591349901955,
"rotateFast": true
}
],
"constraintZones": [],
"eventMarkers": [
{
"name": "New Event Marker",
"waypointRelativePos": 0.1,
"command": {
"type": "parallel",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "Auto Intake"
}
}
]
}
}
}
],
"globalConstraints": {
"maxVelocity": 3.0,
"maxAcceleration": 3.0,
"maxAngularVelocity": 540.0,
"maxAngularAcceleration": 720.0
},
"goalEndState": {
"velocity": 0,
"rotation": -153.43494882292208,
"rotateFast": false
},
"reversed": false,
"folder": null,
"previewStartingState": {
"rotation": -148.523160650416,
"velocity": 0
},
"useDefaultConstraints": true
}

View File

@ -16,12 +16,12 @@
},
{
"anchor": {
"x": 1.2654580294915574,
"y": 6.291455090032687
"x": 1.136822330624718,
"y": 6.478561561111727
},
"prevControl": {
"x": 1.7098358983042754,
"y": 6.525338178881486
"x": 1.581200199437436,
"y": 6.712444649960526
},
"nextControl": null,
"isLocked": false,

View File

@ -0,0 +1,52 @@
{
"version": 1.0,
"waypoints": [
{
"anchor": {
"x": 2.2360728482140724,
"y": 4.139730672623739
},
"prevControl": null,
"nextControl": {
"x": 1.8501657516135543,
"y": 3.940930047102261
},
"isLocked": false,
"linkedName": null
},
{
"anchor": {
"x": 0.9380217051032389,
"y": 4.4671669970120575
},
"prevControl": {
"x": 1.6162826627647555,
"y": 3.730435267138341
},
"nextControl": null,
"isLocked": false,
"linkedName": null
}
],
"rotationTargets": [],
"constraintZones": [],
"eventMarkers": [],
"globalConstraints": {
"maxVelocity": 3.0,
"maxAcceleration": 3.0,
"maxAngularVelocity": 540.0,
"maxAngularAcceleration": 720.0
},
"goalEndState": {
"velocity": 0,
"rotation": 132.43622978853497,
"rotateFast": false
},
"reversed": false,
"folder": null,
"previewStartingState": {
"rotation": -1.5911402711946612,
"velocity": 0
},
"useDefaultConstraints": true
}

View File

@ -0,0 +1,58 @@
{
"version": 1.0,
"waypoints": [
{
"anchor": {
"x": 1.0666574039700785,
"y": 4.373613761472538
},
"prevControl": null,
"nextControl": {
"x": 1.5344235816676757,
"y": 4.338531298145218
},
"isLocked": false,
"linkedName": null
},
{
"anchor": {
"x": 2.282849465983832,
"y": 4.139730672623739
},
"prevControl": {
"x": 1.7210430076110608,
"y": 4.139730672623739
},
"nextControl": null,
"isLocked": false,
"linkedName": null
}
],
"rotationTargets": [
{
"waypointRelativePos": 1.0,
"rotationDegrees": 180.0,
"rotateFast": true
}
],
"constraintZones": [],
"eventMarkers": [],
"globalConstraints": {
"maxVelocity": 3.0,
"maxAcceleration": 3.0,
"maxAngularVelocity": 540.0,
"maxAngularAcceleration": 720.0
},
"goalEndState": {
"velocity": 0,
"rotation": 180.0,
"rotateFast": false
},
"reversed": false,
"folder": null,
"previewStartingState": {
"rotation": 131.18592516570968,
"velocity": 0
},
"useDefaultConstraints": true
}

View File

@ -0,0 +1,52 @@
{
"version": 1.0,
"waypoints": [
{
"anchor": {
"x": 0.4936438362905214,
"y": 4.092954054853979
},
"prevControl": null,
"nextControl": {
"x": 1.359011265031077,
"y": 4.034483282641779
},
"isLocked": false,
"linkedName": null
},
{
"anchor": {
"x": 1.0198807862003185,
"y": 4.502249460339376
},
"prevControl": {
"x": 1.0315749406427583,
"y": 4.116342363738859
},
"nextControl": null,
"isLocked": false,
"linkedName": null
}
],
"rotationTargets": [],
"constraintZones": [],
"eventMarkers": [],
"globalConstraints": {
"maxVelocity": 3.0,
"maxAcceleration": 3.0,
"maxAngularVelocity": 540.0,
"maxAngularAcceleration": 720.0
},
"goalEndState": {
"velocity": 0,
"rotation": 141.34019174590983,
"rotateFast": false
},
"reversed": false,
"folder": null,
"previewStartingState": {
"rotation": 180.0,
"velocity": 0
},
"useDefaultConstraints": true
}

View File

@ -194,13 +194,13 @@ public class RobotContainer {
)
);
driver.leftTrigger().onTrue(
driver.leftTrigger().onTrue(Commands.parallel(
new InstantCommand(
() -> {
intakeDown = true;
}
)
);
), indexer.advanceNote()
));
shooter.setDefaultCommand(
shooter.angleSpeedsSetpoints(
@ -214,8 +214,10 @@ public class RobotContainer {
() -> {
if(driver.getRightTriggerAxis() > 0.25){
return 1.0;
} else {
return 0;
} else if(operator.getRightTriggerAxis() > 0.25){
return -1.0;
}else{
return 0.0;
}
}
)
@ -240,7 +242,7 @@ public class RobotContainer {
indexer.setDefaultCommand(indexer.shootNote(
() -> {
if (driver.getLeftTriggerAxis() > .25) {
if (driver.getRightTriggerAxis() > .25) {
return -1.0;
}else {
return 0.0;
@ -354,7 +356,7 @@ public class RobotContainer {
//operator.povDown().whileTrue(intake.intakeDownCommand());
//operator.povUp().whileTrue(intake.intakeUpCommand());
driver.leftTrigger().whileTrue(Commands.parallel( intake.manualPivot(() -> 0.0, () -> 1.0), indexer.advanceNote()));
//driver.leftTrigger().whileTrue(Commands.parallel( intake.manualPivot(() -> 0.0, () -> 1.0), indexer.advanceNote()));
}