Programming - Intake and Flywheel
Last updated
Was this helpful?

The intake is controlled using the bumpers on the gamepad. The left bumper intakes game pieces into the robot while right bumper reverses to output back onto the field.
The flywheel on the Starter Bot is controlled using two motors. These motors need to move at the same time when activated.

When cross is pressed, the flywheels will both spin up to the set target velocity. Then the Core Hex controlling the feeder will wait until both motors are within 100 ticks of the target velocity before activating and feeding game pieces into the flywheel to launch.

The Core Hex motor controlling the feeder into the flywheel can be manually controlled using the Dpad on the gamepad to assist with agitating game pieces and clearing jams.

If the robot is not receiving input from the Dpad or Cross button, then all three motors will return to 0 power.
To aid with fine tuning the flywheels, we can add telemetry to see the current velocity on the Driver Hub. The velocity can be changed by modifying the targetVelocity variable.

Last updated
Was this helpful?
Was this helpful?

