← All tools

Message & Error Explainer

What an ArduPilot message means and what to do about it

Українська

The Advanced Failsafe is ending the flight on purpose

Act nowFailsafes and emergencies in flightPlane only

What ArduPilot says:

The Advanced Failsafe (AFS) is an optional system made for competitions whose rules demand that an aircraft is brought down rather than allowed to fly away. With AFS_TERM_ACTION 42 a plane crashes itself: throttle closed, flaps down, ailerons, rudder and elevator hard over. With 43 a QuadPlane lands in QLAND, while an ordinary plane only has its motor disarmed and glides on in its mode. The line gives the reason: RC failure (no radio for AFS_RC_FAIL_TIME), fence breach, range (further than AFS_MAX_RANGE km from where it armed), dual loss (ground station and GPS lost together), or one handed in by a battery failsafe or the ground station.

What to do, most likely first

  1. AFS was switched on without a need for it, or with settings copied from a competition aircraft.

    CheckAFS_ENABLE is 1 and AFS_TERM_ACTION is 42.

    FixAFS is the one failsafe a first plane should not have: unless a rule requires termination, set AFS_ENABLE to 0 and let the ordinary failsafes bring the plane home (FS_LONG_ACTN 1, RTL).

  2. The reason in the line did happen.

    CheckRead the last words of the line and the log before it.

    FixTreat each as its own fault: radio range for RC failure, the fence's size for a breach, AFS_MAX_RANGE for range, telemetry and GPS reception for dual loss.

  3. A battery failsafe is set to Terminate (BATT_FS_LOW_ACT or BATT_FS_CRT_ACT is 3).

    CheckThe line ends with “low battery” or “critical battery”.

    FixChoose 1 (RTL) or 2 (Land) for the battery failsafes unless a deliberate crash on low battery is what you want.

Changing the flight mode does not stop a termination. Setting AFS_TERMINATE back to 0 from the ground station does (“Aborting termination …”), if there is still height and a link to do it.

Parameters to look at

ParameterWhat it is
AFS_ENABLEEnable Advanced Failsafe
AFS_TERM_ACTIONTerminate action
AFS_TERMINATEForce Terminate
AFS_RC_FAIL_TIMERC failure time
AFS_GEOFENCEEnable geofence Advanced Failsafe
AFS_MAX_RANGEMax allowed range
AFS_DUAL_LOSSEnable dual loss terminate due to failure of both GCS and GPS simultaneously
AFS_GCS_TIMEOUTGCS timeout
The code that sends it

Terminating due to fence breach

libraries/AP_AdvancedFailsafe/AP_AdvancedFailsafe.cpp AP_AdvancedFailsafe::check() · Open in ArduPilot Copter-4.7.1

Terminating due to …

libraries/AP_AdvancedFailsafe/AP_AdvancedFailsafe.cpp AP_AdvancedFailsafe::gcs_terminate() · Open in ArduPilot Copter-4.7.1

Terminating due to dual loss

libraries/AP_AdvancedFailsafe/AP_AdvancedFailsafe.cpp AP_AdvancedFailsafe::check() · Open in ArduPilot Copter-4.7.1

Terminating due to RC failure

libraries/AP_AdvancedFailsafe/AP_AdvancedFailsafe.cpp AP_AdvancedFailsafe::check() · Open in ArduPilot Copter-4.7.1

And 1 more messages, sent from the same places.

Written here for Plane 4.6. In the tool you choose your vehicle and version, see your own parameter values beside the ones named here, and drop a flight log to have every message in it explained.

Open it in the Message & Error Explainer