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.

TMS320F28035: SPI communication between master(TMS320F28035) and slave (DRV8323RS)

Part Number: TMS320F28035
Other Parts Discussed in Thread: DRV8323

Hi TI Team,

We have referred the Control Suite example for establishing SPI communication. But the available example talks about only loopback operation. We require the DSP to perform read/write operations on DRV8323. 

Our Requirements:

1. Write to the OCP register in DRV8323 to change one of the fault mode.

2. Monitor(Read) the faults on DRV8323 device.

My Code:

sdata = 0x2919;
spi_xmit(sdata);
for(;;)
{
asm(" NOP");
// Transmit data
sdata = 0x8000;
spi_xmit(sdata);
// Wait until data is received
while(SpibRegs.SPIFFRX.bit.RXFFST !=1) { }
// Check against sent data
rdata = SpibRegs.SPIRXBUF;
}

But the above code doesn't seem to be working. 

Please check and reply.

Thanks,

Nikhila