Browse Source

AP_Logger: log baro health

master
Andrew Tridgell 6 years ago
parent
commit
0c314c36b6
  1. 1
      libraries/AP_Logger/LogFile.cpp
  2. 9
      libraries/AP_Logger/LogStructure.h

1
libraries/AP_Logger/LogFile.cpp

@ -263,6 +263,7 @@ void AP_Logger::Write_Baro_instance(uint64_t time_us, uint8_t baro_instance, enu @@ -263,6 +263,7 @@ void AP_Logger::Write_Baro_instance(uint64_t time_us, uint8_t baro_instance, enu
sample_time_ms: baro.get_last_update(baro_instance),
drift_offset : drift_offset,
ground_temp : ground_temp,
healthy : (uint8_t)baro.healthy(baro_instance)
};
WriteBlock(&pkt, sizeof(pkt));
}

9
libraries/AP_Logger/LogStructure.h

@ -385,6 +385,7 @@ struct PACKED log_BARO { @@ -385,6 +385,7 @@ struct PACKED log_BARO {
uint32_t sample_time_ms;
float drift_offset;
float ground_temp;
uint8_t healthy;
};
struct PACKED log_Optflow {
@ -1174,10 +1175,10 @@ struct PACKED log_Arm_Disarm { @@ -1174,10 +1175,10 @@ struct PACKED log_Arm_Disarm {
#define ACC_MULTS "FF000"
// see "struct sensor" in AP_Baro.h and "Write_Baro":
#define BARO_LABELS "TimeUS,Alt,Press,Temp,CRt,SMS,Offset,GndTemp"
#define BARO_FMT "QffcfIff"
#define BARO_UNITS "smPOnsmO"
#define BARO_MULTS "F00B0C?0"
#define BARO_LABELS "TimeUS,Alt,Press,Temp,CRt,SMS,Offset,GndTemp,Health"
#define BARO_FMT "QffcfIffB"
#define BARO_UNITS "smPOnsmO-"
#define BARO_MULTS "F00B0C?0-"
#define ESC_LABELS "TimeUS,RPM,Volt,Curr,Temp,CTot"
#define ESC_FMT "QeCCcH"

Loading…
Cancel
Save