mirror of
https://github.com/iNavFlight/inav.git
synced 2025-07-25 09:16:01 +03:00
WP Mission RTH Change (#6524)
* Initial changes
Change WP mission RTH to normal RTH mode
* Cleanup and remove PR6050
* Clean up
* Persistent ID fix + existing bug fix
* Add system message
* Revert "Add system message"
This reverts commit 28ab7f33ba
.
* Add System Message
* Update navigation.c
This commit is contained in:
parent
459645801b
commit
f2692f322b
5 changed files with 51 additions and 99 deletions
|
@ -1710,7 +1710,7 @@ static bool osdDrawSingleElement(uint8_t item)
|
|||
else if (FLIGHT_MODE(MANUAL_MODE))
|
||||
p = "MANU";
|
||||
else if (FLIGHT_MODE(NAV_RTH_MODE))
|
||||
p = "RTH ";
|
||||
p = isWaypointMissionRTHActive() ? "WRTH" : "RTH ";
|
||||
else if (FLIGHT_MODE(NAV_POSHOLD_MODE))
|
||||
p = "HOLD";
|
||||
else if (FLIGHT_MODE(NAV_COURSE_HOLD_MODE) && FLIGHT_MODE(NAV_ALTHOLD_MODE))
|
||||
|
@ -3612,6 +3612,11 @@ textAttributes_t osdGetSystemMessage(char *buff, size_t buff_size, bool isCenter
|
|||
}
|
||||
} else {
|
||||
if (FLIGHT_MODE(NAV_RTH_MODE) || FLIGHT_MODE(NAV_WP_MODE) || navigationIsExecutingAnEmergencyLanding()) {
|
||||
if (isWaypointMissionRTHActive()) {
|
||||
// if RTH activated whilst WP mode selected, remind pilot to cancel WP mode to exit RTH
|
||||
messages[messageCount++] = OSD_MESSAGE_STR(OSD_MSG_WP_RTH_CANCEL);
|
||||
}
|
||||
|
||||
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);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue