mirror of https://github.com/ArduPilot/ardupilot
AP_NMEA_Output: fix time format
This commit is contained in:
parent
e855c9f46a
commit
81ab6a9461
|
@ -111,8 +111,8 @@ void AP_NMEA_Output::update()
|
|||
struct tm* tm = gmtime(&time_sec);
|
||||
|
||||
// format time string
|
||||
char tstring[11];
|
||||
snprintf(tstring, sizeof(tstring), "%02u%02u%06.2f", tm->tm_hour, tm->tm_min, tm->tm_sec + (time_usec % 1000000) * 1.0e-6);
|
||||
char tstring[10];
|
||||
snprintf(tstring, sizeof(tstring), "%02u%02u%05.2f", tm->tm_hour, tm->tm_min, tm->tm_sec + (time_usec % 1000000) * 1.0e-6);
|
||||
|
||||
Location loc;
|
||||
const auto &gps = AP::gps();
|
||||
|
|
Loading…
Reference in New Issue