mirror of https://github.com/ArduPilot/ardupilot
AP_Mount: tidy header includes
our pattern is to include the config file and then use the relevant define, with nothing in between
This commit is contained in:
parent
1e7cd71ad6
commit
99e314f49a
|
@ -1,9 +1,11 @@
|
|||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_ENABLED
|
||||
|
||||
#include <AP_Common/AP_Common.h>
|
||||
#include <AP_Param/AP_Param.h>
|
||||
#include "AP_Mount.h"
|
||||
|
||||
#if HAL_MOUNT_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_Servo.h"
|
||||
#include "AP_Mount_SoloGimbal.h"
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_Alexmos.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_ALEXMOS_ENABLED
|
||||
|
||||
#include "AP_Mount_Alexmos.h"
|
||||
|
||||
#include <AP_SerialManager/AP_SerialManager.h>
|
||||
|
||||
//definition of the commands id for the Alexmos Serial Protocol
|
||||
|
|
|
@ -3,9 +3,12 @@
|
|||
*/
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_ALEXMOS_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_Param/AP_Param.h>
|
||||
#include <AP_Math/AP_Math.h>
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
#include <AP_Logger/AP_Logger.h>
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_Backend_Serial.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend_Serial.h"
|
||||
|
||||
#include <AP_SerialManager/AP_SerialManager.h>
|
||||
|
||||
// Default init function for every mount
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
#include "AP_Mount_Gremsy.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_GREMSY_ENABLED
|
||||
|
||||
#include "AP_Mount_Gremsy.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
|
||||
|
|
|
@ -3,10 +3,12 @@
|
|||
*/
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_GREMSY_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
#include <GCS_MAVLink/GCS_MAVLink.h>
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_SToRM32.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_STORM32MAVLINK_ENABLED
|
||||
|
||||
#include "AP_Mount_SToRM32.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
|
||||
|
|
|
@ -3,10 +3,12 @@
|
|||
*/
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_STORM32MAVLINK_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_SToRM32_serial.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_STORM32SERIAL_ENABLED
|
||||
|
||||
#include "AP_Mount_SToRM32_serial.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <GCS_MAVLink/GCS_MAVLink.h>
|
||||
#include <GCS_MAVLink/include/mavlink/v2.0/checksum.h>
|
||||
|
|
|
@ -3,10 +3,12 @@
|
|||
*/
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend_Serial.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_STORM32SERIAL_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend_Serial.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_Scripting.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_SCRIPTING_ENABLED
|
||||
|
||||
#include "AP_Mount_Scripting.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
|
|
|
@ -4,10 +4,12 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_SCRIPTING_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
|
@ -50,4 +52,4 @@ private:
|
|||
bool target_loc_valid; // true if target_loc holds a valid target location
|
||||
};
|
||||
|
||||
#endif // HAL_MOUNT_SIYISERIAL_ENABLED
|
||||
#endif // HAL_MOUNT_SCRIPTING_ENABLED
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_Servo.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_SERVO_ENABLED
|
||||
|
||||
#include "AP_Mount_Servo.h"
|
||||
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include <GCS_MAVLink/GCS_MAVLink.h>
|
||||
|
||||
|
|
|
@ -3,10 +3,12 @@
|
|||
*/
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_SERVO_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
#include <SRV_Channel/SRV_Channel.h>
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_Siyi.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_SIYI_ENABLED
|
||||
|
||||
#include "AP_Mount_Siyi.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
|
|
|
@ -19,10 +19,12 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend_Serial.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_SIYI_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend_Serial.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
|
@ -381,4 +383,4 @@ private:
|
|||
uint8_t sent_time_count;
|
||||
};
|
||||
|
||||
#endif // HAL_MOUNT_SIYISERIAL_ENABLED
|
||||
#endif // HAL_MOUNT_SIYI_ENABLED
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
#include "AP_Mount_Topotek.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_TOPOTEK_ENABLED
|
||||
|
||||
#include "AP_Mount_Topotek.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_Viewpro.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_VIEWPRO_ENABLED
|
||||
|
||||
#include "AP_Mount_Viewpro.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include <AP_GPS/AP_GPS.h>
|
||||
|
|
|
@ -16,10 +16,12 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend_Serial.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_VIEWPRO_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend_Serial.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#include "AP_Mount_Xacti.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_XACTI_ENABLED
|
||||
|
||||
#include "AP_Mount_Xacti.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
|
|
|
@ -8,10 +8,12 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_MOUNT_XACTI_ENABLED
|
||||
|
||||
#include "AP_Mount_Backend.h"
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_Math/AP_Math.h>
|
||||
#include <AP_Common/AP_Common.h>
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
|
||||
#include <AP_HAL/AP_HAL_Boards.h>
|
||||
#include <AP_Terrain/AP_Terrain_config.h>
|
||||
#include <GCS_MAVLink/GCS_config.h>
|
||||
#include <AP_Scripting/AP_Scripting_config.h>
|
||||
|
||||
#ifndef HAL_MOUNT_ENABLED
|
||||
#define HAL_MOUNT_ENABLED 1
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_SOLO_GIMBAL_ENABLED
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
#include "SoloGimbal.h"
|
||||
|
||||
#if HAL_SOLO_GIMBAL_ENABLED
|
||||
|
||||
#include <stdio.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
#include <AP_Logger/AP_Logger.h>
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_SOLO_GIMBAL_ENABLED
|
||||
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
|
||||
// uncomment this to force the optimisation of this code, note that
|
||||
|
@ -9,7 +13,6 @@
|
|||
#endif
|
||||
|
||||
#include "SoloGimbalEKF.h"
|
||||
#if HAL_SOLO_GIMBAL_ENABLED
|
||||
#include <AP_Param/AP_Param.h>
|
||||
#include <AP_NavEKF/AP_Nav_Common.h>
|
||||
#include <AP_AHRS/AP_AHRS.h>
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
#include "SoloGimbal_Parameters.h"
|
||||
#include "AP_Mount_config.h"
|
||||
|
||||
#if HAL_SOLO_GIMBAL_ENABLED
|
||||
|
||||
#include "SoloGimbal_Parameters.h"
|
||||
#include <AP_HAL/AP_HAL.h>
|
||||
#include <AP_Logger/AP_Logger.h>
|
||||
#include <GCS_MAVLink/GCS.h>
|
||||
|
|
Loading…
Reference in New Issue