MCU: TM4C1294NCPDT
TI-RTOS: v2.01.00.03
CCS: v6.0.1.0040
Hello,
I successfully ran fatsdusbcopy example provided under TI-RTOS examples for Tiva C on EK-TM4C1294XL Connected LaunchPad. In this given example, the SD card is connected to the SSI2 port, but my actual hardware (that is under development) has SSI0 port assigned for SD card communications.
I am unable to change the necessary sections of the code/drivers that will move the SD card access port from SSI2 to SSI0. Can you please point out which sections of which files need to be changed.
I think that just by changing the following section of code won't help as the SDSPI driver will still try to access the SD card through SSI2 port.
/*
* ======== EK_TM4C1294XL_initSDSPI ========
*/
void EK_TM4C1294XL_initSDSPI(void)
{
/* SDSPI0 configuration */
/* Enable the peripherals used by the SD Card */
SysCtlPeripheralEnable(SYSCTL_PERIPH_SSI2);
/* Configure pad settings */
GPIOPadConfigSet(GPIO_PORTD_BASE,
GPIO_PIN_3 | GPIO_PIN_1,
GPIO_STRENGTH_4MA, GPIO_PIN_TYPE_STD);
GPIOPadConfigSet(GPIO_PORTD_BASE,
GPIO_PIN_0,
GPIO_STRENGTH_4MA, GPIO_PIN_TYPE_STD_WPU);
GPIOPadConfigSet(GPIO_PORTC_BASE,
GPIO_PIN_7,
GPIO_STRENGTH_4MA, GPIO_PIN_TYPE_STD);
GPIOPinConfigure(GPIO_PD3_SSI2CLK);
GPIOPinConfigure(GPIO_PD0_SSI2XDAT1);
GPIOPinConfigure(GPIO_PD1_SSI2XDAT0);
/* SDSPI1 configuration */
/* Enable the peripherals used by the SD Card */
SysCtlPeripheralEnable(SYSCTL_PERIPH_SSI3);
/* Configure pad settings */
GPIOPadConfigSet(GPIO_PORTQ_BASE,
GPIO_PIN_0 | GPIO_PIN_2,
GPIO_STRENGTH_4MA, GPIO_PIN_TYPE_STD);
GPIOPadConfigSet(GPIO_PORTQ_BASE,
GPIO_PIN_3,
GPIO_STRENGTH_4MA, GPIO_PIN_TYPE_STD_WPU);
GPIOPadConfigSet(GPIO_PORTP_BASE,
GPIO_PIN_4,
GPIO_STRENGTH_4MA, GPIO_PIN_TYPE_STD);
GPIOPinConfigure(GPIO_PQ0_SSI3CLK);
GPIOPinConfigure(GPIO_PQ3_SSI3XDAT1);
GPIOPinConfigure(GPIO_PQ2_SSI3XDAT0);
/*
* These GPIOs are connected to PA2 and PA3 and need to be brought into a
* GPIO input state so they don't interfere with SPI communications.
*/
GPIOPinTypeGPIOInput(GPIO_PORTA_BASE, GPIO_PIN_2);
GPIOPinTypeGPIOInput(GPIO_PORTA_BASE, GPIO_PIN_3);
SDSPI_init();
}
Thanks
Regards
Soumyajit