Tracker: move responsibility for logging into library

This commit is contained in:
Peter Barker 2019-03-25 23:42:51 +11:00 committed by Andrew Tridgell
parent 7de995aa3e
commit 89f43c0318
2 changed files with 1 additions and 3 deletions

View File

@ -30,9 +30,6 @@ void Tracker::update_compass(void)
{
if (AP::compass().enabled() && compass.read()) {
ahrs.set_compass(&compass);
if (should_log(MASK_LOG_COMPASS)) {
logger.Write_Compass();
}
}
}

View File

@ -60,6 +60,7 @@ void Tracker::init_tracker()
#endif // ENABLE_SCRIPTING
// initialise compass
AP::compass().set_log_bit(MASK_LOG_COMPASS);
AP::compass().init();
// GPS Initialization