The driver fsl_lpspi.c fails to send a series of single byte TX/RX transfers in a row. The first transfer happens, the following ones are not sent.
The attached example uses the transfer b2b polling file as template, so don't be confused by the name. It attempts to send a single byte TX only , then two bytes TX/RX, then again a single byte TX only so four bytes in total. It sends two bytes.
If after each TX/RX transfer a short delay is added, like 20µs, all works well. Analyzing the flags in the Status register shows, that the transfer is not yet completed when TransferBlocking returns.
Tested with a MIMXRT1020_EVK board, but it fails with other boards as well.
The driver fsl_lpspi.c fails to send a series of single byte TX/RX transfers in a row. The first transfer happens, the following ones are not sent. The attached example uses the transfer b2b polling file as template, so don't be confused by the name. It attempts to send a single byte TX only , then two bytes TX/RX, then again a single byte TX only so four bytes in total. It sends two bytes. If after each TX/RX transfer a short delay is added, like 20µs, all works well. Analyzing the flags in the Status register shows, that the transfer is not yet completed when TransferBlocking returns.
Tested with a MIMXRT1020_EVK board, but it fails with other boards as well.
lpspi_polling_b2b_transfer_master.zip