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.

SSI Slave Master only 0x00

Other Parts Discussed in Thread: CC1200

Hello,

I have a board with 2 processors:

1. TM4C123 (SSI MASTER)

2. CC1200 (SSI SLAVE)

8 bit mode 125000bitrate.

I am sending bytes from the master to the slave.

MASTER RXFF interrupt I receive the data with SSIDataGet,

But all I get is always 0x00, What can be the problem ?

#define TRXEM_SPI_TX(x) do{ SSIDataPut(SSI3_BASE, x); }while(0);
#define TRXEM_SPI_END() do{ __asm__("nop"); GPIOPinWrite(SPI_PORT_BASE, NSS_PIN, NSS_PIN);}while(0);
void SSI_PinConfig(void)
{
// Enable Peripheral Clocks
SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOD);
SysCtlPeripheralEnable(SYSCTL_PERIPH_SSI3);

GPIOPinTypeGPIOOutput(GPIO_PORTD_BASE, NSS_PIN); // Making the SSI3Fss as GPIO type

SSIDisable(SSI3_BASE);

// Enable pin PD2 for SSI3 SSI3RX
GPIOPinConfigure(GPIO_PD2_SSI3RX);
GPIOPinTypeSSI(GPIO_PORTD_BASE, GPIO_PIN_2);

// Enable pin PD0 for SSI3 SSI3CLK
GPIOPinConfigure(GPIO_PD0_SSI3CLK);
GPIOPinTypeSSI(GPIO_PORTD_BASE, GPIO_PIN_0);

// Enable pin PD3 for SSI3 SSI3TX
GPIOPinConfigure(GPIO_PD3_SSI3TX);
GPIOPinTypeSSI(GPIO_PORTD_BASE, GPIO_PIN_3);
}

void RF_SpiInterfaceInit(void)
{
SSI_PinConfig();
SSIClockSourceSet(SSI3_BASE, SSI_CLOCK_SYSTEM);

SSIConfigSetExpClk(SSI3_BASE, SysCtlClockGet(), SSI_FRF_MOTO_MODE_0,SSI_MODE_MASTER, 125000, 8);// defines base, System clk, Mode 0 = SPH = SPO = 0,Master, 125 KHz, no. of bits = 8 = 1 byte transfer

//SSIConfigSetExpClk(SSI3_BASE, SysCtlClockGet(), SSI_FRF_MOTO_MODE_0, SSI_MODE_MASTER, 1000000, 8);
SSIEnable(SSI3_BASE);
SysCtlDelay(100000);

TRXEM_SPI_END();
SysCtlDelay(100000);
}

uint8_t spi_put(uint32_t Data)
{
uint32_t rxData;

TRXEM_SPI_BEGIN();
SSIDataPut(SSI3_BASE, Data);
SSIDataGet(SSI3_BASE, &rxData);
printf("put = %08lX\n", Data);
printf("get = %08lX\n", rxData);
TRXEM_SPI_END();

return rxData;
}

  • DongHoon Kang said:
    But all I get is always 0x00, What can be the problem ?

    The possibilities are numerous.

    What does your oscilloscope or logic analyzer show on your I/O lines?

    Robert

    Also don't spam the tags. It makes them useless