Copter: auto_mode to global scope
This commit is contained in:
parent
7970d7112f
commit
1457a9d31a
@ -549,6 +549,17 @@ static int16_t control_roll; // desired roll angle of copter in centi
|
||||
static int16_t control_pitch; // desired pitch angle of copter in centi-degrees
|
||||
static uint8_t land_state; // records state of land (flying to location, descending)
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Auto
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
static AutoMode auto_mode; // controls which auto controller is run
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// RTL
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
RTLState rtl_state; // records state of rtl (initial climb, returning home, etc)
|
||||
bool rtl_state_complete; // set to true if the current state is completed
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// SIMPLE Mode
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -213,6 +213,15 @@
|
||||
//#define WP_OPTION_ 64
|
||||
#define WP_OPTION_NEXT_CMD 128
|
||||
|
||||
// Auto modes
|
||||
enum AutoMode {
|
||||
Auto_TakeOff,
|
||||
Auto_WP,
|
||||
Auto_Land,
|
||||
Auto_RTL,
|
||||
Auto_Circle
|
||||
};
|
||||
|
||||
// RTL states
|
||||
enum RTLState {
|
||||
Start,
|
||||
|
Loading…
Reference in New Issue
Block a user