diff --git a/ArduPlane/commands_logic.cpp b/ArduPlane/commands_logic.cpp index 6309834ac5..2f3b6344ba 100644 --- a/ArduPlane/commands_logic.cpp +++ b/ArduPlane/commands_logic.cpp @@ -12,13 +12,6 @@ bool Plane::start_command(const AP_Mission::Mission_Command& cmd) plane.target_altitude.terrain_following_pending = false; #endif -#if HAL_LOGGING_ENABLED - // log when new commands start - if (should_log(MASK_LOG_CMD)) { - logger.Write_Mission_Cmd(mission, cmd); - } -#endif - // special handling for nav vs non-nav commands if (AP_Mission::is_nav_cmd(cmd)) { // set takeoff_complete to true so we don't add extra elevator diff --git a/ArduPlane/system.cpp b/ArduPlane/system.cpp index a71e5790c1..b5d412d5fc 100644 --- a/ArduPlane/system.cpp +++ b/ArduPlane/system.cpp @@ -127,6 +127,9 @@ void Plane::init_ardupilot() // initialise mission library mission.init(); +#if HAL_LOGGING_ENABLED + mission.set_log_start_mission_item_bit(MASK_LOG_CMD); +#endif // initialise AP_Logger library #if HAL_LOGGING_ENABLED