diff --git a/libraries/DataFlash/LogFile.cpp b/libraries/DataFlash/LogFile.cpp index 2dd06a75d9..440ee0b7b4 100644 --- a/libraries/DataFlash/LogFile.cpp +++ b/libraries/DataFlash/LogFile.cpp @@ -721,7 +721,7 @@ void DataFlash_Class::Log_Write_GPS(const AP_GPS &gps, uint8_t i) latitude : loc.lat, longitude : loc.lng, altitude : loc.alt, - ground_speed : (uint32_t)(gps.ground_speed(i) * 100), + ground_speed : gps.ground_speed(i), ground_course : gps.ground_course_cd(i), vel_z : gps.velocity(i).z, used : (uint8_t)(gps.primary_sensor() == i) diff --git a/libraries/DataFlash/LogStructure.h b/libraries/DataFlash/LogStructure.h index 29086e40a9..aa8635d896 100644 --- a/libraries/DataFlash/LogStructure.h +++ b/libraries/DataFlash/LogStructure.h @@ -52,7 +52,7 @@ struct PACKED log_GPS { int32_t latitude; int32_t longitude; int32_t altitude; - uint32_t ground_speed; + float ground_speed; int32_t ground_course; float vel_z; uint8_t used; @@ -714,9 +714,9 @@ Format characters in the format string for binary log messages { LOG_PARAMETER_MSG, sizeof(log_Parameter), \ "PARM", "QNf", "TimeUS,Name,Value" }, \ { LOG_GPS_MSG, sizeof(log_GPS), \ - "GPS", "QBIHBcLLeEefB", "TimeUS,Status,GMS,GWk,NSats,HDop,Lat,Lng,Alt,Spd,GCrs,VZ,U" }, \ + "GPS", "QBIHBcLLefefB", "TimeUS,Status,GMS,GWk,NSats,HDop,Lat,Lng,Alt,Spd,GCrs,VZ,U" }, \ { LOG_GPS2_MSG, sizeof(log_GPS), \ - "GPS2", "QBIHBcLLeEefB", "TimeUS,Status,GMS,GWk,NSats,HDop,Lat,Lng,Alt,Spd,GCrs,VZ,U" }, \ + "GPS2", "QBIHBcLLefefB", "TimeUS,Status,GMS,GWk,NSats,HDop,Lat,Lng,Alt,Spd,GCrs,VZ,U" }, \ { LOG_GPA_MSG, sizeof(log_GPA), \ "GPA", "QCCCC", "TimeUS,VDop,HAcc,VAcc,SAcc" }, \ { LOG_GPA2_MSG, sizeof(log_GPA), \