Other Parts Discussed in Thread: HALCOGEN,
Tool/software: Code Composer Studio
Hello,
I am trying to get two SPI ports (SPI 1 and 2) to talk to each other using a hardware connection. Before I go on, my current setup is:
1) I am using HALCoGen v4.07 with CCSv7
2) SPI2 is master and SPI1 is the slave
3) SIMO, SOMI, and CLK are connected, and the nENA pin from SPI2 is connected to nCS[3] of SPI1
4) I changed the pin mode for nENA from "SPI" to "GIO", disabled the the DIR for SOMI on the master and SIMO on the slave, enabled GIO and SPI1/2 drivers, enabled VIM channel for SPI1 low & high signals, and disabled master mode and clock for the slave (SPI1)
Below is all of the code in my sys_main.c:
And here is where my code is essentially failing:
I started with the code provided in example_spi_Master_Slave attempted to alter it to what I need. I've managed to get SPI work using the internal loopback option, but have yet to succeed using a wired connection. I know I probably messed up somewhere in during the setup of this program, but I'm just not sure where to look. I am relatively new to embedded systems and any help/information that could be provided regarding this problem would be greatly appreciated.