forked from Archive/PX4-Autopilot
EKF hotfix: Force zero initialization of vectors
This commit is contained in:
parent
c610050dc3
commit
b4b3a2a2c6
|
@ -743,8 +743,8 @@ FixedwingEstimator::task_main()
|
|||
/* sets also parameters in the EKF object */
|
||||
parameters_update();
|
||||
|
||||
Vector3f lastAngRate = {0.0f, 0.0f, 0.0f};
|
||||
Vector3f lastAccel = {0.0f, 0.0f, 0.0f};
|
||||
Vector3f lastAngRate;
|
||||
Vector3f lastAccel;
|
||||
|
||||
/* wakeup source(s) */
|
||||
struct pollfd fds[2];
|
||||
|
|
|
@ -73,7 +73,7 @@ void AttPosEKF::UpdateStrapdownEquationsNED()
|
|||
float qUpdated[4];
|
||||
float quatMag;
|
||||
float deltaQuat[4];
|
||||
const Vector3f gravityNED = {0.0,0.0,GRAVITY_MSS};
|
||||
const Vector3f gravityNED(0.0f, 0.0f, GRAVITY_MSS);
|
||||
|
||||
// Remove sensor bias errors
|
||||
correctedDelAng.x = dAngIMU.x - states[10];
|
||||
|
|
|
@ -19,6 +19,14 @@ public:
|
|||
float y;
|
||||
float z;
|
||||
|
||||
Vector3f() { zero(); }
|
||||
|
||||
Vector3f(float a, float b, float c) :
|
||||
x(a),
|
||||
y(b),
|
||||
z(c)
|
||||
{}
|
||||
|
||||
float length(void) const;
|
||||
void zero(void);
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue