DMA Serial Peripheral Interface (DSPI)
MCF52277 Reference Manual, Rev. 1
29-24
Freescale Semiconductor
POPNXTPTR equal to two means that the DSPI_RXFR2 contains the received SPI data that is returned
when DSPI_POPR is read. The POPNXTPTR field increments every time the DSPI_POPR is read.
POPNXTPTR rolls over every four frames on the MCU.
29.4.2.5.1
Filling the RX FIFO
The RX FIFO is filled with the received SPI data from the shift register. While the RX FIFO is not full,
SPI frames from the shift register are transferred to the RX FIFO. Every time an SPI frame is transferred
to the RX FIFO, the RX FIFO counter increments by one.
If the RX FIFO and shift register are full and a transfer is initiated, the DSPI_SR[RFOF] bit is asserted
indicating an overflow condition. Depending on the state of the DSPI_MCR[ROOE] bit, data from the
transfer that generated the overflow is ignored or shifted in to the shift register. If the ROOE bit is set,
incoming data is shifted in to the shift register. If the ROOE bit is cleared, the incoming data is ignored.
29.4.2.5.2
Draining the RX FIFO
Host software or the eDMA can remove (pop) entries from the RX FIFO by reading the DSPI_POPR. For
more information on DSPI_POPR, refer to
Section 29.3.7, “DSPI POP RX FIFO Register (DSPI_POPR)
.
”
A read of the DSPI_POPR decrements the RX FIFO counter by one. Attempts to pop data from an empty
RX FIFO are ignored, and the RX FIFO counter remains unchanged. The data returned from reading an
empty RX FIFO is undetermined.
When the RX FIFO is not empty, the RX FIFO drain flag, DSPI_SR[RFDF], is set. The RFDF bit is
cleared when the RX_FIFO is empty and the eDMA controller indicates that a read from DSPI_POPR is
complete. Alternatively, the RFDF bit can be cleared by software writing a 1 to it.
29.4.3
DSPI Baud Rate and Clock Delay Generation
The DSPI_SCK frequency and the delay values for serial transfer are generated by dividing the system
clock frequency by a prescaler and a scaler with the option of doubling the baud rate.
conceptually how the DSPI_SCK signal is generated.
Figure 29-13. Communications Clock Prescalers and Scalers
29.4.3.1
Baud Rate Generator
The baud rate is the frequency of the serial communication clock (DSPI_SCK). The system clock is
divided by a baud rate prescaler (defined by DSPI_CTAR
n
[PBR]) and baud rate scaler (defined by
DSPI_CTAR
n
[BR]) to produce DSPI_SCK with the possibility of doubling the baud rate. The DBR, PBR,
and BR fields in the DSPI_CTAR
n
select the frequency of DSPI_SCK using the following formula:
Eqn. 29-1
Prescaler
1
Scaler
1+DBR
System Clock
DSPI_SCK
SCK baud rate
f
SYS/2
PBR Prescaler Value
--------------------------------------------------
1
DBR
+
BR Scaler Value
----------------------------------------
×
=
Содержание MCF52277
Страница 1: ...MCF52277 Reference Manual Devices Supported MCF52274 MCF52277 Document Number MCF52277RM Rev 1 04 2008...
Страница 22: ...MCF52277 Reference Manual Rev 1 Freescale Semiconductor xxii...
Страница 32: ...MCF52277 Reference Manual Rev 0 xxxii Freescale Semiconductor...
Страница 60: ...Signal Descriptions MCF52277 Reference Manual Rev 1 2 16 Freescale Semiconductor...
Страница 112: ...Enhanced Multiply Accumulate Unit EMAC MCF52277 Reference Manual Rev 1 4 20 Freescale Semiconductor...
Страница 128: ...Static RAM SRAM MCF52277 Reference Manual Rev 1 6 6 Freescale Semiconductor...
Страница 140: ...Clock Module MCF52277 Reference Manual Rev 1 7 12 Freescale Semiconductor...
Страница 172: ...Chip Configuration Module CCM MCF52277 Reference Manual Rev 1 9 16 Freescale Semiconductor...
Страница 180: ...Serial Boot Facility SBF MCF52277 Reference Manual Rev 1 10 8 Freescale Semiconductor...
Страница 188: ...Reset Controller Module MCF52277 Reference Manual Rev 1 11 8 Freescale Semiconductor...
Страница 210: ...Crossbar Switch XBS MCF52277 Reference Manual Rev 1 13 8 Freescale Semiconductor...
Страница 480: ...Liquid Crystal Display Controller LCDC MCF52277 Reference Manual Rev 1 21 44 Freescale Semiconductor...
Страница 510: ...Touchscreen Controller Analog to Digital Converter MCF52277 Reference Manual Rev 1 22 30 Freescale Semiconductor...
Страница 542: ...FlexCAN MCF52277 Reference Manual Rev 1 23 32 Freescale Semiconductor...
Страница 568: ...Pulse Width Modulation PWM Module MCF52277 Reference Manual Rev 1 24 26 Freescale Semiconductor...
Страница 640: ...Programmable Interrupt Timers PIT0 PIT1 MCF52277 Reference Manual Rev 1 27 8 Freescale Semiconductor...
Страница 690: ...DMA Serial Peripheral Interface DSPI MCF52277 Reference Manual Rev 1 29 40 Freescale Semiconductor...
Страница 724: ...UART Modules MCF52277 Reference Manual Rev 1 30 34 Freescale Semiconductor...
Страница 740: ...I2 C Interface MCF52277 Reference Manual Rev 1 31 16 Freescale Semiconductor...
Страница 790: ...Debug Module MCF52277 Reference Manual Rev 1 32 50 Freescale Semiconductor...