Browse Source

AP_NavEKF3: pre_arm_check may skip position checks

c415-sdk
Randy Mackay 4 years ago committed by Andrew Tridgell
parent
commit
f6cb0819ef
  1. 5
      libraries/AP_NavEKF3/AP_NavEKF3.cpp
  2. 3
      libraries/AP_NavEKF3/AP_NavEKF3.h

5
libraries/AP_NavEKF3/AP_NavEKF3.cpp

@ -1060,10 +1060,11 @@ bool NavEKF3::healthy(void) const @@ -1060,10 +1060,11 @@ bool NavEKF3::healthy(void) const
}
// returns false if we fail arming checks, in which case the buffer will be populated with a failure message
bool NavEKF3::pre_arm_check(char *failure_msg, uint8_t failure_msg_len) const
// requires_position should be true if horizontal position configuration should be checked
bool NavEKF3::pre_arm_check(bool requires_position, char *failure_msg, uint8_t failure_msg_len) const
{
// check source configuration
if (!sources.pre_arm_check(failure_msg, failure_msg_len)) {
if (!sources.pre_arm_check(requires_position, failure_msg, failure_msg_len)) {
return false;
}

3
libraries/AP_NavEKF3/AP_NavEKF3.h

@ -56,7 +56,8 @@ public: @@ -56,7 +56,8 @@ public:
bool healthy(void) const;
// returns false if we fail arming checks, in which case the buffer will be populated with a failure message
bool pre_arm_check(char *failure_msg, uint8_t failure_msg_len) const;
// requires_position should be true if horizontal position configuration should be checked
bool pre_arm_check(bool requires_position, char *failure_msg, uint8_t failure_msg_len) const;
// returns the index of the primary core
// return -1 if no primary core selected

Loading…
Cancel
Save