DataFlash: log baro climbrate

This commit is contained in:
Randy Mackay 2014-10-22 16:29:25 +09:00
parent 0d2954b5a4
commit 5cbcbf9b37
2 changed files with 3 additions and 1 deletions
libraries/DataFlash

View File

@ -251,6 +251,7 @@ struct PACKED log_BARO {
float altitude;
float pressure;
int16_t temperature;
float climbrate;
};
struct PACKED log_AHRS {
@ -431,7 +432,7 @@ struct PACKED log_Ubx2 {
{ LOG_RCOUT_MSG, sizeof(log_RCOUT), \
"RCOU", "Ihhhhhhhh", "TimeMS,Chan1,Chan2,Chan3,Chan4,Chan5,Chan6,Chan7,Chan8" }, \
{ LOG_BARO_MSG, sizeof(log_BARO), \
"BARO", "Iffc", "TimeMS,Alt,Press,Temp" }, \
"BARO", "Iffcf", "TimeMS,Alt,Press,Temp,CRt" }, \
{ LOG_POWR_MSG, sizeof(log_POWR), \
"POWR","ICCH","TimeMS,Vcc,VServo,Flags" }, \
{ LOG_CMD_MSG, sizeof(log_Cmd), \

View File

@ -763,6 +763,7 @@ void DataFlash_Class::Log_Write_Baro(AP_Baro &baro)
altitude : baro.get_altitude(),
pressure : baro.get_pressure(),
temperature : (int16_t)(baro.get_temperature() * 100),
climbrate : baro.get_climb_rate()
};
WriteBlock(&pkt, sizeof(pkt));
}