AP_Frsky_Telem: rename AP_AHRS::get_position to get_location

This commit is contained in:
Peter Barker 2022-01-21 10:42:40 +11:00 committed by Andrew Tridgell
parent 88afef4cdc
commit 423bd1e8a4
2 changed files with 3 additions and 3 deletions

View File

@ -77,7 +77,7 @@ void AP_Frsky_Backend::calc_nav_alt(void)
AP_AHRS &_ahrs = AP::ahrs(); AP_AHRS &_ahrs = AP::ahrs();
WITH_SEMAPHORE(_ahrs.get_semaphore()); WITH_SEMAPHORE(_ahrs.get_semaphore());
if (_ahrs.get_position(loc)) { if (_ahrs.get_location(loc)) {
current_height = loc.alt*0.01f; current_height = loc.alt*0.01f;
if (!loc.relative_alt) { if (!loc.relative_alt) {
// loc.alt has home altitude added, remove it // loc.alt has home altitude added, remove it
@ -109,7 +109,7 @@ void AP_Frsky_Backend::calc_gps_position(void)
Location loc; Location loc;
if (_ahrs.get_position(loc)) { if (_ahrs.get_location(loc)) {
float lat = format_gps(fabsf(loc.lat/10000000.0f)); float lat = format_gps(fabsf(loc.lat/10000000.0f));
_SPort_data.latdddmm = lat; _SPort_data.latdddmm = lat;
_SPort_data.latmmmm = (lat - _SPort_data.latdddmm) * 10000; _SPort_data.latmmmm = (lat - _SPort_data.latdddmm) * 10000;

View File

@ -610,7 +610,7 @@ uint32_t AP_Frsky_SPort_Passthrough::calc_home(void)
{ {
AP_AHRS &_ahrs = AP::ahrs(); AP_AHRS &_ahrs = AP::ahrs();
WITH_SEMAPHORE(_ahrs.get_semaphore()); WITH_SEMAPHORE(_ahrs.get_semaphore());
got_position = _ahrs.get_position(loc); got_position = _ahrs.get_location(loc);
home_loc = _ahrs.get_home(); home_loc = _ahrs.get_home();
} }