TX FIFO Max
Level
Progammable
Threshold
(TXTRSH)
Zero Byte
DMA TX Active
TXTRSH
Time
Preliminary
Architecture
www.ti.com
Figure 7-13. Transmit FIFO DMA Request Generation (Low Threshold)
Note that also in DMA mode it is possible to have a transfer whose length is not multiple of the
configured FIFO threshold. In this case, the DMA draining feature is also used for transferring the
additional bytes of the transfer (see the Draining Feature subsection for additional details).
According to the desired operation mode, the programmer must set the FIFO thresholds according to
the following table (note that only the OCP side thresholds can be programmed; the I2C side thresholds
are default equals to 1). Note that the thresholds must be set consistent with the DMA channel length.
In I2C Slave RX Mode, the Local Host can program the RX threshold with the desired value, and use
the FIFO draining feature at the end of the I2C transfer to extract from the FIFO the remaining bytes if
the threshold is not reached (see the Draining Feature subsection for additional details).
Note that in I2C Slave TX Mode, the TX FIFO threshold should be set to 1 (I2C_BUF.TXTRSH=0,
default value), since the length of the transfer may not be known at configuration time. In this way, the
interrupt (or accordingly, DMA) requests will be generated for each byte requested by the remote I2C
master to be transferred over the I2C bus. This configuration will prevent the I2C core to request
additional data from the CPU or from the DMA controller (using IRQ or DMA), data that will eventually
not be extracted from the FIFO by the external master (which can use not acknowledge at any time to
end the transfer). If the TX threshold is not set to 1, the module will generate an interrupt or assert a
DMA only when the external master requests a byte and the FIFO is empty. However, in this case the
TX FIFO will require to be cleared at the end of the transfer.
The I2C module offers the possibility to the user to clear the RX or TX FIFO. This is achieved through
I2C_BUF.RXFIFO_CLR and I2C_BUF.TXFIFO_CLR registers, which act like software reset for the
FIFOs. In DMA mode, these bits will also reset the DMA state machines.
The FIFO clearing feature can be used when the module is configured as a transmitter, the external
receiver responds with a NACK in the middle of the transfer, and there is still data in TX FIFO waiting to
be transferred.
On the Functional (I2C) domain, the thresholds can always be considered equal to 1. This means that
the I2C Core can start transferring data on the I2C bus whenever it has data in the FIFOs (FIFO is not
empty).
856
Inter-Integrated Circuit (I2C) Controller Module
SPRUGX9 – 15 April 2011
© 2011, Texas Instruments Incorporated
Содержание TMS320C6A816 Series
Страница 2: ...Preliminary 2 SPRUGX9 15 April 2011 Submit Documentation Feedback 2011 Texas Instruments Incorporated...
Страница 92: ...92 Read This First SPRUGX9 15 April 2011 Submit Documentation Feedback 2011 Texas Instruments Incorporated...
Страница 1122: ...1122 Multichannel Audio Serial Port McASP SPRUGX9 15 April 2011 Submit Documentation Feedback 2011 Texas Instruments Incorporated...
Страница 1562: ...1562 Real Time Clock RTC SPRUGX9 15 April 2011 Submit Documentation Feedback 2011 Texas Instruments Incorporated...
Страница 1658: ...1658 Timers SPRUGX9 15 April 2011 Submit Documentation Feedback 2011 Texas Instruments Incorporated...
Страница 1750: ...1750 UART IrDA CIR Module SPRUGX9 15 April 2011 Submit Documentation Feedback 2011 Texas Instruments Incorporated...
Страница 1984: ...1984 Universal Serial Bus USB SPRUGX9 15 April 2011 Submit Documentation Feedback 2011 Texas Instruments Incorporated...