From 81f33bb01f40c881caf6fd87cd985a9953fc1009 Mon Sep 17 00:00:00 2001 From: Jacob Dahl Date: Mon, 5 Oct 2026 16:49:06 -0600 Subject: [PATCH] fix(gnss): say GPS in the new pilot-facing messages Pilots know "GPS"; only the code and parameters underneath move to GNSS. The position-lost reasons, the primary-offline warning and the receiver switch event now say GPS like the rest of the ground station text. Assisted-by: Claude:claude-opus-5-5 --- .../HealthAndArmingChecks/checks/estimatorCheck.cpp | 8 ++++---- .../HealthAndArmingChecks/checks/gnssRedundancyCheck.cpp | 2 +- .../sensors/vehicle_gps_position/VehicleGPSPosition.cpp | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp index 19e996be875..85b1be3d6d7 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp @@ -769,7 +769,7 @@ void EstimatorChecks::reportGnssReasonForPositionLoss(const Context &context, Re * The receiver had stopped delivering samples when the local position estimate became invalid. */ events::send(events::ID("check_estimator_position_lost_gnss_no_data"), events::Log::Error, - "Local position lost, no data from GNSS {1}", receiver); + "Local position lost, no data from GPS {1}", receiver); } else if (state == estimator_status_flags_s::GNSS_FUSION_UNUSABLE) { uint16_t failed_checks = 0; @@ -790,7 +790,7 @@ void EstimatorChecks::reportGnssReasonForPositionLoss(const Context &context, Re * */ events::send(events::ID("check_estimator_position_lost_gnss_reason"), - events::Log::Error, "Local position lost, GNSS {1} check failed: {2}", receiver, + events::Log::Error, "Local position lost, GPS {1} check failed: {2}", receiver, static_cast(failed_checks)); } else if (rejected) { @@ -800,7 +800,7 @@ void EstimatorChecks::reportGnssReasonForPositionLoss(const Context &context, Re * reset to them while another source constrained the position. */ events::send(events::ID("check_estimator_position_lost_gnss_rejected"), events::Log::Error, - "Local position lost, GNSS {1} rejected by the estimator", receiver); + "Local position lost, GPS {1} rejected by the estimator", receiver); } else if (state == estimator_status_flags_s::GNSS_FUSION_VEL_LIMIT) { /* EVENT @@ -810,7 +810,7 @@ void EstimatorChecks::reportGnssReasonForPositionLoss(const Context &context, Re * */ events::send(events::ID("check_estimator_position_lost_gnss_vel_limit"), events::Log::Error, - "Local position lost, GNSS {1} velocity above the limit", receiver); + "Local position lost, GPS {1} velocity above the limit", receiver); } } diff --git a/src/modules/commander/HealthAndArmingChecks/checks/gnssRedundancyCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/gnssRedundancyCheck.cpp index 8ae19184878..ec8187c9612 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/gnssRedundancyCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/gnssRedundancyCheck.cpp @@ -195,6 +195,6 @@ void GnssRedundancyChecks::checkAndReport(const Context &context, Report &report * */ reporter.armingCheckFailure(NavModes::None, health_component_t::gps, events::ID("check_gnss_primary_offline"), - events::Log::Warning, "Primary GNSS receiver offline"); + events::Log::Warning, "Primary GPS offline"); } } diff --git a/src/modules/sensors/vehicle_gps_position/VehicleGPSPosition.cpp b/src/modules/sensors/vehicle_gps_position/VehicleGPSPosition.cpp index 5c69d0527e5..1a835f98d83 100644 --- a/src/modules/sensors/vehicle_gps_position/VehicleGPSPosition.cpp +++ b/src/modules/sensors/vehicle_gps_position/VehicleGPSPosition.cpp @@ -558,7 +558,7 @@ void VehicleGPSPosition::reportSwitch(int previous, int selected, uint8_t reason */ events::send(events::ID("gnss_receiver_switched"), {failure ? events::Log::Warning : events::Log::Info, events::LogInternal::Info}, - "Switched from GNSS {3} to GNSS {1}: {2}", static_cast(selected), + "Switched from GPS {3} to GPS {1}: {2}", static_cast(selected), static_cast(reason), static_cast(previous)); }