Paparazzi UAS  v5.0.5_stable-7-g4b8bbb7
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
baro_ms5611_i2c.h File Reference
#include "std.h"
+ Include dependency graph for baro_ms5611_i2c.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define MS5611_SOFT_RESET   0x1E
 
#define MS5611_PROM_READ   0xA0
 
#define MS5611_START_CONV_D1   0x48
 
#define MS5611_START_CONV_D2   0x58
 
#define MS5611_ADC_READ   0x00
 
#define PROM_NB   8
 
#define BARO_MS5611_DT   BARO_MS5611_PERIODIC_PERIOID
 new measurement every baro_ms5611_periodic More...
 
#define BARO_MS5611_R   20
 
#define BARO_MS5611_SIGMA2   1
 
#define BaroMs5611Update(_b, _h)   { if (baro_ms5611_valid) { _b = baro_ms5611_alt; _h(); baro_ms5611_valid = FALSE; } }
 

Enumerations

enum  ms5611_stat {
  MS5611_UNINIT, MS5611_RESET, MS5611_RESET_OK, MS5611_PROM,
  MS5611_IDLE, MS5611_CONV_D1, MS5611_CONV_D1_OK, MS5611_ADC_D1,
  MS5611_CONV_D2, MS5611_CONV_D2_OK, MS5611_ADC_D2, MS5611_UNINIT,
  MS5611_RESET, MS5611_RESET_OK, MS5611_PROM, MS5611_IDLE,
  MS5611_CONV_D1, MS5611_CONV_D1_OK, MS5611_ADC_D1, MS5611_CONV_D2,
  MS5611_CONV_D2_OK, MS5611_ADC_D2
}
 

Functions

void baro_ms5611_init (void)
 
void baro_ms5611_periodic (void)
 
void baro_ms5611_d1 (void)
 
void baro_ms5611_d2 (void)
 
void baro_ms5611_event (void)
 

Variables

float baro_ms5611_alt
 
bool_t baro_ms5611_valid
 
bool_t baro_ms5611_enabled
 
float baro_ms5611_r
 
float baro_ms5611_sigma2
 

Macro Definition Documentation

#define BARO_MS5611_DT   BARO_MS5611_PERIODIC_PERIOID

new measurement every baro_ms5611_periodic

Definition at line 16 of file baro_ms5611_i2c.h.

Referenced by alt_kalman().

#define BARO_MS5611_R   20

Definition at line 18 of file baro_ms5611_i2c.h.

Referenced by baro_ms5611_init().

#define BARO_MS5611_SIGMA2   1

Definition at line 19 of file baro_ms5611_i2c.h.

Referenced by baro_ms5611_init().

#define BaroMs5611Update (   _b,
  _h 
)    { if (baro_ms5611_valid) { _b = baro_ms5611_alt; _h(); baro_ms5611_valid = FALSE; } }

Definition at line 46 of file baro_ms5611_i2c.h.

#define MS5611_ADC_READ   0x00

Definition at line 11 of file baro_ms5611_i2c.h.

Referenced by baro_ms5611_d1(), baro_ms5611_d2(), and baro_periodic().

#define MS5611_PROM_READ   0xA0
#define MS5611_SOFT_RESET   0x1E

Definition at line 7 of file baro_ms5611_i2c.h.

Referenced by baro_ms5611_periodic(), and baro_periodic().

#define MS5611_START_CONV_D1   0x48

Definition at line 9 of file baro_ms5611_i2c.h.

Referenced by baro_ms5611_periodic(), and baro_periodic().

#define MS5611_START_CONV_D2   0x58

Definition at line 10 of file baro_ms5611_i2c.h.

Referenced by baro_event(), and baro_ms5611_event().

#define PROM_NB   8

Definition at line 13 of file baro_ms5611_i2c.h.

Referenced by baro_event(), and baro_ms5611_event().

Enumeration Type Documentation

Enumerator
MS5611_UNINIT 
MS5611_RESET 
MS5611_RESET_OK 
MS5611_PROM 
MS5611_IDLE 
MS5611_CONV_D1 
MS5611_CONV_D1_OK 
MS5611_ADC_D1 
MS5611_CONV_D2 
MS5611_CONV_D2_OK 
MS5611_ADC_D2 
MS5611_UNINIT 
MS5611_RESET 
MS5611_RESET_OK 
MS5611_PROM 
MS5611_IDLE 
MS5611_CONV_D1 
MS5611_CONV_D1_OK 
MS5611_ADC_D1 
MS5611_CONV_D2 
MS5611_CONV_D2_OK 
MS5611_ADC_D2 

Definition at line 26 of file baro_ms5611_i2c.h.

Function Documentation

void baro_ms5611_d1 ( void  )
void baro_ms5611_d2 ( void  )
void baro_ms5611_init ( void  )

Definition at line 83 of file baro_ms5611_i2c.c.

References baro_ms5611_enabled, BARO_MS5611_R, baro_ms5611_r, BARO_MS5611_SIGMA2, baro_ms5611_sigma2, baro_ms5611_valid, FALSE, ms5611_status, MS5611_UNINIT, prom_cnt, and TRUE.

Referenced by baro_ms5611_event().

+ Here is the caller graph for this function:

Variable Documentation

float baro_ms5611_alt

Definition at line 59 of file baro_ms5611_i2c.c.

Referenced by baro_ms5611_event().

bool_t baro_ms5611_enabled

Definition at line 60 of file baro_ms5611_i2c.c.

Referenced by alt_kalman(), and baro_ms5611_init().

float baro_ms5611_r

Definition at line 62 of file baro_ms5611_i2c.c.

Referenced by alt_kalman(), and baro_ms5611_init().

float baro_ms5611_sigma2

Definition at line 63 of file baro_ms5611_i2c.c.

Referenced by alt_kalman(), and baro_ms5611_init().

bool_t baro_ms5611_valid

Definition at line 61 of file baro_ms5611_i2c.c.

Referenced by baro_ms5611_event(), and baro_ms5611_init().