fix(estimator-checks): do not report sensor failure on jamming detection - #28305
Merged
Conversation
Using "Notice" instead of "Warning" makes sure the the GPS bit in SYS_STATUS stays healthy while still reporting the jamming message.
Contributor
🔎 FLASH Analysispx4_fmu-v5x [Total VM Diff: 80 byte (0 %)]px4_fmu-v6x [Total VM Diff: 80 byte (0 %)]Updated: 2026-08-20T12:43:53 |
The published gps_check_fail_flags mask was derived from EKF2_GPS_CHECK with a positional shift, assuming param bit N corresponds to fail status bit N+1. That only holds up to kSpoofed: the fix check sits at param bit 10 but status bit 0, so the shift made param bit 10 (Fix type) publish status bit 11 (jammed), and param bit 11 (Jamming) map to a status bit no check ever sets. With the default EKF2_GPS_CHECK of 2047 the published mask was therefore 4095, which reports a jamming failure even though the jamming check is disabled, while enabling the jamming check published nothing. Map the two layouts one by one in GnssChecks, which owns both, so appending a check to one enum can no longer silently misassign the others. The fix bit is now gated on kFix like every other check, matching how it is already gated when computing whether the checks passed.
Member
|
@bresch would it not make sense to introduce a new FAILURE_TYPE? The approach here breaks the proposed implementation in QGC (mavlink/qgroundcontrol#14578) where we display the |
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.
Solved Problem
Even when a position estimate is not required, the jamming state sets the GPS health status to
falsein SYS_STATUS. This can cause the listener (e.g.: GCS) to report an issue.Solution
Using "Notice" instead of "Warning" makes sure the the GPS bit in SYS_STATUS stays healthy while still reporting the jamming message.

This is of course only the case if the current mode does't require a valid position.
The change was tested in SITL by adding
SYS_FAIL_GPS_JAMthat can be configured to change the jamming status when triggeringfailure gps wrong.Additional fix: there was a mismatch between the bits in
EKF2_GPS_CHECKand the publishedgps_check_fail_flagswhich led to the jamming checks being enabled while it was disabled in the parameter.Changelog Entry
For release notes:
Test coverage
SITL