mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-15 12:25:20 +03:00
Merge pull request #11053 from mikeller/fix_burst_dshot
This commit is contained in:
commit
33a46010b9
2 changed files with 5 additions and 5 deletions
|
@ -363,10 +363,10 @@ bool pwmDshotMotorHardwareConfig(const timerHardware_t *timerHardware, uint8_t m
|
||||||
motor->timer->timerDmaSources &= ~motor->timerDmaSource;
|
motor->timer->timerDmaSources &= ~motor->timerDmaSource;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!dmaIsConfigured) {
|
|
||||||
xDMA_Cmd(dmaRef, DISABLE);
|
xDMA_Cmd(dmaRef, DISABLE);
|
||||||
xDMA_DeInit(dmaRef);
|
xDMA_DeInit(dmaRef);
|
||||||
|
|
||||||
|
if (!dmaIsConfigured) {
|
||||||
dmaEnable(dmaIdentifier);
|
dmaEnable(dmaIdentifier);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -438,7 +438,7 @@ bool pwmDshotMotorHardwareConfig(const timerHardware_t *timerHardware, uint8_t m
|
||||||
#ifdef USE_DSHOT_DMAR
|
#ifdef USE_DSHOT_DMAR
|
||||||
if (useBurstDshot) {
|
if (useBurstDshot) {
|
||||||
if (!dmaIsConfigured) {
|
if (!dmaIsConfigured) {
|
||||||
dmaSetHandler(dmaIdentifier, motor_DMA_IRQHandler, NVIC_PRIO_DSHOT_DMA, timerIndex);
|
dmaSetHandler(dmaIdentifier, motor_DMA_IRQHandler, NVIC_PRIO_DSHOT_DMA, motor->index);
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -419,7 +419,7 @@ bool pwmDshotMotorHardwareConfig(const timerHardware_t *timerHardware, uint8_t m
|
||||||
#ifdef USE_DSHOT_DMAR
|
#ifdef USE_DSHOT_DMAR
|
||||||
if (useBurstDshot) {
|
if (useBurstDshot) {
|
||||||
if (!dmaIsConfigured) {
|
if (!dmaIsConfigured) {
|
||||||
dmaSetHandler(dmaIdentifier, motor_DMA_IRQHandler, NVIC_PRIO_DSHOT_DMA, timerIndex);
|
dmaSetHandler(dmaIdentifier, motor_DMA_IRQHandler, NVIC_PRIO_DSHOT_DMA, motor->index);
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue