CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
Ardupilot

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.

GitHub Repository: Ardupilot/ardupilot
Path: blob/master/Blimp/defines.h
Views: 1798
1
#pragma once
2
3
#include <AP_HAL/AP_HAL_Boards.h>
4
5
// bit options for DEV_OPTIONS parameter
6
enum DevOptions {
7
DevOptionADSBMAVLink = 1,
8
DevOptionVFR_HUDRelativeAlt = 2,
9
DevOptionSetAttitudeTarget_ThrustAsThrust = 4,
10
};
11
12
// Logging parameters - only 32 messages are available to the vehicle here.
13
enum LoggingParameters {
14
LOG_CONTROL_TUNING_MSG,
15
LOG_DATA_INT16_MSG,
16
LOG_DATA_UINT16_MSG,
17
LOG_DATA_INT32_MSG,
18
LOG_DATA_UINT32_MSG,
19
LOG_DATA_FLOAT_MSG,
20
LOG_PARAMTUNE_MSG,
21
LOG_HELI_MSG,
22
LOG_GUIDEDTARGET_MSG,
23
LOG_SYSIDD_MSG,
24
LOG_SYSIDS_MSG,
25
LOG_FINI_MSG,
26
LOG_FINO_MSG,
27
LOG_PIDD_MSG,
28
LOG_PIVN_MSG,
29
LOG_PIVE_MSG,
30
LOG_PIVD_MSG,
31
LOG_PIVY_MSG,
32
33
};
34
35
#define MASK_LOG_ATTITUDE_FAST (1<<0)
36
#define MASK_LOG_ATTITUDE_MED (1<<1)
37
#define MASK_LOG_GPS (1<<2)
38
#define MASK_LOG_PM (1<<3)
39
#define MASK_LOG_CTUN (1<<4)
40
#define MASK_LOG_NTUN (1<<5)
41
#define MASK_LOG_RCIN (1<<6)
42
#define MASK_LOG_IMU (1<<7)
43
#define MASK_LOG_CMD (1<<8)
44
#define MASK_LOG_CURRENT (1<<9)
45
#define MASK_LOG_RCOUT (1<<10)
46
#define MASK_LOG_OPTFLOW (1<<11)
47
#define MASK_LOG_PID (1<<12)
48
#define MASK_LOG_COMPASS (1<<13)
49
#define MASK_LOG_INAV (1<<14) // deprecated
50
#define MASK_LOG_CAMERA (1<<15)
51
#define MASK_LOG_MOTBATT (1UL<<17)
52
#define MASK_LOG_IMU_FAST (1UL<<18)
53
#define MASK_LOG_IMU_RAW (1UL<<19)
54
#define MASK_LOG_ANY 0xFFFF
55
56
// Radio failsafe definitions (FS_THR parameter)
57
#define FS_THR_DISABLED 0
58
#define FS_THR_ENABLED_ALWAYS_RTL 1
59
#define FS_THR_ENABLED_CONTINUE_MISSION 2 // Removed in 4.0+, now use fs_options
60
#define FS_THR_ENABLED_ALWAYS_LAND 3
61
#define FS_THR_ENABLED_ALWAYS_SMARTRTL_OR_RTL 4
62
#define FS_THR_ENABLED_ALWAYS_SMARTRTL_OR_LAND 5
63
64
// GCS failsafe definitions (FS_GCS_ENABLE parameter)
65
#define FS_GCS_DISABLED 0
66
#define FS_GCS_ENABLED_ALWAYS_RTL 1
67
#define FS_GCS_ENABLED_CONTINUE_MISSION 2 // Removed in 4.0+, now use fs_options
68
#define FS_GCS_ENABLED_ALWAYS_SMARTRTL_OR_RTL 3
69
#define FS_GCS_ENABLED_ALWAYS_SMARTRTL_OR_LAND 4
70
#define FS_GCS_ENABLED_ALWAYS_LAND 5
71
72
// EKF failsafe definitions (FS_EKF_ACTION parameter)
73
#define FS_EKF_ACTION_LAND 1 // switch to LAND mode on EKF failsafe
74
#define FS_EKF_ACTION_LAND_EVEN_MANUAL 3 // switch to Land mode on EKF failsafe even if in Manual mode
75
76
// for PILOT_THR_BHV parameter
77
#define THR_BEHAVE_FEEDBACK_FROM_MID_STICK (1<<0)
78
#define THR_BEHAVE_HIGH_THROTTLE_CANCELS_LAND (1<<1)
79
#define THR_BEHAVE_DISARM_ON_LAND_DETECT (1<<2)
80
81