Question
Bug in HAL_SPI F3 V1.5 Library HAL_SPI_Receive_DMA
Posted on August 05, 2016 at 05:17
The implementation of HAL_SPI_Receive_DMA() assumes that the Transmit is also DMA and uses HAL_SPI_TransmitReceive_DMA() internally which tries to write to a non-existent Tx DMA transfer complete callback (line 1622 of stm32f3xx_hal_spi.c) causing a hard fault.
I've run out of DMA channels so I don't have the option of using DMA transmit.I would suggest that HAL_SPI_TransmitReceive_DMA() is modified to check the existence of the transmit (and/or receive) buffer and NOT try and write to non-existent variables.