#pragma once12#include <AP_Logger/LogStructure.h>34#define LOG_IDS_FROM_BARO \5LOG_BARO_MSG, \6LOG_BARD_MSG78// @LoggerMessage: BARO9// @Description: Gathered Barometer data10// @Field: TimeUS: Time since system startup11// @Field: I: barometer sensor instance number12// @Field: Alt: calculated altitude13// @Field: AltAMSL: altitude AMSL14// @Field: Press: measured atmospheric pressure15// @Field: Temp: measured atmospheric temperature16// @Field: CRt: derived climb rate from primary barometer17// @Field: SMS: time last sample was taken18// @Field: Offset: raw adjustment of barometer altitude, zeroed on calibration, possibly set by GCS19// @Field: GndTemp: temperature on ground, specified by parameter or measured while on ground20// @Field: H: true if barometer is considered healthy21// @Field: CPress: compensated atmospheric pressure22struct PACKED log_BARO {23LOG_PACKET_HEADER;24uint64_t time_us;25uint8_t instance;26float altitude;27float altitude_AMSL;28float pressure;29int16_t temperature;30float climbrate;31uint32_t sample_time_ms;32float drift_offset;33float ground_temp;34uint8_t healthy;35float corrected_pressure;36};3738// @LoggerMessage: BARD39// @Description: Barometer dynamic data40// @Field: TimeUS: Time since system startup41// @Field: I: barometer sensor instance number42// @Field: DynPrX: calculated dynamic pressure in the bodyframe X-axis43// @Field: DynPrY: calculated dynamic pressure in the bodyframe Y-axis44// @Field: DynPrZ: calculated dynamic pressure in the bodyframe Z-axis45struct PACKED log_BARD {46LOG_PACKET_HEADER;47uint64_t time_us;48uint8_t instance;49float dyn_pressure_x;50float dyn_pressure_y;51float dyn_pressure_z;52};5354#define LOG_STRUCTURE_FROM_BARO \55{ LOG_BARO_MSG, sizeof(log_BARO), \56"BARO", \57"Q" "B" "f" "f" "f" "c" "f" "I" "f" "f" "B" "f", \58"TimeUS," "I," "Alt," "AltAMSL," "Press," "Temp," "CRt," "SMS," "Offset," "GndTemp," "H," "CPress", \59"s" "#" "m" "m" "P" "O" "n" "s" "m" "O" "-" "P", \60"F" "-" "0" "0" "0" "B" "0" "C" "?" "0" "-" "0", \61true \62}, \63{ LOG_BARD_MSG, sizeof(log_BARD), \64"BARD", \65"Q" "B" "fff", \66"TimeUS," "I," "DynPrX,DynPrY,DynPrZ", \67"s" "#" "PPP", \68"F" "-" "000", \69true \70},717273