Hi,
I've got some problems with the LSPSI example.
Before sending a SPI trame my TX and RX fifo counter are 0 .
After executing the ligne : LPSPI1->TDR = send; the RX counter has incremented to 1 but not the TX fifo counter ? Can someone explain me why ?
Besides that, I do not understand the ligne : LPSPI1->SR |= LPSPI_SR_TDF_MASK; /* Clear TDF flag */
Because in the RM, this bit seems not writable.
Thanks for your time and answers,
Florian
Solved! Go to Solution.
Hi Florian,
BR, Daniel
I'm sending a SPI frame every second, the first start correctly but after few seconds, the RX fifo is full (nothing is connected on the SDIN pin) and the CS stay low after sending the last frame.
In the example, the flags cleared are in Read only mode, I still don't get it.
Hi Florian,
BR, Daniel
Hi Daniel,
Thanks for your answer, I understood I was receiving some frames on RX so I was reading them just to clear the RXFIFO. But the RXMSK bit you suggested seems to be a better option !
Thanks again
Florian