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.

CCS/TMS320F28335: Questions about the F28335-to-PC and F28335-to-F28335 Communications

Part Number: TMS320F28335

Tool/software: Code Composer Studio

Dear Mark and Gautam

Thank you very much for your answers to my questions in the thread "What else chips I need to integrate in my own board in order to use the TI F28335 ControlCard?". Now I have further questions based on that.

Can you please also talk about MCU-to-MCU communication? In my project, I need to use four F28335 MCUs (ControlCards) among which there is a MCU (I call it Master MCU) will be in charge of sending/receiving information to/from PC. The other three MCUs will send/receive information to the Master one first and then the PC can see that information through the Master F28335.

For this project, I want to try easy things on the MCU-to-MCU first. That is, if I connect two F28335 MCUs (with the TI USB Docking Station instead of using my own boards that will be developed) to PC, can I just use one CCS to control these two MCUs? If this can be done, then I think I can do the MCU-to-PC communication for the two F28335 MCUs, and then exchange their information within the CCS. If this can be performed, then I can go ahead to think about the MCU-to-MCU communication without the help from the PC.

Can you please help me on the above? Thank you so much for your time.

Lin 

  • Lin,

    Are you trying to debug both devices at the same time using Code Composer Studio, or just using the UART Output (COMs) to control the devices?

    If you aren't debugging, you should be able to see both devices come up as com ports, and should be able to use a terminal application to connect to each C2000.

    Regards,

    Vince Rodriguez
  • Hi, Vince

    I am not quite sure what my case belongs to. Basically, in my project, one F28335's ADC pins are not enough (although there are totally 16 (A0~A7 and B0~B7)). Thus I need multiple F28335 MCUs. I will sense different signal using different MCUs respectively, and then send all those to a Master F28335 MCU to be processed. In order to do this, I need to know how to exchange messages between two F28335 MCUs firstly using one CCS, one PC, two F28335 MCUs that are connected to the PC through USB.

    After the above is known, then I will try to burn/flash codes into the two F28335 MCUs such that they can run on the application boards that I will develop without the help of the CCS located in the PC. These two F28335 MCUs need to be able to communicate to each other to send/receive messages, again, without the PC.

    My target is to have four F28335 MCUs working together in one PCB board that I will develop. Once the 5V power is given, then the pre-burned/flashed code in the four MCUs will run automatically. The running results will be sent only through one F28335 MCU (I call it Master MCU) to PC only for LabVIEW curve plotting purpose. That is to say, even without that PC, the four F28335 MCUs should still be able to run for my application (because the code had been burned/flashed into their ROMs).

    Do you know if the F28335-to-PC and F28335-to-F28335 communication issues are discussed somewhere in the controSuite? Or in some application notes that you can refer to for me to learn?

    Thanks.

    Lin

  • Lin,

    How many ADC channels do you need? do you need 64 different pins for all different sensors? I'm thinking you don't, but are unsure how to sample each different pin that is available on one device.

    Take a look at the below:
    www.ti.com/.../spru812a.pdf

    It should have some useful info about the ADC.

    Thanks,

    Vince Rodriguez
  • Lin,

    Again here you have a few options. You could use the SPI peripheral, and hook up the Clock and data lines together with independent chip selects. Be sure to use use the TALK feature of the SPI to ensure that the SOMI lines do not contend with each other. You might also look into using the I2C. it is a slower bit rate, but you have addressable slaves so the master can just round-robin through all of them requesting data on demand. McBSP is also similar to SPI, and can be used to implement a TDM bus (Time division Multiplex) where each node will transmit a burst of data in a predefined time-slot.

    This is a fairly standard design scheme when using microcontrollers. My recommendations above are just a few of the possibilities that you can use with the F28335, there is also CAN, but I think that it will require too much overhead to make an on-board ADC sample aggregator worth the cost.

    Thanks,
    Mark
  • Mark Labbato said:
    Lin,

    Again here you have a few options. You could use the SPI peripheral, and hook up the Clock and data lines together with independent chip selects. Be sure to use use the TALK feature of the SPI to ensure that the SOMI lines do not contend with each other. You might also look into using the I2C. it is a slower bit rate, but you have addressable slaves so the master can just round-robin through all of them requesting data on demand. McBSP is also similar to SPI, and can be used to implement a TDM bus (Time division Multiplex) where each node will transmit a burst of data in a predefined time-slot.

    This is a fairly standard design scheme when using microcontrollers. My recommendations above are just a few of the possibilities that you can use with the F28335, there is also CAN, but I think that it will require too much overhead to make an on-board ADC sample aggregator worth the cost.

    Thanks,
    Mark

    Hi, Mark

    Thank you so much for your note. It really helps. Now, I still have one question regarding the Clock signal between the four F28335 chips I will use. You said in your message that "You could use the SPI peripheral, and hook up the Clock and data lines together with independent chip selects." What does that mean? Does it mean that we should connect all slave F28335s' clock signal (in my case, three F28335 work as slaves and one works as Master) together to a chip, which can choose which clock signal to be used for being synchronized with the Master F28335? If this is the case, would not it be that this chip is just kind of a MUX? Can you please help me on that?

    Thanks.

    Lin

  • Lin,

    Please refer to this thread : e2e.ti.com/.../591822 I drew out a sample connection for a single master/multiple slave configuration. Wikipedia has a few examples as well for how this would work.

    Simply, all SPICLK, SPISIMO, and SPISOMI lines are connected together. The Master has individual GPIOs connected to each slave that act as Chip Select to enable the specific slave it is requesting data from.

    Does this make sense?

    -Mark
  • Hi, Mark

    Thank you so much for the reply. That chart quite helps and I get it now.

    Lin