cancel
Showing results for 
Search instead for 
Did you mean: 

handling of LDMA_TX bit in HAL_SPI_Transmit_DMA

AMacd.1
Senior

According to Page 1354 of rm0394, setting LDMA_TX bit must occur only when SPE=0.

However, from my reading of the function HAL_SPI_Transmit_DMA, this bit may be set or cleared when the DataSize <= 8bit and MemDataAlignment == HALFWORD, even if SPE=1.

This looks like a bug.

Am I correct?

STM32Cube MCU Package for STM32F4 STM32L4, version 1.28.3

1 ACCEPTED SOLUTION

Accepted Solutions
TDK
Super User

Ahh, the L4. I've corrected the OP to refer to STM32L4, not F4, in the text.

Looks like a bug to me.

If you feel a post has answered your question, please click "Accept as Solution".

View solution in original post

6 REPLIES 6
TDK
Super User

Where in the code do you think it's being set? I'm not seeing it.

 

If you feel a post has answered your question, please click "Accept as Solution".

Lines 1965 (clear bit) and 1970 (set bit), stm32l4xx_hal_spi.c

 

and line 1958 (clear bit)

TDK
Super User

Ahh, the L4. I've corrected the OP to refer to STM32L4, not F4, in the text.

Looks like a bug to me.

If you feel a post has answered your question, please click "Accept as Solution".

Whoops!  Yes I meant L4!

Version 1.18.1