mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-25 07:43:33 +08:00
ekf2: always publish global position when origin has been set
This commit is contained in:
@@ -1164,7 +1164,7 @@ void EKF2::PublishEventFlags(const hrt_abstime ×tamp)
|
|||||||
|
|
||||||
void EKF2::PublishGlobalPosition(const hrt_abstime ×tamp)
|
void EKF2::PublishGlobalPosition(const hrt_abstime ×tamp)
|
||||||
{
|
{
|
||||||
if (_ekf.global_position_is_valid()) {
|
if (_ekf.global_origin_valid() && _ekf.control_status().flags.yaw_align) {
|
||||||
const Vector3f position{_ekf.getPosition()};
|
const Vector3f position{_ekf.getPosition()};
|
||||||
|
|
||||||
// generate and publish global position data
|
// generate and publish global position data
|
||||||
|
|||||||
Reference in New Issue
Block a user