generated from Frc5572/Java-Template
-
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
51c8a10
commit 5d60e08
Showing
4 changed files
with
67 additions
and
31 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package frc.robot.subsystems.intake; | ||
|
||
import edu.wpi.first.wpilibj.DigitalInput; | ||
import frc.robot.Constants; | ||
|
||
public class IntakeSim implements IntakeIO { | ||
|
||
private final DigitalInput indexerBeamBrake = | ||
new DigitalInput(Constants.IntakeConstants.INDEXER_BEAM_BRAKE_DIO_PORT); | ||
private final DigitalInput intakeBeamBrake = | ||
new DigitalInput(Constants.IntakeConstants.INTAKE_BEAM_BRAKE_DIO_PORT); | ||
|
||
public IntakeSim() {} | ||
|
||
@Override | ||
public void updateInputs(IntakeInputs inputs) { | ||
// inputs.intakeSupplyVoltage = intakeMotorLeft.getBusVoltage(); | ||
// inputs.intakeAmps = intakeMotorLeft.getOutputCurrent(); | ||
// inputs.intakeRPM = intakeRelativeEnc.getVelocity(); | ||
// inputs.indexerSupplyVoltage = indexerMotor.getSupplyVoltage().getValueAsDouble(); | ||
// inputs.indexerMotorVoltage = indexerMotor.getMotorVoltage().getValueAsDouble(); | ||
// inputs.indexerAmps = indexerMotor.getSupplyCurrent().getValueAsDouble(); | ||
// inputs.indexerRPM = indexerMotor.getVelocity().getValueAsDouble(); | ||
inputs.indexerBeamBrake = !indexerBeamBrake.get(); // true == game piece | ||
inputs.intakeBeamBrake = !intakeBeamBrake.get(); // true == game piece | ||
} | ||
} |