AP_AHRS: move location_update to Location and rename to offset_bearing
This commit is contained in:
parent
b31e5bf055
commit
701c5dd4c0
@ -30,6 +30,7 @@
|
||||
#include <AP_Baro/AP_Baro.h>
|
||||
#include <AP_Param/AP_Param.h>
|
||||
#include <AP_Common/Semaphore.h>
|
||||
#include <AP_Common/Location.h>
|
||||
|
||||
class OpticalFlow;
|
||||
#define AP_AHRS_TRIM_LIMIT 10.0f // maximum trim angle in degrees
|
||||
|
@ -989,7 +989,7 @@ bool AP_AHRS_DCM::get_position(struct Location &loc) const
|
||||
if (_flags.fly_forward && _have_position) {
|
||||
float gps_delay_sec = 0;
|
||||
_gps.get_lag(gps_delay_sec);
|
||||
location_update(loc, _gps.ground_course_cd() * 0.01f, _gps.ground_speed() * gps_delay_sec);
|
||||
loc.offset_bearing(_gps.ground_course_cd() * 0.01f, _gps.ground_speed() * gps_delay_sec);
|
||||
}
|
||||
return _have_position;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user