Paparazzi UAS  v5.2.2_stable-0-gd6b9f29
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
vf_extended_float.c File Reference

Extended vertical filter (in float). More...

#include "subsystems/ins/vf_extended_float.h"
#include "generated/airframe.h"
#include "std.h"
+ Include dependency graph for vf_extended_float.c:

Go to the source code of this file.

Macros

#define DEBUG_VFF_EXTENDED   0
 
#define INS_PROPAGATE_FREQUENCY   PERIODIC_FREQUENCY
 
#define DT_VFILTER   (1./(INS_PROPAGATE_FREQUENCY))
 
#define INIT_PXX   1.
 
#define ACCEL_NOISE   0.5
 
#define Qzz   ACCEL_NOISE * DT_VFILTER * DT_VFILTER / 2.
 
#define Qzdotzdot   ACCEL_NOISE * DT_VFILTER
 
#define Qbiasbias   1e-7
 
#define Qoffoff   1e-4
 
#define R_BARO   1.
 
#define R_ALT   0.1
 
#define R_OFFSET   1.
 

Functions

void vff_init_zero (void)
 
void vff_init (float init_z, float init_zdot, float init_accel_bias, float init_baro_offset)
 
void vff_propagate (float accel)
 
static void update_baro_conf (float z_meas, float conf)
 
void vff_update_baro (float z_meas)
 
void vff_update_baro_conf (float z_meas, float conf)
 
static void update_alt_conf (float z_meas, float conf)
 
void vff_update_z (float z_meas)
 
void vff_update_z_conf (float z_meas, float conf)
 
static void update_offset_conf (float offset, float conf)
 
void vff_update_offset (float offset)
 
void vff_realign (float z_meas)
 

Variables

struct VffExtended vff
 

Detailed Description

Extended vertical filter (in float).

Estimates altitude, vertical speed, accelerometer bias and barometer offset.

Definition in file vf_extended_float.c.

Macro Definition Documentation

#define ACCEL_NOISE   0.5

Definition at line 72 of file vf_extended_float.c.

#define DEBUG_VFF_EXTENDED   0

Definition at line 37 of file vf_extended_float.c.

#define DT_VFILTER   (1./(INS_PROPAGATE_FREQUENCY))

Definition at line 57 of file vf_extended_float.c.

Referenced by vff_propagate().

#define INIT_PXX   1.

Definition at line 70 of file vf_extended_float.c.

Referenced by vff_init().

#define INS_PROPAGATE_FREQUENCY   PERIODIC_FREQUENCY

Definition at line 52 of file vf_extended_float.c.

#define Qbiasbias   1e-7

Definition at line 75 of file vf_extended_float.c.

Referenced by vff_propagate().

#define Qoffoff   1e-4

Definition at line 76 of file vf_extended_float.c.

Referenced by vff_propagate().

#define Qzdotzdot   ACCEL_NOISE * DT_VFILTER

Definition at line 74 of file vf_extended_float.c.

Referenced by vff_propagate().

#define Qzz   ACCEL_NOISE * DT_VFILTER * DT_VFILTER / 2.

Definition at line 73 of file vf_extended_float.c.

Referenced by vff_propagate().

#define R_ALT   0.1

Definition at line 78 of file vf_extended_float.c.

Referenced by vff_update_z().

#define R_BARO   1.

Definition at line 77 of file vf_extended_float.c.

Referenced by vff_update_baro().

#define R_OFFSET   1.

Definition at line 79 of file vf_extended_float.c.

Referenced by vff_update_offset().

Function Documentation

static void update_alt_conf ( float  z_meas,
float  conf 
)
static

Definition at line 243 of file vf_extended_float.c.

References VffExtended::bias, K0, VffExtended::offset, VffExtended::P, vff, VffExtended::z, VffExtended::z_meas, and VffExtended::zdot.

Referenced by vff_update_z(), and vff_update_z_conf().

+ Here is the caller graph for this function:

static void update_baro_conf ( float  z_meas,
float  conf 
)
static

Definition at line 182 of file vf_extended_float.c.

References VffExtended::bias, K0, VffExtended::offset, VffExtended::P, vff, VffExtended::z, VffExtended::z_meas, VffExtended::z_meas_baro, and VffExtended::zdot.

Referenced by vff_update_baro(), and vff_update_baro_conf().

+ Here is the caller graph for this function:

static void update_offset_conf ( float  offset,
float  conf 
)
static

Definition at line 303 of file vf_extended_float.c.

References VffExtended::bias, K0, VffExtended::offset, VffExtended::P, vff, VffExtended::z, and VffExtended::zdot.

Referenced by vff_update_offset().

+ Here is the caller graph for this function:

void vff_init ( float  init_z,
float  init_zdot,
float  init_accel_bias,
float  init_baro_offset 
)

Definition at line 98 of file vf_extended_float.c.

References VffExtended::bias, INIT_PXX, VffExtended::offset, VffExtended::P, register_periodic_telemetry(), vff, VFF_STATE_SIZE, VffExtended::z, and VffExtended::zdot.

Referenced by vff_init_zero(), and vff_realign().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void vff_init_zero ( void  )

Definition at line 94 of file vf_extended_float.c.

Referenced by ins_init().

+ Here is the caller graph for this function:

void vff_propagate ( float  accel)

Definition at line 135 of file vf_extended_float.c.

Referenced by ins_propagate().

+ Here is the caller graph for this function:

void vff_realign ( float  z_meas)

Definition at line 345 of file vf_extended_float.c.

Referenced by baro_cb().

+ Here is the caller graph for this function:

void vff_update_baro ( float  z_meas)

Definition at line 221 of file vf_extended_float.c.

References R_BARO, and update_baro_conf().

Referenced by baro_cb().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void vff_update_baro_conf ( float  z_meas,
float  conf 
)

Definition at line 225 of file vf_extended_float.c.

References update_baro_conf().

+ Here is the call graph for this function:

void vff_update_offset ( float  offset)

Definition at line 340 of file vf_extended_float.c.

References R_OFFSET, and update_offset_conf().

+ Here is the call graph for this function:

void vff_update_z ( float  z_meas)

Definition at line 281 of file vf_extended_float.c.

References R_ALT, and update_alt_conf().

+ Here is the call graph for this function:

void vff_update_z_conf ( float  z_meas,
float  conf 
)

Definition at line 285 of file vf_extended_float.c.

Referenced by ins_update_gps().

+ Here is the caller graph for this function:

Variable Documentation