mirror of https://github.com/ArduPilot/ardupilot
DataFlash: log health and primary for airspeed
This commit is contained in:
parent
eba0e43912
commit
d7bbf9bf66
|
@ -1783,7 +1783,9 @@ void DataFlash_Class::Log_Write_Airspeed(AP_Airspeed &airspeed)
|
||||||
temperature : (int16_t)(temperature * 100.0f),
|
temperature : (int16_t)(temperature * 100.0f),
|
||||||
rawpressure : airspeed.get_corrected_pressure(i),
|
rawpressure : airspeed.get_corrected_pressure(i),
|
||||||
offset : airspeed.get_offset(i),
|
offset : airspeed.get_offset(i),
|
||||||
use : airspeed.use(i)
|
use : airspeed.use(i),
|
||||||
|
healthy : airspeed.healthy(i),
|
||||||
|
primary : airspeed.get_primary()
|
||||||
};
|
};
|
||||||
WriteBlock(&pkt, sizeof(pkt));
|
WriteBlock(&pkt, sizeof(pkt));
|
||||||
}
|
}
|
||||||
|
|
|
@ -698,6 +698,8 @@ struct PACKED log_AIRSPEED {
|
||||||
float rawpressure;
|
float rawpressure;
|
||||||
float offset;
|
float offset;
|
||||||
bool use;
|
bool use;
|
||||||
|
bool healthy;
|
||||||
|
uint8_t primary;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct PACKED log_ACCEL {
|
struct PACKED log_ACCEL {
|
||||||
|
@ -916,6 +918,9 @@ struct PACKED log_Proximity {
|
||||||
#define CURR_CELL_LABELS "TimeUS,Volt,V1,V2,V3,V4,V5,V6,V7,V8,V9,V10"
|
#define CURR_CELL_LABELS "TimeUS,Volt,V1,V2,V3,V4,V5,V6,V7,V8,V9,V10"
|
||||||
#define CURR_CELL_FMT "QfHHHHHHHHHH"
|
#define CURR_CELL_FMT "QfHHHHHHHHHH"
|
||||||
|
|
||||||
|
#define ARSP_LABELS "TimeUS,Airspeed,DiffPress,Temp,RawPress,Offset,U,Health,Primary"
|
||||||
|
#define ARSP_FMT "QffcffBBB"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Format characters in the format string for binary log messages
|
Format characters in the format string for binary log messages
|
||||||
b : int8_t
|
b : int8_t
|
||||||
|
@ -980,9 +985,9 @@ Format characters in the format string for binary log messages
|
||||||
{ LOG_TRIGGER_MSG, sizeof(log_Camera), \
|
{ LOG_TRIGGER_MSG, sizeof(log_Camera), \
|
||||||
"TRIG", "QIHLLeeeccC","TimeUS,GPSTime,GPSWeek,Lat,Lng,Alt,RelAlt,GPSAlt,Roll,Pitch,Yaw" }, \
|
"TRIG", "QIHLLeeeccC","TimeUS,GPSTime,GPSWeek,Lat,Lng,Alt,RelAlt,GPSAlt,Roll,Pitch,Yaw" }, \
|
||||||
{ LOG_ARSP_MSG, sizeof(log_AIRSPEED), \
|
{ LOG_ARSP_MSG, sizeof(log_AIRSPEED), \
|
||||||
"ARSP", "QffcffB", "TimeUS,Airspeed,DiffPress,Temp,RawPress,Offset,U" }, \
|
"ARSP", ARSP_FMT, ARSP_LABELS }, \
|
||||||
{ LOG_ASP2_MSG, sizeof(log_AIRSPEED), \
|
{ LOG_ASP2_MSG, sizeof(log_AIRSPEED), \
|
||||||
"ASP2", "QffcffB", "TimeUS,Airspeed,DiffPress,Temp,RawPress,Offset,U" }, \
|
"ASP2", ARSP_FMT, ARSP_LABELS }, \
|
||||||
{ LOG_CURRENT_MSG, sizeof(log_Current), \
|
{ LOG_CURRENT_MSG, sizeof(log_Current), \
|
||||||
"BAT", CURR_FMT,CURR_LABELS }, \
|
"BAT", CURR_FMT,CURR_LABELS }, \
|
||||||
{ LOG_CURRENT2_MSG, sizeof(log_Current), \
|
{ LOG_CURRENT2_MSG, sizeof(log_Current), \
|
||||||
|
|
Loading…
Reference in New Issue