From c8e21c194dce367f7c4c59ed2aad803ccebc8173 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Wed, 23 Oct 2013 23:28:07 +1100 Subject: [PATCH] Rover: set system time on GPS lock --- APMrover2/APMrover2.pde | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/APMrover2/APMrover2.pde b/APMrover2/APMrover2.pde index 97eaf5405f..6c12d49527 100644 --- a/APMrover2/APMrover2.pde +++ b/APMrover2/APMrover2.pde @@ -832,6 +832,10 @@ static void update_GPS(void) } else { init_home(); + + // set system clock for log timestamps + hal.util->set_system_clock(g_gps->time_epoch_usec()); + if (g.compass_enabled) { // Set compass declination automatically compass.set_initial_location(g_gps->latitude, g_gps->longitude);