Skip to content

Dcmp tweaks #73

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 19 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 24 additions & 18 deletions src/main/deploy/pathplanner/autos/0 - L.auto
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "path",
"data": {
"pathName": "Mobility Left"
}
}
]
}
},
"resetOdom": true,
"folder": null,
"choreoAuto": true
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
"pathName": "Mobility Left"
}
}
]
}
},
"resetOdom": true,
"folder": null,
"choreoAuto": true
}
42 changes: 24 additions & 18 deletions src/main/deploy/pathplanner/autos/0 - M.auto
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "path",
"data": {
"pathName": "Mobility Center"
}
}
]
}
},
"resetOdom": true,
"folder": null,
"choreoAuto": true
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
"pathName": "Mobility Center"
}
}
]
}
},
"resetOdom": true,
"folder": null,
"choreoAuto": true
}
42 changes: 24 additions & 18 deletions src/main/deploy/pathplanner/autos/0 - R.auto
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "path",
"data": {
"pathName": "Mobility Right"
}
}
]
}
},
"resetOdom": true,
"folder": null,
"choreoAuto": true
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
"pathName": "Mobility Right"
}
}
]
}
},
"resetOdom": true,
"folder": null,
"choreoAuto": true
}
12 changes: 12 additions & 0 deletions src/main/deploy/pathplanner/autos/1 - L.auto
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
Expand All @@ -15,6 +21,12 @@
"data": {
"name": "AutoPlaceRight4"
}
},
{
"type": "named",
"data": {
"name": "ArmToStow"
}
}
]
}
Expand Down
12 changes: 12 additions & 0 deletions src/main/deploy/pathplanner/autos/1 - M PoleL.auto
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
Expand All @@ -15,6 +21,12 @@
"data": {
"name": "AutoPlaceLeft4"
}
},
{
"type": "named",
"data": {
"name": "ArmToStow"
}
}
]
}
Expand Down
12 changes: 12 additions & 0 deletions src/main/deploy/pathplanner/autos/1 - M PoleR.auto
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
Expand All @@ -15,6 +21,12 @@
"data": {
"name": "AutoPlaceRight4"
}
},
{
"type": "named",
"data": {
"name": "ArmToStow"
}
}
]
}
Expand Down
12 changes: 12 additions & 0 deletions src/main/deploy/pathplanner/autos/1 - R.auto
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
Expand All @@ -15,6 +21,12 @@
"data": {
"name": "AutoPlaceLeft4"
}
},
{
"type": "named",
"data": {
"name": "ArmToStow"
}
}
]
}
Expand Down
12 changes: 12 additions & 0 deletions src/main/deploy/pathplanner/autos/2 - L.auto
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
Expand Down Expand Up @@ -52,6 +58,12 @@
"data": {
"name": "AutoPlaceLeft4"
}
},
{
"type": "named",
"data": {
"name": "ArmToStow"
}
}
]
}
Expand Down
12 changes: 12 additions & 0 deletions src/main/deploy/pathplanner/autos/2 - R.auto
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "ZeroWrist"
}
},
{
"type": "path",
"data": {
Expand Down Expand Up @@ -64,6 +70,12 @@
"data": {
"name": "AutoPlaceRight4"
}
},
{
"type": "named",
"data": {
"name": "ArmToStow"
}
}
]
}
Expand Down
25 changes: 25 additions & 0 deletions src/main/deploy/pathplanner/autos/Pit Test.auto
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"version": "2025.0",
"command": {
"type": "sequential",
"data": {
"commands": [
{
"type": "named",
"data": {
"name": "TestPlaceReefImmobile"
}
},
{
"type": "named",
"data": {
"name": "ArmToStow"
}
}
]
}
},
"resetOdom": false,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What was the reasoning behind this change? I feel like it shouldn't matter either way.

"folder": null,
"choreoAuto": true
}
8 changes: 0 additions & 8 deletions src/main/java/frc/robot/Robot.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,6 @@ public class Robot extends LoggedRobot {

@Override
public void robotInit() {

Logger.addDataReceiver(new WPILOGWriter("U/logs"));
Logger.addDataReceiver(new NT4Publisher());

Logger.start();

m_robotContainer = new RobotContainer();

// Set up data receivers & replay source
Expand Down Expand Up @@ -93,8 +87,6 @@ public void teleopInit() {
if (m_autonomousCommand != null) {
m_autonomousCommand.cancel();
}

m_robotContainer.zeroArm().schedule();
}

@Override
Expand Down
13 changes: 10 additions & 3 deletions src/main/java/frc/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,16 @@ private void configureBindings() {

backupController.povDown().onTrue(zeroArm());

backupController.leftBumper().whileTrue(intake.ejectCoralCommand());
backupController.leftBumper().whileTrue(intake.runEjectCommand());

backupController.rightBumper().whileTrue(intake.intakeCoralCommand());

backupController.start().whileTrue(CompoundCommands.armToNet());

backupController.x().whileTrue(intake.intakeAlgaeCommand());

backupController.y().whileTrue(intake.ejectAlgaeCommand());

backupController
.povUp()
.onTrue(
Expand Down Expand Up @@ -198,8 +204,9 @@ private void configureBindings() {
.onFalse(CompoundCommands.armToStowSafely());
controller
.rightTrigger(0.25)
.whileTrue(intake.ejectCoralCommand())
.onFalse(intake.stopCommand().alongWith(CompoundCommands.armToStow()));
.whileTrue(intake.runEjectCommand())
.onFalse(
intake.stopCommand().alongWith(CompoundCommands.armToStowSafely()).andThen(zeroArm()));

controller
.rightStick()
Expand Down
6 changes: 6 additions & 0 deletions src/main/java/frc/robot/constants/ElevatorConstants.java
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,12 @@ public class ElevatorConstants {

public static final double moveVoltage = 5.0;

/** Maximum speed of elevator in m/s */
public static final double MAX_SPEED = 3.6;

/** Maximum acceleration of elevator in m/s² */
public static final double MAX_ACCELERATION = 4.0;

/* Device IDs */
public static final int motorID = 12;

Expand Down
6 changes: 5 additions & 1 deletion src/main/java/frc/robot/constants/IntakeConstants.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@ public class IntakeConstants {

public static final double INTAKE_CORAL_TOP_MOTOR_VOLTAGE = -3;
public static final double INTAKE_CORAL_LOW_MOTOR_VOLTAGE = 3;
public static final double EJECT_CORAL_TOP_MOTOR_VOLTAGE = 4;

public static final double BACKWARD_EJECT_CORAL_TOP_MOTOR_VOLTAGE = 3;
public static final double FOREWARD_EJECT_CORAL_TOP_MOTOR_VOLTAGE = -3;
public static final double BACKWARD_EJECT_CORAL_LOW_MOTOR_VOLTAGE = -3;
public static final double FOREWARD_EJECT_CORAL_LOW_MOTOR_VOLTAGE = 3;

public static final double INTAKE_ALGAE_LOW_MOTOR_VOLTAGE = -4;
public static final double EJECT_ALGAE_LOW_MOTOR_VOLTAGE = 3;
Expand Down
Loading