IMX8MP ECSPI Slave Mode receive data issue

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

IMX8MP ECSPI Slave Mode receive data issue

295 Views
sophie-wang
Contributor III

Hello NXP Expert,

I wrote a program to test the slave function of the IMX8MP ECSPI2 peripheral, running on the M7 core side. The version number of SDK I use is SDK_2_11_1, and the development board I use is EVK-MIMX8MP. The slave uses the default configuration (ECSPI_SlaveGetDefaultConfig, burstLength set to and uses ECSPI_SlaveTransferNonBlocking to receive data from the master. The testing process found some problems, hope the expert can answer.

Test scenario:
Set the slave burstLength to 8 (the master also sets the burstLength to 8), and the master sends eight consecutive bytes (0x11, 0x22, 0x33, 0x44, 0x55, 0x66, 0x77, 0x88) to the slave. The slave reads only two data 0x11 and 0x22334455.

Question:
1. Why did the slave not receive the data 0x66, 0x77, and 0x88 sent by the master?
2. With burstLength set to 8, why doesn't the slave interrupt every byte it receives (the first interrupt receives one byte (0x11) and the second interrupt receives four bytes (0x22334455))?

I tried to set the burstLength of the slave to 16 (the burstLength of the master to 8), and received the first data 0x1122 and the second data 0x33445566. I found that the length of the first data was equal to burstLength each time. But the second data must be 4 bytes to trigger the interrupt. Is there a hardware limitation or is there a problem with the parameters I configured?

0 Kudos
0 Replies