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.

TMS320F28335: SPI Communication.

Part Number: TMS320F28335

Hi All,

I am using TMS320F28335 DSP microcontroller for my digitally controlled DC-DC Converter. According to the requirement I need to communicate five converters at a time, and each converters operations are controlled by main master controller.  I am using SPI as my communication protocol.

Observation 1:

In TMS320F28335 DSP microcontroller, I have taken all the mentioned pin from the master and connected to the slave DSP controller (SPI CLK, SPI STE, SPI MISO, SPI MOSI). The slave controller is not properly reading data. 

After shorting the ground (GND) of both DSP microcontroller together, then the slave controller is properly the reading the data of what master has sent through the communication line.

Observation 2:

I can properly communicate the data between the single master and single slave. when I am connecting the second slave into the communication line, both the slaves are having a problem in communication.

In signal level without turning ON the converter power, single master and two slave configuration are working fine. But when I am turning ON the converter power, it is properly working for only one master and one slave. The same configuration doesn't work for single master and two slaves. 

Condition:

1) I have shorted all the microcontrollers ground.

2) I have configured SPI SOMI pin as a continuous high (internal pull up).   

3) I am not using any buffer in the communication line.

If some one aware of this issue, please help me to solve this problem.

Thanks and Regards

Prakash.S

  • Hi Prakash, sorry to hear that you are having some issues with the SPI. I hope that I am able to help you out.

    Regarding observation 1)
    You need that ground connection to provide a return path for the signal you are transmitting! See this pretty simplified summary I found on Stack Exchange explaining why that ground connection is needed: electronics.stackexchange.com/.../sending-ground-along-with-digital-connections-between-boards

    Observation 2)
    Please share a block diagram showing how you are connecting the slaves together. Is it Daisy chain? Star connection? other? In the end, you need to have a dedicated chip select per slave device. I don't know what your slave devices are, but I would assume that they are other MCUs.
    See this search linking to multiple posts on this same topic that have previously be answered before: e2e.ti.com/search

    What does your communication protocol look like? Does the master intend to send data simultaneously to all slaves and not expect return data? does the master need full duplex communication between each slave individually?

    I would also like to see a block diagram of how your boards are connected. It sounds like they are all different boards, likely running all in different power domains (separate power and grounds). You may need to look into using digital isolator chips to help the communications work during DC/DC operation as I am sure there is noise propagating between the boards or that your SPI signals are not clean.

    It would also be beneficial to observe the SPI signals on an oscilloscope during each of these steps. It sounds like a single slave to the master works fine, what do the signals look like when the second slave is connected? What do the signals look like when one DC/DC is powered on?

    Unfortunately the solution won't be as simple as just plugging the boards together through the SPI channel. I know that I asked you a lot of questions above; please think about each of them. They will help you understand your system and how it is working. If You share the things I have asked for, it will help me understand where the issue is.

    -Mark
  • Prakash,

    Its been over a week since your initial post. I am going to assume that you have resolved your issue. If not, please reply with additional information so we can continue the conversation.

    Thanks,
    Mark