Part Number: MSP432E401Y
Tool/software: TI-RTOS
I'd like to confirm my configuration is correct so that I'm running SSI2 in Quad-SPI read mode. It seems I can get at least the SDO0 bit to read properly, but 1-3 don't do anything. Either the GPIO configuration is wrong, the SSI configuration is wrong, or the device I'm operating isn't in QSPI mode like I think (but is as far as I can tell).
Here is my init function:
void initSSI2(void)
{
Types_FreqHz F;
BIOS_getCpuFreq(&F);
MAP_SysCtlPeripheralEnable(SYSCTL_PERIPH_SSI2);
while(!MAP_SysCtlPeripheralReady(SYSCTL_PERIPH_SSI2));
MAP_SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOD);
while(!MAP_SysCtlPeripheralReady(SYSCTL_PERIPH_GPIOD));
MAP_GPIOPinConfigure(GPIO_PD3_SSI2CLK);
MAP_GPIOPinConfigure(GPIO_PD1_SSI2XDAT0);
MAP_GPIOPinConfigure(GPIO_PD0_SSI2XDAT1);
MAP_GPIOPinConfigure(GPIO_PD2_SSI2FSS);
MAP_GPIOPinConfigure(GPIO_PD6_SSI2XDAT3);
MAP_GPIOPinConfigure(GPIO_PD7_SSI2XDAT2);
MAP_GPIOPinTypeSSI(GPIO_PORTD_BASE, GPIO_PIN_3 | GPIO_PIN_1 | GPIO_PIN_0 |
GPIO_PIN_2 | GPIO_PIN_6 | GPIO_PIN_7);
MAP_SSIConfigSetExpClk ( SSI2_BASE,
120e6,
SSI_FRF_MOTO_MODE_0,
SSI_MODE_MASTER,
20e6,
8
);
MAP_SSIAdvModeSet(SSI2_BASE, SSI_ADV_MODE_QUAD_READ);
SSIAdvFrameHoldEnable(SSI2_BASE);
MAP_SSIEnable(SSI2_BASE);
}
I have to first configure the slave device using SSI1 in legacy mode, then disable that entirely and switch over to SSI2. The SSI1 initialization looks very similar, other than the specific pins and the SSI1 vs SSI2 references.
Does this look like the right way to configure it?
How can I verify the GPIO pins are set appropriately (the GPIO_DIR register in debug mode seems to indicate all pins are inputs, but that doesn't make sense)?
