Browse Source

AC_WPNav: get_terrain_offset and get_vector_NEU made public

c415-sdk
Randy Mackay 4 years ago
parent
commit
f3c25397c7
  1. 14
      libraries/AC_WPNav/AC_WPNav.h

14
libraries/AC_WPNav/AC_WPNav.h

@ -49,6 +49,13 @@ public: @@ -49,6 +49,13 @@ public:
};
AC_WPNav::TerrainSource get_terrain_source() const;
// get terrain's altitude (in cm above the ekf origin) at the current position (+ve means terrain below vehicle is above ekf origin's altitude)
bool get_terrain_offset(float& offset_cm);
// convert location to vector from ekf origin. terrain_alt is set to true if resulting vector's z-axis should be treated as alt-above-terrain
// returns false if conversion failed (likely because terrain data was not available)
bool get_vector_NEU(const Location &loc, Vector3f &vec, bool &terrain_alt);
///
/// waypoint controller
///
@ -216,13 +223,6 @@ protected: @@ -216,13 +223,6 @@ protected:
uint8_t wp_yaw_set : 1; // true if yaw target has been set
} _flags;
// get terrain's altitude (in cm above the ekf origin) at the current position (+ve means terrain below vehicle is above ekf origin's altitude)
bool get_terrain_offset(float& offset_cm);
// convert location to vector from ekf origin. terrain_alt is set to true if resulting vector's z-axis should be treated as alt-above-terrain
// returns false if conversion failed (likely because terrain data was not available)
bool get_vector_NEU(const Location &loc, Vector3f &vec, bool &terrain_alt);
// helper function to calculate scurve jerk and jerk_time values
// updates _scurve_jerk and _scurve_jerk_time
void calc_scurve_jerk_and_jerk_time();

Loading…
Cancel
Save