working auto aim + autonomous after regio - #3
Conversation
…terpolation. Refactored some code.
|
Caution Review failedThe pull request is closed. ℹ️ Recent review infoConfiguration used: defaults Review profile: CHILL Plan: Pro 📒 Files selected for processing (13)
📝 WalkthroughWalkthroughThis PR introduces a range-based shooter targeting system with configurable RangeConfig data holders, substantially overhauls autonomous routines for multi-ball shooting sequences with staged intake/launch cycles, updates hardware calibration constants (flap, range velocities, angles), and removes automatic IMU reset and follower initialization during hardware setup. Changes
Sequence Diagram(s)sequenceDiagram
participant Sensor as Robot Sensor/Measurement
participant Range as Outtake (Range Interpolation)
participant Shooter as Shoot (Activation)
participant Config as RangeConfig
participant Hardware as Hardware Output
Sensor->>Range: measured distance (0 or value)
activate Range
alt distance == 0 (auto-range)
Range->>Range: interpolateRange()
Note over Range: TreeMap lookup + linear interpolation
else distance > 0 (fixed range)
Range->>Range: select fixed RangeConfig
end
Range-->>Config: RangeConfig (velocity, angle, kS)
deactivate Range
Shooter->>Shooter: activateRange(int range)
Shooter->>Config: assign to outtake.activeConfig
Hardware->>Hardware: apply velocity from activeConfig
Hardware->>Hardware: apply angle from activeConfig
Hardware->>Hardware: apply kS (friction compensation)
Estimated code review effort🎯 4 (Complex) | ⏱️ ~50 minutes Possibly related PRs
Poem
✨ Finishing Touches
🧪 Generate unit tests (beta)
Tip Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs). Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Before issuing a pull request, please see the contributing page.
Summary by CodeRabbit
Release Notes
New Features
Bug Fixes
Refactoring