Part Number: MSP432P401R
Hi,
Our MSP432P401R Rev D is connected to an SD card using an SPI interface. Our configuration values are shown below:
const eUSCI_SPI_MasterConfig spi_config = {
EUSCI_B_SPI_CLOCKSOURCE_SMCLK, // SMCLK Clock Source
48000000, //SMCLK is 48MHZ
16000000,
EUSCI_B_SPI_MSB_FIRST, // MSB First
EUSCI_B_SPI_PHASE_DATA_CHANGED_ONFIRST_CAPTURED_ON_NEXT, // Phase
EUSCI_B_SPI_CLOCKPOLARITY_INACTIVITY_LOW, // Low polarity
EUSCI_B_SPI_3PIN // 3Wire SPI Mode
};
When I look at the CLK signal that is output from the MSP then it has the correct frequency (16MHz) but the duty cycle is not 50%. The duty cycle is only 32% (20ns High, 42.5ns Low). It seems that as a result of the incorrect duty cycle we are getting data corruption during reads from and writes to the SD card. I've seen the same SPI CLK duty cycle issue reported multiple times in this support forum but I could not find one final solution to this problem. Some responses from the TI support team (to the other postings in the forum) indicate that 24MHz is the maximum allowed value for the SMCLK but other responses from TI support indicate that it is OK to use 48MHz. If it is impossible to get a 16MHz clock with the correct 50% duty cycle then can you please provide the correct values for the SMCLK and SPI CLK that will provide the maximum safe SPI CLK frequency.
Thanks,
Raz