Browse Source

AP_HAL_Linux: ToneAlarm_Raspilot: add fixme comment

master
Lucas De Marchi 9 years ago
parent
commit
4f14b9b7e2
  1. 1
      libraries/AP_HAL_Linux/ToneAlarm_Raspilot.cpp

1
libraries/AP_HAL_Linux/ToneAlarm_Raspilot.cpp

@ -183,6 +183,7 @@ void ToneAlarm_Raspilot::_set_pwm0_duty(uint8_t percent) @@ -183,6 +183,7 @@ void ToneAlarm_Raspilot::_set_pwm0_duty(uint8_t percent)
int bit_count = constrain_int32(320 * percent / 100, 320, 0);
unsigned int bits = 0;
// FIXME: bits overflows for any bit_count > 32
while (bit_count) {
bits <<= 1;
bits |= 1;

Loading…
Cancel
Save