M4 Coprocessor (of MP15xx) DMA SPI4 example stays in "busy" state after first transmission
Hello,
I'd like to setup a DMA transfer to feed a SPI Display with 8192 bytes per DMA cycle. To offload the MP1 I want to do this with the help of the M4 coprocessor. For my tests I am using the CubeIDE and a custom board. As a basis for learning I tried the example "SPI_FullDuplex_ComDMA_Master". The example (FW_MP1_V1.6.0) itself waits for a keypress and then starts exactly one DMA transfer, I can see the clock pulses on the scope.
Since I need a peridoc refresh of the display, I tried as an experiment to wrap a simple loop together with a delay around the DMA-Send section but for some reason the DMA does not repeat, it gets stuck in a
hspi->State = HAL_SPI_STATE_BUSY_TX_RX
state and the error handler is called.
while(1)
{
if(HAL_SPI_TransmitReceive_DMA(&hspi4, (uint8_t*)aTxBuffer, (uint8_t *)aRxBuffer, BUFFERSIZE) != HAL_OK)
{
Error_Handler();
}
HAL_Delay(50);
}
Why is the "DMA-in-a-loop" not working?
I can increase the time to HAL_Delay(1000) but that makes no difference. Any idea?
