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.

TMS320F2808: SPI transmit buffer becoming corrupted when running from Flash

Part Number: TMS320F2808

I am starting to merge several projects together since our project will require the CAN, SPI and I2C (plus others later) communications. I have run all the CAN, SPI and I2C F2808 projects from RAM successfully and now am incorporating into Flash. I started with the SPI and CAN and these were running from Flash. I have since added the I2C project but I am now getting corrupted data.

In the I2cfifo_Interrupts file, there is a TestI2CEEPROM() function in which the TxMsgBuffer is filled with 0x00 to 0x3F. When the I2C_MasterWrite(&EEPROM) is executed, the TxMsgBuffer becomes corrupted and when captured with a Logic Analyzer, the following is observed: Every other 4 bytes are omitted from the write - the 'corrupted' bytes. See the image provided.

I have added pictures and a zip of the code from the CC environment. I also included the DSP280x_common and DSP280x_headers as these are being altered as I merge the projects

Example_F2808_Flash.zip

  • So it seems in my zealousness, I enabled the RXFFRST and TXFFRST in the InitI2C function but the should only be enabled when a Tx or Rx is expected.

    Any further enlightenment on why these are set prior to a tx or rx? How would the controller stay in a 'listen' mode?