ArduCopter: do_set_servo fix to resolve -1 being assigned to uint8_t

This commit is contained in:
rmackay9 2012-12-07 12:58:44 +09:00
parent 47af1fd255
commit 8378de6d8c
1 changed files with 2 additions and 2 deletions

View File

@ -791,7 +791,7 @@ static void do_set_home()
static void do_set_servo()
{
uint8_t channel_num = -1;
uint8_t channel_num = 0xff;
switch( command_cond_queue.p1 ) {
case 1:
@ -830,7 +830,7 @@ static void do_set_servo()
}
// send output to channel
if (channel_num != -1) {
if (channel_num != 0xff) {
APM_RC.enable_out(channel_num);
APM_RC.OutputCh(channel_num, command_cond_queue.alt);
}