Skip to content

Prevent premature launches: disable continuous indexing on intake and tune beam-break pulse#11

Open
mechaniaccc wants to merge 2 commits intomainfrom
codex/modify-indexer-rotation-logic-nshje5
Open

Prevent premature launches: disable continuous indexing on intake and tune beam-break pulse#11
mechaniaccc wants to merge 2 commits intomainfrom
codex/modify-indexer-rotation-logic-nshje5

Conversation

@mechaniaccc
Copy link
Contributor

Motivation

  • Intake was still driving the indexer continuously while the left trigger was held, which caused rings to be advanced into the shooter and sometimes launched prematurely.
  • The beam-break compensation logic needed tighter caps and a proper subsystem implementation so pulsed indexing behaves predictably and callers can query beam-break state.

Description

  • Updated TeleOp binding to stop continuous indexer drive during normal intake by changing the left-trigger IntakeCommand call to pass indexPower = 0 instead of 0.6 (file: CommandTeleOp.java).
  • Tuned IntakeCommand to reduce the beam-break feed pulse to 180 ms, added separate pulse power caps INDEX_FEED_PULSE_POWER_INTAKE = 0.35 and INDEX_FEED_PULSE_POWER_ACTIVE = 0.6, and implemented getIndexPulsePower() which returns the appropriate capped pulse power (file: IntakeCommand.java).
  • Restored BeamBreakSubsystem as a proper SubsystemBase implementation with isBeamBreakOn(...) and getVoltage() methods and removed the embedded debug opmode (file: BeamBreakSubsystem.java).

Testing

  • Verified code locations and the updated binding with rg -n "leftTrigger\.whileActiveContinuous|new IntakeCommand\(feeder, \(\) -> beamBreak\.isBeamBreakOn\(" TeamCode/src/main/java/org/firstinspires/ftc/teamcode/CommandTeleOp.java, which found the modified binding.
  • Attempted to compile with ./gradlew :TeamCode:compileDebugJavaWithJavac --console=plain, but Gradle wrapper download was blocked by the environment proxy (HTTP/1.1 403 Forbidden), so a full compile could not be completed in this environment.

Codex Task

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant