rc range bug fixed

git-svn-id: https://arducopter.googlecode.com/svn/trunk@1058 f9c3cf11-9bcb-44bc-f272-b75c42450872
This commit is contained in:
jasonshort 2010-12-06 17:22:05 +00:00
parent 9b3b5320fc
commit 718bf566c8
1 changed files with 1 additions and 1 deletions

View File

@ -157,7 +157,7 @@ RC_Channel::angle_to_pwm()
int16_t
RC_Channel::pwm_to_range()
{
return _low + _high * ((float)(radio_in - radio_min) / (float)(radio_max - radio_min));
return _low + ((_high - _low) * ((float)(radio_in - radio_min) / (float)(radio_max - radio_min)));
}
int16_t