fix: gate PVT satellites on decoding completeness#51
Merged
Conversation
Pair GNSSDecoder's newly exported is_decoding_completed_for_positioning with the existing is_sat_healthy check in calc_pvt. A satellite now enters the solve only once its decoder has recovered the full navigation data set a fix needs (TOW, ephemeris, SV clock polynomial, …) and promoted raw_data to data. Checking completeness first guarantees the broadcast health bit is already decoded, so the two predicates compose without a separate nothing guard. Requires the export, so bump the GNSSDecoder compat to 3.7. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #51 +/- ##
=======================================
Coverage 98.30% 98.30%
=======================================
Files 7 7
Lines 472 473 +1
=======================================
+ Hits 464 465 +1
Misses 8 8 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Contributor
Benchmark Results (Julia v1)Time benchmarks
Memory benchmarks
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
calc_pvtnow admits a satellite into the solve only once its decoder hasfully decoded the navigation data a fix needs — not just that the satellite
reports healthy.
This pairs GNSSDecoder's newly exported
is_decoding_completed_for_positioningwith the existing
is_sat_healthycheck:Completeness is checked first: once it holds, the broadcast health bit
is_sat_healthyinspects is guaranteed to have been decoded, so the twopredicates compose without a separate
nothingguard.Why
Previously a satellite could pass the health check while its decoder had not
yet recovered the full data set required to position from it (time of week,
ephemeris, SV clock polynomial, and — where carried in the required set — the
week number and single-band group delay). Using such a satellite risks a bad
or failed fix. The new gate ensures every satellite entering the least-squares
solve carries a complete, self-consistent
dataset.Changes
src/PositionVelocityTime.jl— add theis_decoding_completed_for_positioninggate alongside
is_sat_healthyincalc_pvt.Project.toml— bumpGNSSDecodercompat"3.6"→"3.7"(the release thatexports the new function).
Testing
Verified against GNSSDecoder 3.7.0 that both the GPS L1 C/A and Galileo E1B
test fixtures'
datablocks pass the new gate (and correctly fail when arequired field such as TOW/WN is dropped), so the existing test suite's
healthy-satellite counts are preserved.
🤖 Generated with Claude Code