36 #if USE_BARO_MEDIAN_FILTER
46 #if USE_BARO_MEDIAN_FILTER
67 x3 = ((x1 + x2) + 2) >> 2;
70 int32_t p = b7 < 0x80000000L ? (b7 * 2) / b4 : (b7 / b4) * 2;
71 x1 = (
p >> 8) * (
p >> 8);
72 x1 = (x1 * 3038UL) >> 16;
73 x2 = (-7357L *
p) >> 16;
74 int32_t press =
p + ((x1 + x2 + 3791L) >> 4);
101 #if USE_BARO_MEDIAN_FILTER
104 float pressure = (float)press_pascal;
Main include for ABI (AirBorneInterface).
#define BARO_BOARD_SENDER_ID
default onboard baro
#define BMP180_OSS
Use an extra median filter to filter baro data.
static int32_t baro_apply_calibration(int32_t raw)
Apply temperature and sensor calibration to get pressure in Pa.
static int32_t baro_apply_calibration_temp(int32_t tmp_raw)
Apply temperature calibration.
void ardrone_baro_event(void)
Common barometric sensor implementation.
uint32_t get_sys_time_usec(void)
Get the time in microseconds since startup.
ardrone2 navdata aquisition driver.
struct bmp180_calib_t bmp180_calib
BMP180 calibration receieved from navboard.
struct navdata_measure_t measure
Main navdata packet receieved from navboard.
bool baro_calibrated
Whenever the baro is calibrated.
bool baro_available
Whenever the baro is available.
uint16_t temperature_pressure
int int32_t
Typedef defining 32 bit int type.
unsigned int uint32_t
Typedef defining 32 bit unsigned int type.