mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 16:25:31 +03:00
Adjust info/warning status (#14088)
This commit is contained in:
parent
aab21384f6
commit
5dc5a8e973
2 changed files with 4 additions and 3 deletions
|
@ -887,6 +887,7 @@ static void osdElementCrashFlipArrow(osdElementParms_t *element)
|
|||
}
|
||||
|
||||
if ((isCrashFlipModeActive() || (!ARMING_FLAG(ARMED) && !isUpright())) && !((imuConfig()->small_angle < 180 && isUpright()) || (rollAngle == 0 && pitchAngle == 0))) {
|
||||
element->attr = DISPLAYPORT_SEVERITY_INFO;
|
||||
if (abs(pitchAngle) < 2 * abs(rollAngle) && abs(rollAngle) < 2 * abs(pitchAngle)) {
|
||||
if (pitchAngle > 0) {
|
||||
if (rollAngle > 0) {
|
||||
|
@ -1167,7 +1168,7 @@ static void osdElementGpsSats(osdElementParms_t *element)
|
|||
}
|
||||
#endif
|
||||
else {
|
||||
element->attr = DISPLAYPORT_SEVERITY_INFO;
|
||||
element->attr = DISPLAYPORT_SEVERITY_NORMAL;
|
||||
}
|
||||
|
||||
if (!gpsIsHealthy()) {
|
||||
|
|
|
@ -139,7 +139,7 @@ void renderOsdWarning(char *warningText, bool *blinking, uint8_t *displayAttr)
|
|||
if (osdWarnGetState(OSD_WARNING_CRASHFLIP) && IS_RC_MODE_ACTIVE(BOXCRASHFLIP)) {
|
||||
if (isCrashFlipModeActive()) { // if was armed in crashflip mode
|
||||
tfp_sprintf(warningText, CRASHFLIP_WARNING);
|
||||
*displayAttr = DISPLAYPORT_SEVERITY_INFO;
|
||||
*displayAttr = DISPLAYPORT_SEVERITY_WARNING;
|
||||
return;
|
||||
} else if (!ARMING_FLAG(ARMED)) { // if disarmed, but crashflip mode is activated (not allowed / can't happen)
|
||||
tfp_sprintf(warningText, "CRASHFLIP SW");
|
||||
|
@ -420,7 +420,7 @@ void renderOsdWarning(char *warningText, bool *blinking, uint8_t *displayAttr)
|
|||
if (osdWarnGetState(OSD_WARNING_BATTERY_NOT_FULL) && !(ARMING_FLAG(ARMED) || ARMING_FLAG(WAS_EVER_ARMED)) && (getBatteryState() == BATTERY_OK)
|
||||
&& getBatteryAverageCellVoltage() < batteryConfig()->vbatfullcellvoltage) {
|
||||
tfp_sprintf(warningText, "BATT < FULL");
|
||||
*displayAttr = DISPLAYPORT_SEVERITY_INFO;
|
||||
*displayAttr = DISPLAYPORT_SEVERITY_WARNING;
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue