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.

[TM4C123GH6PM] SSI fifo size smaller than intended input

Other Parts Discussed in Thread: TM4C123GH6PM

Hi E2E,

I have a sensor I need to implement with the microcontroller (TM4C123GH6PM) that has an SPI output. I do use TivaWare which is awesome, but I happen to run into trouble when I realize that the FIFO buffers 16 bits when the sensor outputs a 32 bit message.

When reading the datasheet for the microcontroller, I find that the receive FIFO is 16-bit wide and 8-locations deep... What does that mean? Can I take advantage of this?

If I were to guess, there must be a way so that once a 16-bit location is full, the next 16 bits from the sensor is stored in the next "adjacent" location. From there, I could use SSIDataGet(), or something to send the whole 32-bit data into a variable.

Help me?

Thanks in advance :)

  • The fifo size means it's got 8 slots with space for 16 bits of data each. The hardware supports transfers of max. 16 bits at a time. But if you manage the FSS (aka chip select) pin "manually" via GPIO calls, you can make two consecutive transfers look like one 32-bit transfer to the sensor. Then, after the transfer, you would read two values off the SSI FIFO and combine them with the proper bitwise operations.
  • Ah I see, that makes sense. I guess when I use the SSIDataGet() function, it grabs the 16-bit of data at the top the FIFO? Because so far, when I call the function, it only returns the first half of the 32-bit data. If I wanted to get the other half, I would need to access the register? (manually, outside of TivaWare it seems)
  • Hello e2e_gai,

    The next SSIDataGet will get the other half of the 32-bit transfer. That is exactly what Veikko mentioned (tow consecutive transfer...)

    Regards
    Amit