fix: guard debug[0-2] gyroUnfilt fallback to GYRO_SCALED mode only#159
Conversation
Previously, debug[0-2] was unconditionally used as a fallback for gyroUnfilt when dedicated gyroUnfilt columns were absent. This produced incorrect unfiltered gyro analysis for any debug_mode other than GYRO_SCALED (6), e.g. RC_SMOOTHING (7) or ACCELEROMETER (4), where debug[0-2] does not contain raw gyro data. Now the fallback is guarded: only proceeds when debug_mode=6, warns and skips otherwise. When debug_mode is absent from headers, the fallback is allowed with an assumption warning. Add DEBUG_MODE_GYRO_SCALED = 6 named constant to src/constants.rs. Closes #154 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
Warning Review limit reached
More reviews will be available in 21 minutes and 1 second. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more credits in the billing tab to continue. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
AI Generated pull-request
Summary
debug[0-2]gyroUnfilt fallback so it only activates whendebug_mode = GYRO_SCALED (6)DEBUG_MODE_GYRO_SCALED = 6tosrc/constants.rsCloses #154
Changes
src/constants.rs: addDEBUG_MODE_GYRO_SCALED: u32 = 6src/data_input/log_parser.rs: guard fallback assignment; fixNone => parsed_debug[axis]toNone if using_debug_fallback => parsed_debug[axis], None => None