spi interface on a TI MSC1211Y5

Dear all,

First of all happy New Year.

The project I'm working on, involves programming TI's MSC1211Y5 microcontroller in C language, to interface with a number of other chips on the pcb.

One of the functionalities the program is to have, is to receive short range telemetry data (from a telemetry module). Once the data is received, it is supposed to be sent to the Microcontroller via the SPI interface. For this, the telemetry module is the master and the MSC microcontroller is configured as a slave. Unfortunately the microcontroller doesn't send any bytes, I've verified this by outputting the tx buffer on a console window and on an oscilloscope. However it is able to correctly receive bytes of data from the telemetry module (the oscilloscope trace corresponds to the rx buffer data output on the console window). The telemetry module provides the clock for the exchange, and I've verified on an oscilloscope that it appears when it should. I've also checked the way the microcontrollers pins and registers are setup and they seem correct.

The code that I'm using is similar to the examples given on TI's datasheets.

I was wondering if anyone had any experience in troubleshooting spi interfaces? I've been stuck on this problem for over 2 weeks and any help would be very much appreciated.

Thanks in advance for your help,

Regards,

Alan

Reply to
a.ball
Loading thread data ...

I've another question. Can an spi slave transmit a byte?

Thanks again,

Alan

Reply to
a.ball

Yes, if it's configured for bidirectional (i.e., full-duplex) operation, and the slave knows to load its byte into the shift register _before_ the master starts clocking it.

formatting link

Good Luck! Rich

Reply to
Rich Grise

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.