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/ArduCopter/config.h
Views: 1798
1
//
2
#pragma once
3
4
//////////////////////////////////////////////////////////////////////////////
5
//////////////////////////////////////////////////////////////////////////////
6
//
7
// WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
8
//
9
// DO NOT EDIT this file to adjust your configuration. Create your own
10
// APM_Config.h and use APM_Config.h.example as a reference.
11
//
12
// WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
13
///
14
//////////////////////////////////////////////////////////////////////////////
15
//////////////////////////////////////////////////////////////////////////////
16
//
17
// Default and automatic configuration details.
18
//
19
// Notes for maintainers:
20
//
21
// - Try to keep this file organised in the same order as APM_Config.h.example
22
//
23
#include "defines.h"
24
25
///
26
/// DO NOT EDIT THIS INCLUDE - if you want to make a local change, make that
27
/// change in your local copy of APM_Config.h.
28
///
29
#include "APM_Config.h"
30
#include <AP_ADSB/AP_ADSB_config.h>
31
#include <AP_Follow/AP_Follow_config.h>
32
#include <AC_Avoidance/AC_Avoidance_config.h>
33
34
//////////////////////////////////////////////////////////////////////////////
35
//////////////////////////////////////////////////////////////////////////////
36
// HARDWARE CONFIGURATION AND CONNECTIONS
37
//////////////////////////////////////////////////////////////////////////////
38
//////////////////////////////////////////////////////////////////////////////
39
40
#ifndef CONFIG_HAL_BOARD
41
#error CONFIG_HAL_BOARD must be defined to build ArduCopter
42
#endif
43
44
#ifndef ARMING_DELAY_SEC
45
# define ARMING_DELAY_SEC 2.0f
46
#endif
47
48
//////////////////////////////////////////////////////////////////////////////
49
// FRAME_CONFIG
50
//
51
#ifndef FRAME_CONFIG
52
# define FRAME_CONFIG MULTICOPTER_FRAME
53
#endif
54
55
/////////////////////////////////////////////////////////////////////////////////
56
// TradHeli defaults
57
#if FRAME_CONFIG == HELI_FRAME
58
# define RC_FAST_SPEED 125
59
# define WP_YAW_BEHAVIOR_DEFAULT WP_YAW_BEHAVIOR_LOOK_AHEAD
60
#endif
61
62
//////////////////////////////////////////////////////////////////////////////
63
// PWM control
64
// default RC speed in Hz
65
#ifndef RC_FAST_SPEED
66
# define RC_FAST_SPEED 490
67
#endif
68
69
//////////////////////////////////////////////////////////////////////////////
70
// Rangefinder
71
//
72
73
#ifndef RANGEFINDER_FILT_DEFAULT
74
# define RANGEFINDER_FILT_DEFAULT 0.5f // filter for rangefinder distance
75
#endif
76
77
#ifndef SURFACE_TRACKING_TIMEOUT_MS
78
# define SURFACE_TRACKING_TIMEOUT_MS 1000 // surface tracking target alt will reset to current rangefinder alt after this many milliseconds without a good rangefinder alt
79
#endif
80
81
#ifndef MAV_SYSTEM_ID
82
# define MAV_SYSTEM_ID 1
83
#endif
84
85
// prearm GPS hdop check
86
#ifndef GPS_HDOP_GOOD_DEFAULT
87
# define GPS_HDOP_GOOD_DEFAULT 140 // minimum hdop that represents a good position. used during pre-arm checks if fence is enabled
88
#endif
89
90
// missing terrain data failsafe
91
#ifndef FS_TERRAIN_TIMEOUT_MS
92
#define FS_TERRAIN_TIMEOUT_MS 5000 // 5 seconds of missing terrain data will trigger failsafe (RTL)
93
#endif
94
95
// pre-arm baro vs inertial nav max alt disparity
96
#ifndef PREARM_MAX_ALT_DISPARITY_CM
97
# define PREARM_MAX_ALT_DISPARITY_CM 100 // barometer and inertial nav altitude must be within this many centimeters
98
#endif
99
100
//////////////////////////////////////////////////////////////////////////////
101
// EKF Failsafe
102
#ifndef FS_EKF_ACTION_DEFAULT
103
# define FS_EKF_ACTION_DEFAULT FS_EKF_ACTION_LAND // EKF failsafe triggers land by default
104
#endif
105
#ifndef FS_EKF_THRESHOLD_DEFAULT
106
# define FS_EKF_THRESHOLD_DEFAULT 0.8f // EKF failsafe's default compass and velocity variance threshold above which the EKF failsafe will be triggered
107
#endif
108
109
#ifndef EKF_ORIGIN_MAX_ALT_KM
110
# define EKF_ORIGIN_MAX_ALT_KM 50 // EKF origin and home must be within 50km vertically
111
#endif
112
113
#ifndef FS_EKF_FILT_DEFAULT
114
# define FS_EKF_FILT_DEFAULT 5.0f // frequency cutoff of EKF variance filters
115
#endif
116
117
//////////////////////////////////////////////////////////////////////////////
118
// Auto Tuning
119
#ifndef AUTOTUNE_ENABLED
120
# define AUTOTUNE_ENABLED 1
121
#endif
122
123
//////////////////////////////////////////////////////////////////////////////
124
// Nav-Guided - allows external nav computer to control vehicle
125
#ifndef AC_NAV_GUIDED
126
# define AC_NAV_GUIDED 1
127
#endif
128
129
//////////////////////////////////////////////////////////////////////////////
130
// Acro - fly vehicle in acrobatic mode
131
#ifndef MODE_ACRO_ENABLED
132
# define MODE_ACRO_ENABLED 1
133
#endif
134
135
//////////////////////////////////////////////////////////////////////////////
136
// Auto mode - allows vehicle to trace waypoints and perform automated actions
137
#ifndef MODE_AUTO_ENABLED
138
# define MODE_AUTO_ENABLED 1
139
#endif
140
141
//////////////////////////////////////////////////////////////////////////////
142
// Brake mode - bring vehicle to stop
143
#ifndef MODE_BRAKE_ENABLED
144
# define MODE_BRAKE_ENABLED 1
145
#endif
146
147
//////////////////////////////////////////////////////////////////////////////
148
// Circle - fly vehicle around a central point
149
#ifndef MODE_CIRCLE_ENABLED
150
# define MODE_CIRCLE_ENABLED 1
151
#endif
152
153
//////////////////////////////////////////////////////////////////////////////
154
// Drift - fly vehicle in altitude-held, coordinated-turn mode
155
#ifndef MODE_DRIFT_ENABLED
156
# define MODE_DRIFT_ENABLED 1
157
#endif
158
159
//////////////////////////////////////////////////////////////////////////////
160
// flip - fly vehicle in flip in pitch and roll direction mode
161
#ifndef MODE_FLIP_ENABLED
162
# define MODE_FLIP_ENABLED 1
163
#endif
164
165
//////////////////////////////////////////////////////////////////////////////
166
// Follow - follow another vehicle or GCS
167
#ifndef MODE_FOLLOW_ENABLED
168
#if AP_FOLLOW_ENABLED && AP_AVOIDANCE_ENABLED
169
#define MODE_FOLLOW_ENABLED 1
170
#else
171
#define MODE_FOLLOW_ENABLED 0
172
#endif
173
#endif
174
175
//////////////////////////////////////////////////////////////////////////////
176
// Guided mode - control vehicle's position or angles from GCS
177
#ifndef MODE_GUIDED_ENABLED
178
# define MODE_GUIDED_ENABLED 1
179
#endif
180
181
//////////////////////////////////////////////////////////////////////////////
182
// GuidedNoGPS mode - control vehicle's angles from GCS
183
#ifndef MODE_GUIDED_NOGPS_ENABLED
184
# define MODE_GUIDED_NOGPS_ENABLED 1
185
#endif
186
187
//////////////////////////////////////////////////////////////////////////////
188
// Loiter mode - allows vehicle to hold global position
189
#ifndef MODE_LOITER_ENABLED
190
# define MODE_LOITER_ENABLED 1
191
#endif
192
193
//////////////////////////////////////////////////////////////////////////////
194
// Position Hold - enable holding of global position
195
#ifndef MODE_POSHOLD_ENABLED
196
# define MODE_POSHOLD_ENABLED 1
197
#endif
198
199
//////////////////////////////////////////////////////////////////////////////
200
// RTL - Return To Launch
201
#ifndef MODE_RTL_ENABLED
202
# define MODE_RTL_ENABLED 1
203
#endif
204
205
//////////////////////////////////////////////////////////////////////////////
206
// SmartRTL - allows vehicle to retrace a (loop-eliminated) breadcrumb home
207
#ifndef MODE_SMARTRTL_ENABLED
208
# define MODE_SMARTRTL_ENABLED 1
209
#endif
210
211
//////////////////////////////////////////////////////////////////////////////
212
// Sport - fly vehicle in rate-controlled (earth-frame) mode
213
#ifndef MODE_SPORT_ENABLED
214
# define MODE_SPORT_ENABLED 0
215
#endif
216
217
//////////////////////////////////////////////////////////////////////////////
218
// System ID - conduct system identification tests on vehicle
219
#ifndef MODE_SYSTEMID_ENABLED
220
# define MODE_SYSTEMID_ENABLED HAL_LOGGING_ENABLED
221
#endif
222
223
//////////////////////////////////////////////////////////////////////////////
224
// Throw - fly vehicle after throwing it in the air
225
#ifndef MODE_THROW_ENABLED
226
# define MODE_THROW_ENABLED 1
227
#endif
228
229
//////////////////////////////////////////////////////////////////////////////
230
// ZigZag - allow vehicle to fly in a zigzag manner with predefined point A B
231
#ifndef MODE_ZIGZAG_ENABLED
232
# define MODE_ZIGZAG_ENABLED 1
233
#endif
234
235
//////////////////////////////////////////////////////////////////////////////
236
// Turtle - allow vehicle to be flipped over after a crash
237
#ifndef MODE_TURTLE_ENABLED
238
# define MODE_TURTLE_ENABLED HAL_DSHOT_ENABLED && FRAME_CONFIG != HELI_FRAME
239
#endif
240
241
//////////////////////////////////////////////////////////////////////////////
242
// Flowhold - use optical flow to hover in place
243
#ifndef MODE_FLOWHOLD_ENABLED
244
# define MODE_FLOWHOLD_ENABLED AP_OPTICALFLOW_ENABLED
245
#endif
246
247
//////////////////////////////////////////////////////////////////////////////
248
249
//////////////////////////////////////////////////////////////////////////////
250
// Weathervane - allow vehicle to yaw into wind
251
#ifndef WEATHERVANE_ENABLED
252
# define WEATHERVANE_ENABLED 1
253
#endif
254
255
//////////////////////////////////////////////////////////////////////////////
256
257
//////////////////////////////////////////////////////////////////////////////
258
// Autorotate - autonomous auto-rotation - helicopters only
259
#ifndef MODE_AUTOROTATE_ENABLED
260
#if CONFIG_HAL_BOARD == HAL_BOARD_SITL
261
#if FRAME_CONFIG == HELI_FRAME
262
#ifndef MODE_AUTOROTATE_ENABLED
263
# define MODE_AUTOROTATE_ENABLED 1
264
#endif
265
#else
266
# define MODE_AUTOROTATE_ENABLED 0
267
#endif
268
#else
269
# define MODE_AUTOROTATE_ENABLED 0
270
#endif
271
#endif
272
273
//////////////////////////////////////////////////////////////////////////////
274
// RADIO CONFIGURATION
275
//////////////////////////////////////////////////////////////////////////////
276
//////////////////////////////////////////////////////////////////////////////
277
278
279
//////////////////////////////////////////////////////////////////////////////
280
// FLIGHT_MODE
281
//
282
283
#ifndef FLIGHT_MODE_1
284
# define FLIGHT_MODE_1 Mode::Number::STABILIZE
285
#endif
286
#ifndef FLIGHT_MODE_2
287
# define FLIGHT_MODE_2 Mode::Number::STABILIZE
288
#endif
289
#ifndef FLIGHT_MODE_3
290
# define FLIGHT_MODE_3 Mode::Number::STABILIZE
291
#endif
292
#ifndef FLIGHT_MODE_4
293
# define FLIGHT_MODE_4 Mode::Number::STABILIZE
294
#endif
295
#ifndef FLIGHT_MODE_5
296
# define FLIGHT_MODE_5 Mode::Number::STABILIZE
297
#endif
298
#ifndef FLIGHT_MODE_6
299
# define FLIGHT_MODE_6 Mode::Number::STABILIZE
300
#endif
301
302
303
//////////////////////////////////////////////////////////////////////////////
304
// Throttle Failsafe
305
//
306
#ifndef FS_THR_VALUE_DEFAULT
307
# define FS_THR_VALUE_DEFAULT 975
308
#endif
309
310
//////////////////////////////////////////////////////////////////////////////
311
// Takeoff
312
//
313
#ifndef PILOT_TKOFF_ALT_DEFAULT
314
# define PILOT_TKOFF_ALT_DEFAULT 0 // default final alt above home for pilot initiated takeoff
315
#endif
316
317
318
//////////////////////////////////////////////////////////////////////////////
319
// Landing
320
//
321
#ifndef LAND_SPEED
322
# define LAND_SPEED 50 // the descent speed for the final stage of landing in cm/s
323
#endif
324
#ifndef LAND_REPOSITION_DEFAULT
325
# define LAND_REPOSITION_DEFAULT 1 // by default the pilot can override roll/pitch during landing
326
#endif
327
#ifndef LAND_WITH_DELAY_MS
328
# define LAND_WITH_DELAY_MS 4000 // default delay (in milliseconds) when a land-with-delay is triggered during a failsafe event
329
#endif
330
#ifndef LAND_CANCEL_TRIGGER_THR
331
# define LAND_CANCEL_TRIGGER_THR 700 // land is cancelled by input throttle above 700
332
#endif
333
#ifndef LAND_RANGEFINDER_MIN_ALT_CM
334
#define LAND_RANGEFINDER_MIN_ALT_CM 200
335
#endif
336
337
//////////////////////////////////////////////////////////////////////////////
338
// Landing Detector
339
//
340
#ifndef LAND_DETECTOR_TRIGGER_SEC
341
# define LAND_DETECTOR_TRIGGER_SEC 1.0f // number of seconds to detect a landing
342
#endif
343
#ifndef LAND_AIRMODE_DETECTOR_TRIGGER_SEC
344
# define LAND_AIRMODE_DETECTOR_TRIGGER_SEC 3.0f // number of seconds to detect a landing in air mode
345
#endif
346
#ifndef LAND_DETECTOR_MAYBE_TRIGGER_SEC
347
# define LAND_DETECTOR_MAYBE_TRIGGER_SEC 0.2f // number of seconds that means we might be landed (used to reset horizontal position targets to prevent tipping over)
348
#endif
349
#ifndef LAND_DETECTOR_ACCEL_LPF_CUTOFF
350
# define LAND_DETECTOR_ACCEL_LPF_CUTOFF 1.0f // frequency cutoff of land detector accelerometer filter
351
#endif
352
#ifndef LAND_DETECTOR_ACCEL_MAX
353
# define LAND_DETECTOR_ACCEL_MAX 1.0f // vehicle acceleration must be under 1m/s/s
354
#endif
355
#ifndef LAND_DETECTOR_VEL_Z_MAX
356
# define LAND_DETECTOR_VEL_Z_MAX 1.0f // vehicle vertical velocity must be under 1m/s
357
#endif
358
359
//////////////////////////////////////////////////////////////////////////////
360
// Flight mode definitions
361
//
362
363
// Acro Mode
364
#ifndef ACRO_LEVEL_MAX_ANGLE
365
# define ACRO_LEVEL_MAX_ANGLE 3000 // maximum lean angle in trainer mode measured in centidegrees
366
#endif
367
368
#ifndef ACRO_LEVEL_MAX_OVERSHOOT
369
# define ACRO_LEVEL_MAX_OVERSHOOT 1000 // maximum overshoot angle in trainer mode when full roll or pitch stick is held in centidegrees
370
#endif
371
372
#ifndef ACRO_BALANCE_ROLL
373
#define ACRO_BALANCE_ROLL 1.0f
374
#endif
375
376
#ifndef ACRO_BALANCE_PITCH
377
#define ACRO_BALANCE_PITCH 1.0f
378
#endif
379
380
#ifndef ACRO_RP_EXPO_DEFAULT
381
#define ACRO_RP_EXPO_DEFAULT 0.3f // ACRO roll and pitch expo parameter default
382
#endif
383
384
#ifndef ACRO_Y_EXPO_DEFAULT
385
#define ACRO_Y_EXPO_DEFAULT 0.0f // ACRO yaw expo parameter default
386
#endif
387
388
#ifndef ACRO_THR_MID_DEFAULT
389
#define ACRO_THR_MID_DEFAULT 0.0f
390
#endif
391
392
#ifndef ACRO_RP_RATE_DEFAULT
393
#define ACRO_RP_RATE_DEFAULT 360 // ACRO roll and pitch rotation rate parameter default in deg/s
394
#endif
395
396
#ifndef ACRO_Y_RATE_DEFAULT
397
#define ACRO_Y_RATE_DEFAULT 202.5 // ACRO yaw rotation rate parameter default in deg/s
398
#endif
399
400
// RTL Mode
401
#ifndef RTL_ALT_FINAL
402
# define RTL_ALT_FINAL 0 // the altitude, in cm, the vehicle will move to as the final stage of Returning to Launch. Set to zero to land.
403
#endif
404
405
#ifndef RTL_ALT
406
# define RTL_ALT 1500 // default alt to return to home in cm, 0 = Maintain current altitude
407
#endif
408
409
#ifndef RTL_ALT_MIN
410
# define RTL_ALT_MIN 30 // min height above ground for RTL (i.e 30cm)
411
#endif
412
413
#ifndef RTL_CLIMB_MIN_DEFAULT
414
# define RTL_CLIMB_MIN_DEFAULT 0 // vehicle will always climb this many cm as first stage of RTL
415
#endif
416
417
#ifndef RTL_CONE_SLOPE_DEFAULT
418
# define RTL_CONE_SLOPE_DEFAULT 3.0f // slope of RTL cone (height / distance). 0 = No cone
419
#endif
420
421
#ifndef RTL_MIN_CONE_SLOPE
422
# define RTL_MIN_CONE_SLOPE 0.5f // minimum slope of cone
423
#endif
424
425
#ifndef RTL_LOITER_TIME
426
# define RTL_LOITER_TIME 5000 // Time (in milliseconds) to loiter above home before beginning final descent
427
#endif
428
429
// AUTO Mode
430
#ifndef WP_YAW_BEHAVIOR_DEFAULT
431
# define WP_YAW_BEHAVIOR_DEFAULT WP_YAW_BEHAVIOR_LOOK_AT_NEXT_WP_EXCEPT_RTL
432
#endif
433
434
#ifndef YAW_LOOK_AHEAD_MIN_SPEED
435
# define YAW_LOOK_AHEAD_MIN_SPEED 100 // minimum ground speed in cm/s required before copter is aimed at ground course
436
#endif
437
438
// Super Simple mode
439
#ifndef SUPER_SIMPLE_RADIUS
440
# define SUPER_SIMPLE_RADIUS 1000
441
#endif
442
443
//////////////////////////////////////////////////////////////////////////////
444
// Stabilize Rate Control
445
//
446
#ifndef ROLL_PITCH_YAW_INPUT_MAX
447
# define ROLL_PITCH_YAW_INPUT_MAX 4500 // roll, pitch and yaw input range
448
#endif
449
#ifndef DEFAULT_ANGLE_MAX
450
# define DEFAULT_ANGLE_MAX 3000 // ANGLE_MAX parameters default value
451
#endif
452
453
//////////////////////////////////////////////////////////////////////////////
454
// Stop mode defaults
455
//
456
#ifndef BRAKE_MODE_SPEED_Z
457
# define BRAKE_MODE_SPEED_Z 250 // z-axis speed in cm/s in Brake Mode
458
#endif
459
#ifndef BRAKE_MODE_DECEL_RATE
460
# define BRAKE_MODE_DECEL_RATE 750 // acceleration rate in cm/s/s in Brake Mode
461
#endif
462
463
//////////////////////////////////////////////////////////////////////////////
464
// PosHold parameter defaults
465
//
466
#ifndef POSHOLD_BRAKE_RATE_DEFAULT
467
# define POSHOLD_BRAKE_RATE_DEFAULT 8 // default POSHOLD_BRAKE_RATE param value. Rotation rate during braking in deg/sec
468
#endif
469
#ifndef POSHOLD_BRAKE_ANGLE_DEFAULT
470
# define POSHOLD_BRAKE_ANGLE_DEFAULT 3000 // default POSHOLD_BRAKE_ANGLE param value. Max lean angle during braking in centi-degrees
471
#endif
472
473
//////////////////////////////////////////////////////////////////////////////
474
// Pilot control defaults
475
//
476
477
#ifndef THR_DZ_DEFAULT
478
# define THR_DZ_DEFAULT 100 // the deadzone above and below mid throttle while in althold or loiter
479
#endif
480
481
// default maximum vertical velocity and acceleration the pilot may request
482
#ifndef PILOT_VELZ_MAX
483
# define PILOT_VELZ_MAX 250 // maximum vertical velocity in cm/s
484
#endif
485
#ifndef PILOT_ACCEL_Z_DEFAULT
486
# define PILOT_ACCEL_Z_DEFAULT 250 // vertical acceleration in cm/s/s while altitude is under pilot control
487
#endif
488
489
#ifndef PILOT_Y_RATE_DEFAULT
490
# define PILOT_Y_RATE_DEFAULT 202.5 // yaw rotation rate parameter default in deg/s for all mode except ACRO
491
#endif
492
#ifndef PILOT_Y_EXPO_DEFAULT
493
# define PILOT_Y_EXPO_DEFAULT 0.0 // yaw expo parameter default for all mode except ACRO
494
#endif
495
496
#ifndef AUTO_DISARMING_DELAY
497
# define AUTO_DISARMING_DELAY 10
498
#endif
499
500
//////////////////////////////////////////////////////////////////////////////
501
// Throw mode configuration
502
//
503
#ifndef THROW_HIGH_SPEED
504
# define THROW_HIGH_SPEED 500.0f // vehicle much reach this total 3D speed in cm/s (or be free falling)
505
#endif
506
#ifndef THROW_VERTICAL_SPEED
507
# define THROW_VERTICAL_SPEED 50.0f // motors start when vehicle reaches this total 3D speed in cm/s
508
#endif
509
510
//////////////////////////////////////////////////////////////////////////////
511
// Logging control
512
//
513
514
// Default logging bitmask
515
#ifndef DEFAULT_LOG_BITMASK
516
# define DEFAULT_LOG_BITMASK \
517
MASK_LOG_ATTITUDE_MED | \
518
MASK_LOG_GPS | \
519
MASK_LOG_PM | \
520
MASK_LOG_CTUN | \
521
MASK_LOG_NTUN | \
522
MASK_LOG_RCIN | \
523
MASK_LOG_IMU | \
524
MASK_LOG_CMD | \
525
MASK_LOG_CURRENT | \
526
MASK_LOG_RCOUT | \
527
MASK_LOG_OPTFLOW | \
528
MASK_LOG_COMPASS | \
529
MASK_LOG_CAMERA | \
530
MASK_LOG_MOTBATT
531
#endif
532
533
//////////////////////////////////////////////////////////////////////////////
534
// Fence, Rally and Terrain and AC_Avoidance defaults
535
//
536
537
#if MODE_FOLLOW_ENABLED && !AP_AVOIDANCE_ENABLED
538
#error Follow Mode relies on AP_AVOIDANCE_ENABLED which is disabled
539
#endif
540
541
#if MODE_AUTO_ENABLED && !MODE_GUIDED_ENABLED
542
#error ModeAuto requires ModeGuided which is disabled
543
#endif
544
545
#if MODE_AUTO_ENABLED && !MODE_CIRCLE_ENABLED
546
#error ModeAuto requires ModeCircle which is disabled
547
#endif
548
549
#if MODE_AUTO_ENABLED && !MODE_RTL_ENABLED
550
#error ModeAuto requires ModeRTL which is disabled
551
#endif
552
553
#if FRAME_CONFIG == HELI_FRAME && !MODE_ACRO_ENABLED
554
#error Helicopter frame requires acro mode support which is disabled
555
#endif
556
557
#if MODE_SMARTRTL_ENABLED && !MODE_RTL_ENABLED
558
#error SmartRTL requires ModeRTL which is disabled
559
#endif
560
561
#if HAL_ADSB_ENABLED && !MODE_GUIDED_ENABLED
562
#error ADSB requires ModeGuided which is disabled
563
#endif
564
565
#if MODE_FOLLOW_ENABLED && !MODE_GUIDED_ENABLED
566
#error Follow requires ModeGuided which is disabled
567
#endif
568
569
#if MODE_GUIDED_NOGPS_ENABLED && !MODE_GUIDED_ENABLED
570
#error ModeGuided-NoGPS requires ModeGuided which is disabled
571
#endif
572
573
//////////////////////////////////////////////////////////////////////////////
574
// Developer Items
575
//
576
577
#ifndef AP_COPTER_ADVANCED_FAILSAFE_ENABLED
578
# define AP_COPTER_ADVANCED_FAILSAFE_ENABLED 0
579
#endif
580
581
#ifndef CH_MODE_DEFAULT
582
# define CH_MODE_DEFAULT 5
583
#endif
584
585
#ifndef TOY_MODE_ENABLED
586
#define TOY_MODE_ENABLED 0
587
#endif
588
589
#if TOY_MODE_ENABLED && FRAME_CONFIG == HELI_FRAME
590
#error Toy mode is not available on Helicopters
591
#endif
592
593
#ifndef HAL_FRAME_TYPE_DEFAULT
594
#define HAL_FRAME_TYPE_DEFAULT AP_Motors::MOTOR_FRAME_TYPE_X
595
#endif
596
597
#ifndef AC_CUSTOMCONTROL_MULTI_ENABLED
598
#define AC_CUSTOMCONTROL_MULTI_ENABLED FRAME_CONFIG == MULTICOPTER_FRAME && AP_CUSTOMCONTROL_ENABLED
599
#endif
600
601
#ifndef AC_PAYLOAD_PLACE_ENABLED
602
#define AC_PAYLOAD_PLACE_ENABLED 1
603
#endif
604
605
#ifndef USER_PARAMS_ENABLED
606
#define USER_PARAMS_ENABLED 0
607
#endif
608
609