mirror of https://github.com/ArduPilot/ardupilot
Allows you to clear the stored mission when in Auto
This commit is contained in:
parent
6228dfb37c
commit
2b06a54fc5
|
@ -112,6 +112,12 @@ static void read_trim_switch()
|
||||||
if(trim_flag){
|
if(trim_flag){
|
||||||
trim_flag = false;
|
trim_flag = false;
|
||||||
|
|
||||||
|
if(control_mode == AUTO){
|
||||||
|
CH7_wp_index = 0;
|
||||||
|
g.command_total.set_and_save(1);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if(CH7_wp_index == 0){
|
if(CH7_wp_index == 0){
|
||||||
// this is our first WP, let's save WP 1 as a takeoff
|
// this is our first WP, let's save WP 1 as a takeoff
|
||||||
// increment index
|
// increment index
|
||||||
|
|
Loading…
Reference in New Issue