-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3247b42
commit 768e85f
Showing
9 changed files
with
70 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...systems/drive/intake/IntakeConstants.java → ...ot/subsystems/intake/IntakeConstants.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
src/main/java/frc/robot/subsystems/intake/IntakeIOProto.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package frc.robot.subsystems.intake; | ||
|
||
import com.ctre.phoenix6.configs.TalonFXConfiguration; | ||
import com.ctre.phoenix6.hardware.TalonFX; | ||
import com.ctre.phoenix6.signals.NeutralModeValue; | ||
|
||
public class IntakeIOProto implements IntakeIO { | ||
private final TalonFX intake; | ||
|
||
public IntakeIOProto() { | ||
intake = new TalonFX(17); | ||
|
||
var config = new TalonFXConfiguration(); | ||
config.MotorOutput.NeutralMode = NeutralModeValue.Brake; | ||
|
||
intake.getConfigurator().apply(config); | ||
} | ||
|
||
@Override | ||
public void updateInputs(IntakeIOInputsAutoLogged inputs) { | ||
inputs.intakeAppliedVolts = intake.getMotorVoltage().getValueAsDouble(); | ||
inputs.intakeCurrentDraw = intake.getSupplyCurrent().getValueAsDouble(); | ||
} | ||
|
||
@Override | ||
public void setMotorVoltageIntake(double voltage) { | ||
intake.setVoltage(voltage); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...systems/drive/intake/IntakeSubsystem.java → ...ot/subsystems/intake/IntakeSubsystem.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters