mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-02-20 10:54:14 +01:00
OP-1395 add a vTaskDelay when waiting for dma transfer to complete when using FreeRTOS.
This commit is contained in:
parent
711c3609b6
commit
03d03cfb06
@ -585,6 +585,9 @@ static int32_t SPI_DMA_TransferBlock(uint32_t spi_id, const uint8_t *send_buffer
|
||||
|
||||
/* Wait until all bytes have been transmitted/received */
|
||||
while (DMA_GetCurrDataCounter(spi_dev->cfg->dma.rx.channel)) {
|
||||
#if defined(PIOS_INCLUDE_FREERTOS)
|
||||
vTaskDelay(0);
|
||||
#endif
|
||||
;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user