From 2cc193c173232b3c72ca0b06a9c7b5ef7306c64e Mon Sep 17 00:00:00 2001 From: TSC21 Date: Thu, 12 Jul 2018 20:38:25 +0100 Subject: [PATCH] lpe: mocap: fix enum constant in boolean context --- src/modules/local_position_estimator/sensors/mocap.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/local_position_estimator/sensors/mocap.cpp b/src/modules/local_position_estimator/sensors/mocap.cpp index 98f80f5b81..83855f1119 100644 --- a/src/modules/local_position_estimator/sensors/mocap.cpp +++ b/src/modules/local_position_estimator/sensors/mocap.cpp @@ -41,7 +41,7 @@ void BlockLocalPositionEstimator::mocapInit() _global_ref_timestamp = hrt_absolute_time(); _is_global_cov_init = globallocalconverter_initialized(); - if (!_map_ref.init_done && _is_global_cov_init && !FUSE_VIS_POS) { + if (!_map_ref.init_done && _is_global_cov_init && _visionUpdated) { // initialize global origin using the mocap estimator reference (only if the vision estimation is not being fused as well) mavlink_and_console_log_info(&mavlink_log_pub, "[lpe] global origin init (mocap) : lat %6.2f lon %6.2f alt %5.1f m", double(_ref_lat), double(_ref_lon), double(_ref_alt));