|
|
|
@ -33,9 +33,6 @@
@@ -33,9 +33,6 @@
|
|
|
|
|
#include <AP_Common/AP_Common.h> |
|
|
|
|
#include <AP_Param/AP_Param.h> |
|
|
|
|
#include <StorageManager/StorageManager.h> |
|
|
|
|
#include <AP_GPS/AP_GPS.h> // ArduPilot GPS library |
|
|
|
|
#include <AP_Baro/AP_Baro.h> // ArduPilot barometer library |
|
|
|
|
#include <AP_Compass/AP_Compass.h> // ArduPilot Mega Magnetometer Library |
|
|
|
|
#include <AP_Math/AP_Math.h> // ArduPilot Mega Vector/Matrix math Library |
|
|
|
|
#include <AP_InertialSensor/AP_InertialSensor.h> // Inertial Sensor Library |
|
|
|
|
#include <AP_AccelCal/AP_AccelCal.h> // interface and maths for accelerometer calibration |
|
|
|
@ -43,7 +40,6 @@
@@ -43,7 +40,6 @@
|
|
|
|
|
#include <SRV_Channel/SRV_Channel.h> |
|
|
|
|
#include <AP_RangeFinder/AP_RangeFinder.h> // Range finder library |
|
|
|
|
#include <Filter/Filter.h> // Filter library |
|
|
|
|
#include <AP_Relay/AP_Relay.h> // APM relay |
|
|
|
|
#include <AP_Camera/AP_Camera.h> // Photo or video camera |
|
|
|
|
#include <AP_Airspeed/AP_Airspeed.h> |
|
|
|
|
#include <AP_Terrain/AP_Terrain.h> |
|
|
|
@ -55,7 +51,6 @@
@@ -55,7 +51,6 @@
|
|
|
|
|
#include <APM_Control/APM_Control.h> |
|
|
|
|
#include <APM_Control/AP_AutoTune.h> |
|
|
|
|
#include <GCS_MAVLink/GCS_MAVLink.h> // MAVLink GCS definitions |
|
|
|
|
#include <AP_SerialManager/AP_SerialManager.h> // Serial manager library |
|
|
|
|
#include <AP_Mount/AP_Mount.h> // Camera/Antenna mount |
|
|
|
|
#include <AP_Declination/AP_Declination.h> // ArduPilot Mega Declination Helper Library |
|
|
|
|
#include <AP_Logger/AP_Logger.h> |
|
|
|
@ -74,23 +69,17 @@
@@ -74,23 +69,17 @@
|
|
|
|
|
#include <AP_Mission/AP_Mission.h> // Mission command library |
|
|
|
|
|
|
|
|
|
#include <AP_Soaring/AP_Soaring.h> |
|
|
|
|
#include <AP_Notify/AP_Notify.h> // Notify library |
|
|
|
|
#include <AP_BattMonitor/AP_BattMonitor.h> // Battery monitor library |
|
|
|
|
|
|
|
|
|
#include <AP_Arming/AP_Arming.h> |
|
|
|
|
#include <AP_BoardConfig/AP_BoardConfig.h> |
|
|
|
|
#include <AP_BoardConfig/AP_BoardConfig_CAN.h> |
|
|
|
|
#include <AP_Frsky_Telem/AP_Frsky_Telem.h> |
|
|
|
|
#include <AP_OSD/AP_OSD.h> |
|
|
|
|
#include <AP_ServoRelayEvents/AP_ServoRelayEvents.h> |
|
|
|
|
|
|
|
|
|
#include <AP_Rally/AP_Rally.h> |
|
|
|
|
|
|
|
|
|
#include <AP_OpticalFlow/AP_OpticalFlow.h> // Optical Flow library |
|
|
|
|
#include <AP_RSSI/AP_RSSI.h> // RSSI Library |
|
|
|
|
#include <AP_Parachute/AP_Parachute.h> |
|
|
|
|
#include <AP_ADSB/AP_ADSB.h> |
|
|
|
|
#include <AP_Button/AP_Button.h> |
|
|
|
|
#include <AP_ICEngine/AP_ICEngine.h> |
|
|
|
|
#include <AP_Gripper/AP_Gripper.h> |
|
|
|
|
#include <AP_Landing/AP_Landing.h> |
|
|
|
@ -188,42 +177,21 @@ private:
@@ -188,42 +177,21 @@ private:
|
|
|
|
|
// mapping between input channels
|
|
|
|
|
RCMapper rcmap; |
|
|
|
|
|
|
|
|
|
// board specific config
|
|
|
|
|
AP_BoardConfig BoardConfig; |
|
|
|
|
|
|
|
|
|
// board specific config for CAN bus
|
|
|
|
|
#if HAL_WITH_UAVCAN |
|
|
|
|
AP_BoardConfig_CAN BoardConfig_CAN; |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
// primary input channels
|
|
|
|
|
RC_Channel *channel_roll; |
|
|
|
|
RC_Channel *channel_pitch; |
|
|
|
|
RC_Channel *channel_throttle; |
|
|
|
|
RC_Channel *channel_rudder; |
|
|
|
|
|
|
|
|
|
// notification object for LEDs, buzzers etc (parameter set to false disables external leds)
|
|
|
|
|
AP_Notify notify; |
|
|
|
|
|
|
|
|
|
AP_Logger logger; |
|
|
|
|
|
|
|
|
|
// scaled roll limit based on pitch
|
|
|
|
|
int32_t roll_limit_cd; |
|
|
|
|
int32_t pitch_limit_min_cd; |
|
|
|
|
|
|
|
|
|
// Sensors
|
|
|
|
|
AP_GPS gps; |
|
|
|
|
|
|
|
|
|
// flight modes convenience array
|
|
|
|
|
AP_Int8 *flight_modes = &g.flight_mode1; |
|
|
|
|
|
|
|
|
|
AP_Baro barometer; |
|
|
|
|
Compass compass; |
|
|
|
|
|
|
|
|
|
AP_InertialSensor ins; |
|
|
|
|
|
|
|
|
|
RangeFinder rangefinder; |
|
|
|
|
|
|
|
|
|
AP_Vehicle::FixedWing::Rangefinder_State rangefinder_state; |
|
|
|
|
|
|
|
|
|
AP_RPM rpm_sensor; |
|
|
|
@ -271,8 +239,6 @@ private:
@@ -271,8 +239,6 @@ private:
|
|
|
|
|
// external failsafe boards during baro and airspeed calibration
|
|
|
|
|
bool in_calibration; |
|
|
|
|
|
|
|
|
|
AP_SerialManager serial_manager; |
|
|
|
|
|
|
|
|
|
// GCS selection
|
|
|
|
|
GCS_Plane _gcs; // avoid using this; use gcs()
|
|
|
|
|
GCS_Plane &gcs() { return _gcs; } |
|
|
|
@ -283,12 +249,6 @@ private:
@@ -283,12 +249,6 @@ private:
|
|
|
|
|
// selected navigation controller
|
|
|
|
|
AP_SpdHgtControl *SpdHgt_Controller = &TECS_controller; |
|
|
|
|
|
|
|
|
|
// Relay
|
|
|
|
|
AP_Relay relay; |
|
|
|
|
|
|
|
|
|
// handle servo and relay events
|
|
|
|
|
AP_ServoRelayEvents ServoRelayEvents; |
|
|
|
|
|
|
|
|
|
// Camera
|
|
|
|
|
#if CAMERA == ENABLED |
|
|
|
|
AP_Camera camera{MASK_LOG_CAMERA, current_loc}; |
|
|
|
@ -302,9 +262,6 @@ private:
@@ -302,9 +262,6 @@ private:
|
|
|
|
|
// Rally Ponints
|
|
|
|
|
AP_Rally rally; |
|
|
|
|
|
|
|
|
|
// RSSI
|
|
|
|
|
AP_RSSI rssi; |
|
|
|
|
|
|
|
|
|
#if OSD_ENABLED == ENABLED |
|
|
|
|
AP_OSD osd; |
|
|
|
|
#endif |
|
|
|
@ -1098,7 +1055,6 @@ public:
@@ -1098,7 +1055,6 @@ public:
|
|
|
|
|
void failsafe_check(void); |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
extern const AP_HAL::HAL& hal; |
|
|
|
|
extern Plane plane; |
|
|
|
|
|
|
|
|
|
using AP_HAL::millis; |
|
|
|
|