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.

TMS320F2800157: SPI EEPROM example in C2000Ware 5.04

Part Number: TMS320F2800157
Other Parts Discussed in Thread: C2000WARE, SYSCONFIG

HI,

Just needing a little guideance on the example found in \C2000Ware_5_04_00_00\driverlib\f280015x\examples\spi.

I'm already using SPI0 to talk to a CPLD am using the full SPI FIFO state machine .  In the effor to provide re-progamming of the CPLD configuration EEPROM via another set of pins, I had planned to manually swap over the and wanted the state machine function as well.  I have seen that I was successful in reconfiguring the SPI state machine to use these pins.

I have attempted to use the SPI example referenced above, but got stuck when I saw that it is manually manpulating the CS line.  In debugging, noticed that the CS line was not toggling.  The example manually toggles the GPIO.  Since I have not remapped the CS pin to a GPIO configuration, it stands to reason why I'm not seeing the pin toggle.

Is there any SPI EEPROM example that uses the SPI FIFO state machine automation rather than me having to bit-bang it?

Thanks,

John

  • Hi John, 

    As you mentioned, the spi_ex6_eeprom example has manual GPIO toggling to mimic the CS pin for the SPI instance. We don't have an EEPROM example with automated CS toggling. But you can chose to have to automated by just configuring the CS pin in the sysconfig of the project. The screenshot below shows how to do the same:



    Additionally, you can refer to the Sysconfig of spi_ex1_loopback example to see how to add the CS pin in the SPI instance and not via GPIO. 

    Regards, 
    Pranav Siddappa

  • Hi Pranav,

    I managed to use the example and found that I'd not set the GPIO mux correctly for my CS pin.  Once that was resolved, I learned that when I flipped from my main set of SPI pins to the EEPROM update set, the SPIPOCI must be un-muxed by configuring it back to a GPIO.  It appears that if both are configured as SPIPOCI in the pin mux, they will fight each other. 

    Thanks for the help.

    John