Skip to main content

Stage 11: IMU Field-Centric Drive

Upgrade the existing Drivetrain.java; do not create another OpMode. The TeleOp continues to delegate stick input while the subsystem owns heading and coordinate conversion.

Your Task

  1. Map the IMU as "imu" and initialize it with the Control Hub's physical logo and USB orientation.
  2. Read yaw explicitly in radians.
  3. Let the X button reset heading.
  4. Rotate forward and strafe with sine and cosine.
  5. Reuse the normalized four-wheel mecanum output from Unit 4.

Keep all angle units explicit. Degrees and radians must not be mixed accidentally.

Coding Challenge Simulator

Telemark Unit 12 Comprehensive Coding Challenge
The editor opens your saved cumulative DECODE project and adds only the files introduced by this stage.
Use Init and Start to check every unit objective. Passing every check demonstrates full unit mastery.
Complete the stage across its file tabs. The requirement panel checks the compiled project, and a passing stage saves a read-only snapshot.

Passed every challenge check?

Mark the unit mastered to record every lesson objective and continue directly to the next unit. Your progress will be saved in this browser.

Stuck on this lesson?

Ask about anything on this page. It can see which lesson you have open and which part you are reading.