Quantcast
Viewing all articles
Browse latest Browse all 262198

SSIConfigSetExpClk won't execute

Hi

I'm trying to configure the SSI module on my LM3S811 eval board but the SSIConfigSetExpClk does not execute; I have attached my code. I put code to print to the LCD to see how far the code gets in execution and it does not get past SSIConfigSetExpClk. I cannot figure out why or how. I'm trying to interface with an Inertial Measurement Unit with a 16 bit data, and a 100kHz bit rate from the Inertial Measurement Unit as a slave.

Any help is greatly appreciated,

Thank You

int
main(void)
{

unsigned long ssi_base = SYSCTL_PERIPH_SSI;
unsigned long ulBitRate = 100000;
unsigned long gyroRateX;//Pass to SSIDataGet as reference
unsigned long LED;
LED = 0x05;

//
// Set the clocking to run directly from the crystal.
//
SysCtlClockSet(SYSCTL_SYSDIV_1 | SYSCTL_USE_OSC | SYSCTL_OSC_MAIN |
SYSCTL_XTAL_6MHZ);

//
// Initialize the OLED display.
//
Display96x16x1Init(false);

SysCtlPeripheralEnable(SYSCTL_PERIPH_SSI0);

SSIConfigSetExpClk(ssi_base, SysCtlClockGet(), SSI_FRF_MOTO_MODE_0, SSI_MODE_MASTER, ulBitRate, 8); // 100khz

Display96x16x1StringDraw("Test1", 0, 0);

/*SSIConfigSetExpClk(ssi_base,
ulBitRate*2,
SSI_FRF_MOTO_MODE_0, SSI_MODE_MASTER,
ulBitRate,
16);
*/

SSIEnable(ssi_base);

//SSIDataGet(ssi_base, &gyroRateX);


//
// Finished.
//

Display96x16x1StringDraw("Test2", 0, 0);

SSIDataPut(ssi_base, LED);

Display96x16x1StringDraw("Test3", 0, 0);

SSIDataGet(ssi_base, &gyroRateX);

Display96x16x1StringDraw("Test4", 0, 0);

}


Viewing all articles
Browse latest Browse all 262198

Trending Articles