Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CRSF SNR Range #6604

Merged
merged 1 commit into from
Feb 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/main/fc/settings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2799,8 +2799,8 @@ groups:
description: "Value below which Crossfire SNR Alarm pops-up. (dB)"
default_value: "4"
field: snr_alarm
min: -12
max: 8
min: -20
max: 10
- name: osd_link_quality_alarm
condition: USE_SERIALRX_CRSF
description: "LQ % indicator blinks below this value. For Crossfire use 70%, for Tracer use 50%"
Expand Down
10 changes: 5 additions & 5 deletions src/main/io/osd.c
Original file line number Diff line number Diff line change
Expand Up @@ -785,7 +785,7 @@ static const char * navigationStateMessage(void)
break;
case MW_NAV_STATE_RTH_START:
return OSD_MESSAGE_STR(OSD_MSG_STARTING_RTH);
case MW_NAV_STATE_RTH_CLIMB:
case MW_NAV_STATE_RTH_CLIMB:
return OSD_MESSAGE_STR(OSD_MSG_RTH_CLIMB);
case MW_NAV_STATE_RTH_ENROUTE:
return OSD_MESSAGE_STR(OSD_MSG_HEADING_HOME);
Expand Down Expand Up @@ -1685,7 +1685,7 @@ static bool osdDrawSingleElement(uint8_t item)
}

case OSD_CRSF_SNR_DB: {
const char* showsnr = "-12";
const char* showsnr = "-20";
const char* hidesnr = " ";
int16_t osdSNR_Alarm = rxLinkStatistics.uplinkSNR;
if (osdSNR_Alarm <= osdConfig()->snr_alarm) {
Expand Down Expand Up @@ -3378,7 +3378,7 @@ textAttributes_t osdGetSystemMessage(char *buff, size_t buff_size, bool isCenter
if (FLIGHT_MODE(NAV_RTH_MODE) || FLIGHT_MODE(NAV_WP_MODE) || navigationIsExecutingAnEmergencyLanding()) {
if (NAV_Status.state == MW_NAV_STATE_WP_ENROUTE) {
// Countdown display for remaining Waypoints
tfp_sprintf(messageBuf, "TO WP %u/%u", posControl.activeWaypointIndex + 1, posControl.waypointCount);
tfp_sprintf(messageBuf, "TO WP %u/%u", posControl.activeWaypointIndex + 1, posControl.waypointCount);
messages[messageCount++] = messageBuf;
} else if (NAV_Status.state == MW_NAV_STATE_HOLD_TIMED) {
// WP hold time countdown in seconds
Expand All @@ -3388,8 +3388,8 @@ textAttributes_t osdGetSystemMessage(char *buff, size_t buff_size, bool isCenter
tfp_sprintf(messageBuf, "HOLDING WP FOR %2u S", holdTimeRemaining);
messages[messageCount++] = messageBuf;
}
} else {
const char *navStateMessage = navigationStateMessage();
} else {
const char *navStateMessage = navigationStateMessage();
if (navStateMessage) {
messages[messageCount++] = navStateMessage;
}
Expand Down
4 changes: 2 additions & 2 deletions src/main/io/osd.h
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ typedef struct osdConfig_s {
float gforce_axis_alarm_min;
float gforce_axis_alarm_max;
#ifdef USE_SERIALRX_CRSF
int16_t snr_alarm; //CRSF SNR alarm in dB
int8_t snr_alarm; //CRSF SNR alarm in dB
int8_t link_quality_alarm;
#endif
#ifdef USE_BARO
Expand Down Expand Up @@ -337,7 +337,7 @@ typedef struct osdConfig_s {

bool osd_failsafe_switch_layout;
uint8_t plus_code_digits; // Number of digits to use in OSD_PLUS_CODE
uint8_t plus_code_short;
uint8_t plus_code_short;
uint8_t osd_ahi_style;
uint8_t force_grid; // Force a pixel based OSD to use grid mode.
uint8_t ahi_bordered; // Only used by the AHI widget
Expand Down