diff --git a/libraries/AP_BLHeli/AP_BLHeli.cpp b/libraries/AP_BLHeli/AP_BLHeli.cpp index 814d7be3c1..bee58f40f9 100644 --- a/libraries/AP_BLHeli/AP_BLHeli.cpp +++ b/libraries/AP_BLHeli/AP_BLHeli.cpp @@ -1377,7 +1377,7 @@ void AP_BLHeli::init(void) AP_Motors *motors = AP::motors(); #endif if (motors) { - uint16_t motormask = motors->get_motor_mask(); + uint32_t motormask = motors->get_motor_mask(); // set the rest of the digital channels if (motors->is_digital_pwm_type()) { digital_mask |= motormask; @@ -1580,7 +1580,7 @@ void AP_BLHeli::update_telemetry(void) break; } } - uint16_t mask = 1U << motor_map[idx]; + uint32_t mask = 1U << motor_map[idx]; if (SRV_Channels::have_digital_outputs(mask)) { hal.rcout->set_telem_request_mask(mask); last_telem_esc = idx; diff --git a/libraries/AP_BLHeli/AP_BLHeli.h b/libraries/AP_BLHeli/AP_BLHeli.h index 53a0a0b9ff..2614cd39ae 100644 --- a/libraries/AP_BLHeli/AP_BLHeli.h +++ b/libraries/AP_BLHeli/AP_BLHeli.h @@ -53,7 +53,7 @@ public: return channel_bidir_dshot_mask.get() & (1U << motor_map[esc_index]); } - uint16_t get_bidir_dshot_mask() const { return channel_bidir_dshot_mask.get(); } + uint32_t get_bidir_dshot_mask() const { return channel_bidir_dshot_mask.get(); } static AP_BLHeli *get_singleton(void) { return _singleton; @@ -232,7 +232,7 @@ private: // have we disabled motor outputs? bool motors_disabled; // mask of channels that should normally be disabled - uint16_t motors_disabled_mask; + uint32_t motors_disabled_mask; // have we locked the UART? bool uart_locked;