Skip to content

Commit a56a745

Browse files
321thijs123JaapSkinner
authored andcommitted
fix bidir dshot for nxp xrt boards
Cherry-picked from upstream PX4/PX4-Autopilot PR PX4#25854 Commit: c44e0be Fixes: PX4#25853 When attempting to use bidirectional dshot on NXP i.MXRT boards, esc_status messages would never get published. This was due to bdshot_recv_mask being used to check the number of ready erpms, while this mask is always set to zero before the check. Fixed by checking bdshot_parsed_recv_mask instead.
1 parent 763b287 commit a56a745

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • platforms/nuttx/src/px4/nxp/imxrt/dshot

platforms/nuttx/src/px4/nxp/imxrt/dshot/dshot.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ int up_bdshot_num_erpm_ready(void)
425425
for (unsigned i = 0; i < DSHOT_TIMERS; ++i) {
426426
// We only check that data has been received, rather than if it's valid.
427427
// This ensures data is published even if one channel has bit errors.
428-
if (bdshot_recv_mask & (1 << i)) {
428+
if (bdshot_parsed_recv_mask & (1 << i)) {
429429
++num_ready;
430430
}
431431
}

0 commit comments

Comments
 (0)