mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-22 08:38:36 -04:00
AP_Rally: log any changes or additions to rally points
This commit is contained in:
parent
9108eeb8f5
commit
542aa4c9e0
@ -2,8 +2,7 @@
|
||||
/// @brief Handles rally point storage and retrieval.
|
||||
#include "AP_Rally.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
extern const AP_HAL::HAL& hal;
|
||||
#include <AP_Logger/AP_Logger.h>
|
||||
|
||||
// storage object
|
||||
StorageAccess AP_Rally::_storage(StorageManager::StorageRally);
|
||||
@ -92,6 +91,11 @@ bool AP_Rally::set_rally_point_with_index(uint8_t i, const RallyLocation &rallyL
|
||||
|
||||
_last_change_time_ms = AP_HAL::millis();
|
||||
|
||||
AP_Logger *logger = AP_Logger::instance();
|
||||
if (logger != nullptr) {
|
||||
logger->Write_RallyPoint(_rally_point_total_count, i, rallyLoc);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user