MCF548x Reference Manual, Rev. 3
27-36 Freescale Semiconductor
Figure 27-23. Tx FIFO Pointers and Counter

27.8.4.1 Address Calculation for the First-in Entry and Last-in Entry in the Tx FIFO

The memory address of the first-in entry in the Tx FIFO is computed by the following equation:
First-in entry address = Tx FIFO base + 4*(TXPTR)
The memory address of the last-in entry in the Tx FIFO is computed by the following equation:
Last-in entry address = Tx FIFO base + 4*[(TXCTR + TXPTR - 1)modulo 4]
Tx FIFO base - Base address of Tx FIFO
TXCTR - Tx FIFO counter
TXTPTR - Transmit pointer

27.8.4.2 Address Calculation for the First-in Entry and Last-in Entry in the Rx

FIFO

The memory address of the first-in entry in the Rx FIFO is computed by the following equation:
First-in entry address = Rx FIFO Base + 4*(RXPTR)
The memory address of the last-in entry in the Rx FIFO is computed by the following equation:
Last-in entry address = Rx FIFO base + 4*[(RXCTR + RXPTR - 1)modulo 4]
Rx FIFO base - Base address of RX FIFO
RXCTR - Rx FIFO counter
RXPTR - Receive pointer
Entry C
Entry A (First In)
– 1
Entry B
Entry D (Last In)
Tx FIFO Base
Tx FIFO Counter
Shift Register DSPISOUT
Transmit Data
Pointer
+ 1
Tx FIFO Register