AP_AHRS: getLastYawResetAngle returns reset time

This commit is contained in:
Randy Mackay 2015-09-24 15:51:21 +09:00
parent 015f700bc0
commit 9f59b6f7b5
3 changed files with 6 additions and 9 deletions

View File

@ -400,9 +400,8 @@ public:
}; };
// return the amount of yaw angle change due to the last yaw angle reset in radians // return the amount of yaw angle change due to the last yaw angle reset in radians
// returns true if a reset yaw angle has been updated and not queried // returns the time of the last yaw angle reset or 0 if no reset has ever occurred
// this function should not have more than one client virtual uint32_t getLastYawResetAngle(float &yawAng) {
virtual bool getLastYawResetAngle(float &yawAng) {
return false; return false;
}; };

View File

@ -679,9 +679,8 @@ const char *AP_AHRS_NavEKF::prearm_failure_reason(void) const
} }
// return the amount of yaw angle change due to the last yaw angle reset in radians // return the amount of yaw angle change due to the last yaw angle reset in radians
// returns true if a reset yaw angle has been updated and not queried // returns the time of the last yaw angle reset or 0 if no reset has ever occurred
// this function should not have more than one client uint32_t AP_AHRS_NavEKF::getLastYawResetAngle(float &yawAng)
bool AP_AHRS_NavEKF::getLastYawResetAngle(float &yawAng)
{ {
switch (ekf_type()) { switch (ekf_type()) {
case 1: case 1:

View File

@ -143,9 +143,8 @@ public:
const char *prearm_failure_reason(void) const override; const char *prearm_failure_reason(void) const override;
// return the amount of yaw angle change due to the last yaw angle reset in radians // return the amount of yaw angle change due to the last yaw angle reset in radians
// returns true if a reset yaw angle has been updated and not queried // returns the time of the last yaw angle reset or 0 if no reset has ever occurred
// this function should not have more than one client uint32_t getLastYawResetAngle(float &yawAng);
bool getLastYawResetAngle(float &yawAng);
// Resets the baro so that it reads zero at the current height // Resets the baro so that it reads zero at the current height
// Resets the EKF height to zero // Resets the EKF height to zero