AP_Notify: ensure dshot LEDs work with EDT ESCs

This commit is contained in:
Andy Piper 2023-10-08 21:14:52 +01:00 committed by Andrew Tridgell
parent 2a9c2fdf14
commit e024f9fc8c
1 changed files with 2 additions and 1 deletions

View File

@ -23,7 +23,8 @@ extern const AP_HAL::HAL& hal;
bool DShotLED::hw_set_rgb(uint8_t red, uint8_t green, uint8_t blue) bool DShotLED::hw_set_rgb(uint8_t red, uint8_t green, uint8_t blue)
{ {
// don't play the motor LEDs while flying // don't play the motor LEDs while flying
if (hal.util->get_soft_armed() || hal.rcout->get_dshot_esc_type() != AP_HAL::RCOutput::DSHOT_ESC_BLHELI) { if (hal.util->get_soft_armed() || (hal.rcout->get_dshot_esc_type() != AP_HAL::RCOutput::DSHOT_ESC_BLHELI
&& hal.rcout->get_dshot_esc_type() != AP_HAL::RCOutput::DSHOT_ESC_BLHELI_EDT)) {
return false; return false;
} }