Merge pull request #7730 from TonyBlit/fix_resc_off

Fix timed GPS RESCUE OFF message condition
This commit is contained in:
Michael Keller 2019-03-09 21:52:49 +13:00 committed by GitHub
commit 92ed1be027
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -1096,7 +1096,7 @@ static void osdElementWarnings(osdElementParms_t *element)
gpsRescueIsConfigured() &&
!gpsRescueIsDisabled() &&
!gpsRescueIsAvailable()) {
osdFormatMessage(element->buff, OSD_FORMAT_MESSAGE_BUFFER_SIZE, "NO GPS RESC");
osdFormatMessage(element->buff, OSD_FORMAT_MESSAGE_BUFFER_SIZE, "RESCUE N/A");
SET_BLINK(OSD_WARNINGS);
return;
}
@ -1107,8 +1107,8 @@ static void osdElementWarnings(osdElementParms_t *element)
gpsRescueIsDisabled()) {
statistic_t *stats = osdGetStats();
if (!cmpTimeUs(stats->armed_time, OSD_GPS_RESCUE_DISABLED_WARNING_DURATION_US)) {
osdFormatMessage(element->buff, OSD_FORMAT_MESSAGE_BUFFER_SIZE, "RESC OFF!!!");
if (cmpTimeUs(stats->armed_time, OSD_GPS_RESCUE_DISABLED_WARNING_DURATION_US) < 0) {
osdFormatMessage(element->buff, OSD_FORMAT_MESSAGE_BUFFER_SIZE, "RESCUE OFF");
SET_BLINK(OSD_WARNINGS);
return;
}