This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

RTOS/PROCESSOR-SDK-OMAPL138: Issue with SPI interrupt

Part Number: PROCESSOR-SDK-OMAPL138
Other Parts Discussed in Thread: OMAPL138

Tool/software: TI-RTOS

Hi All,

I am working on omapl138 C674 and using pdk_omapl138_1_0_5. Currently, I am facing an issue with spi interrupt. 

So, I am trying it in loopback mode. When ever I am trying to transfer more than 1byte, control is getting stuck in last byte to receive i.e., receive count is 1 but transmit count is 0. When I stop it in debug mode and make transmit count as 1, I am able to see tx data in rx buffer and control is coming out of the isr.

My spi configurations as follows...

SPI_socGetInitCfg(SPI_INSTANCE, &spi_cfg);

spi_cfg.enableIntr = true;
SPI_socSetInitCfg(SPI_INSTANCE, &spi_cfg);

SPI_Params_init(&spiParams);

SPI_init();

hwHandle = (SPI_Handle)SPI_open(SPI_INSTANCE, &spiParams);

SPI_control(hwHandle,SPI_V0_CMD_LOOPBACK,(void *) &loop);


if (!hwHandle)
{
testPassed = false;
while(1);
}

Task_sleep(1000);

/* Enable transfer */
xferEnable = 1;
SPI_control(hwHandle, SPI_V0_CMD_XFER_ACTIVATE, (void *)&xferEnable);

Then I start with transaction.

Can anyone help me to comeout off this problem?

Thanks...