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.

doubt in spi programming of TMDXEVM6678

Hi,

     I have small doubt about the output of this program(spi programming of TMDXEVM6678), please help me.

/-----------------------------------------------------/

#include <c6x.h>
#include <stdint.h>
#include <evmc66x_spi.h>
#include <platform_internal.h>
#include <cslr_spi.h>
#include <platform.h>
SPI_STATUS status;
void main(void) {

status=spi_claim(0,2000000);
while(1){
printf("data \n");
SPI_SPIDAT0 = 0x00005555;
spi_delay(10000);


}
// spi_release();
}

/----------------------------------------------------/

For this source code, I am not getting the clock  output of spi_clk pin (69 pin of 80 pin test header). and I am not getting data output at spi_SIMO pin.

Please help me and if correction for my code please inform me.

Thank you, waiting for reply.

regards,

chandu.

  • Chandu,

    Are you using 6678 EVM please? I think in C6678 EVM, SPI /CS0 is connected to NOR flash and /CS1 is connected to FPGA. 

    You can refer to "evmc66x_nor.c" below to see how SPI is used to access NOR flash.

    "C:\ti\pdk_C6678_1_1_2_5\packages\ti\platform\evmc6678l\platform_lib\src

    And "platforms_utils_test.c" also has NOR flash testing using SPI ("TEST_NOR"), which is located at

    C:\ti\pdk_C6678_1_1_2_5\packages\ti\platform\evmc6678l\platform_test\src

    Hope they could help with your testing.