Paparazzi UAS  v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
hf_float.h File Reference
#include "std.h"
#include "math/pprz_algebra_float.h"
#include "math/pprz_algebra_int.h"
#include "generated/airframe.h"
+ Include dependency graph for hf_float.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  HfilterFloat
 

Macros

#define HFF_STATE_SIZE   3
 

Functions

void hff_init (float init_x, float init_xdot, float init_y, float init_ydot)
 
void hff_propagate (void)
 
void hff_update_gps (struct FloatVect2 *pos_ned, struct FloatVect2 *speed_ned)
 
void hff_update_pos (struct FloatVect2 pos, struct FloatVect2 Rpos)
 Update position. More...
 
void hff_update_vel (struct FloatVect2 vel, struct FloatVect2 Rvel)
 
void hff_realign (struct FloatVect2 pos, struct FloatVect2 vel)
 

Variables

struct HfilterFloat hff
 

Detailed Description

Horizontal filter (x,y) to estimate position and velocity.

Definition in file hf_float.h.


Data Structure Documentation

◆ HfilterFloat

struct HfilterFloat

Definition at line 40 of file hf_float.h.

Data Fields
uint16_t lag_counter
bool rollback
float x
float xbias
float xdot
float xdotdot
float xP[HFF_STATE_SIZE][HFF_STATE_SIZE]
float y
float ybias
float ydot
float ydotdot
float yP[HFF_STATE_SIZE][HFF_STATE_SIZE]

Macro Definition Documentation

◆ HFF_STATE_SIZE

#define HFF_STATE_SIZE   3

Definition at line 38 of file hf_float.h.

Function Documentation

◆ hff_init()

◆ hff_propagate()

◆ hff_realign()

void hff_realign ( struct FloatVect2  pos,
struct FloatVect2  vel 
)

◆ hff_update_gps()

◆ hff_update_pos()

void hff_update_pos ( struct FloatVect2  pos,
struct FloatVect2  Rpos 
)

Update position.

H = [1 0 0]; R = 0.1; // state residual y = rangemeter - H * Xm; // covariance residual S = H*Pm*H' + R; // kalman gain K = Pm*H'*inv(S); // update state Xp = Xm + K*y; // update covariance Pp = Pm - K*H*Pm;

Definition at line 711 of file hf_float.c.

References hff, hff_lost_counter, hff_update_x(), hff_update_y(), FloatVect2::x, and FloatVect2::y.

Referenced by pos_est_cb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ hff_update_vel()

void hff_update_vel ( struct FloatVect2  vel,
struct FloatVect2  Rvel 
)

Definition at line 806 of file hf_float.c.

References hff, hff_speed_lost_counter, hff_update_xdot(), hff_update_ydot(), FloatVect2::x, and FloatVect2::y.

Referenced by vel_est_cb().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ hff