Skip to content

Error in "AP_NavEKF2_MagFusion.cpp" #49

@hamidmajidibalanji

Description

@hamidmajidibalanji

Why I got the following error, when I try to install "Ardupilot and MAVProxy"?

../../libraries/AP_NavEKF2/AP_NavEKF2_MagFusion.cpp: In member function ‘void NavEKF2_core::FuseMagnetometer()’:
../../libraries/AP_NavEKF2/AP_NavEKF2_MagFusion.cpp:681:44: error: ‘H_MAG’ may be used uninitialized [-Werror=maybe-uninitialized]
681 | KH[i][j] = Kfusion[i] * H_MAG[j];
| ~~~~~~~^
compilation terminated due to -Wfatal-errors.
cc1plus: some warnings being treated as errors

Waf: Leaving directory `/home/hamid/ardupilot/build/sitl'
Build failed
-> task in 'objs/AP_NavEKF2' failed (exit status 1):
{task 139951261890144: cxx AP_NavEKF2_MagFusion.cpp -> AP_NavEKF2_MagFusion.cpp.0.o}
(run with -v to display more information)
SIM_VEHICLE: Build failed
SIM_VEHICLE: Killing tasks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions