Copter: reject change_command if not in AUTO

This commit is contained in:
Randy Mackay 2013-11-14 13:49:37 +09:00
parent 0778454434
commit 57b291b1c5

View File

@ -4,6 +4,11 @@
//----------------------------------------
static void change_command(uint8_t cmd_index)
{
// check we are in AUTO mode
if (control_mode != AUTO) {
return;
}
// limit range
cmd_index = min(g.command_total - 1, cmd_index);