Browse Source

AP_OSD: fixes bug introduced by #16477

zr-v5.1
Hwurzburg 4 years ago committed by Randy Mackay
parent
commit
8b484738a5
  1. 5
      libraries/AP_OSD/AP_OSD.cpp

5
libraries/AP_OSD/AP_OSD.cpp

@ -423,8 +423,11 @@ void AP_OSD::update_current_screen()
case PWM_RANGE: case PWM_RANGE:
for (int i=0; i<AP_OSD_NUM_SCREENS; i++) { for (int i=0; i<AP_OSD_NUM_SCREENS; i++) {
if (get_screen(i).enabled && get_screen(i).channel_min <= channel_value && get_screen(i).channel_max > channel_value) { if (get_screen(i).enabled && get_screen(i).channel_min <= channel_value && get_screen(i).channel_max > channel_value) {
if (previous_pwm_screen == i) {
break;
} else {
current_screen = previous_pwm_screen = i; current_screen = previous_pwm_screen = i;
break; }
} }
} }
break; break;

Loading…
Cancel
Save