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.

AMC1210 SPI interface problem

Other Parts Discussed in Thread: TM4C1294NCPDT, AMC1210

Hello,

I am currently trying to use the SPI interface in the AMC1210EVM board. I am using a Tiva C tm4c1294ncpdt connected launchpad. The problem is that the EVM is not responding to any commands (The SPIDout stays low all the time)

Here is what I know:

Power: the EVM needs two power supplies, a 3V3 and a 5V and I am providing those from the tm4c launchpad (the picture shows that I am powering the boards because the LEDs light up)

Pinouts: 4 pin SPI interface (picture shows the connections)

Code: I am using the Tivaware APIs and driverlib to setup the SPI interface using SSI2. The settings are: System clock: 25MHz, SSI clock: 1 MHz, master mode, SSI_FRF_MOTO_MODE_1, and 8 bits packages)

void SPI_AMC1210_Write(uint8_t address, uint16_t data){
	uint8_t byte0, byte1, byte2;
	uint32_t ignore;

	byte0 = address;
	byte1 = data >> 8;
	byte2 = data;

	SSIDataPut(SSI2_BASE, byte0);
	SSIDataPut(SSI2_BASE, byte1);
	SSIDataPut(SSI2_BASE, byte2);

	while(SSIBusy(SSI2_BASE)) {} /* Wait until SPI2 is not busy */
	while(MAP_SSIDataGetNonBlocking(SSI2_BASE, &ignore)) {} /* ignore data from the RX FIFO */

	return;
}

uint32_t SPI_AMC1210_Read(uint8_t address){
	uint8_t byte0, byte1, byte2;
	uint32_t responseByte0, responseByte1, responseByte2, response, ignore;

	byte0 = address | (1U << 7); /* write Command bit */
	byte1 = byte2 = 0;

	while(SSIBusy(SSI2_BASE)) {} /* Wait until SPI2 is not busy */

	/* Get any data that is currently in the RX FIFO */
	while(MAP_SSIDataGetNonBlocking(SSI2_BASE, &ignore)) {}

	SSIDataPut(SSI2_BASE, byte0);
	SSIDataPut(SSI2_BASE, byte1);
	SSIDataPut(SSI2_BASE, byte2);

	while(SSIBusy(SSI2_BASE)) {} /* Wait until data is transfered */

	SSIDataGet(SSI2_BASE, &responseByte0);
	SSIDataGet(SSI2_BASE, &responseByte1);
	SSIDataGet(SSI2_BASE, &responseByte2);

	response = (responseByte0 << 16) | (responseByte1 << 8) | responseByte2;

	return response;
}

What I am trying to do is send a write command bit to address 0x06 and write some values to that register to see if I can get them back.

What I tried: I tried connecting the RST line in the EVM and since its active low I just keep it up all the time. I tried connecting the CLK like in the EVM and feed it a 2.5Mhz clock by using a 50% duty cycle PWM.

What I want to know: Am I doing something wrong? what steps should I follow now to try to debug this?

Here is the picture of my EVM and connections. JP9,19, and 16 are open just like the datasheet says.

Here is a picture of the write command, CH1 (yellow) is the clock and blue line is MOSI :

Here is a picture of the whole 24 bit frame:

Here is a picture of the Read command:

Thank You all!!!!