Architecture
1033
SPRUH82C – April 2013 – Revised September 2016
Copyright © 2013–2016, Texas Instruments Incorporated
Liquid Crystal Display Controller (LCDC)
23.2.3 DMA Engine
The DMA engine provides the capability to output graphics data to constantly refresh LCDs, without
burdening the CPU, via interrupts or a firmware timer. It operates on one or two frame buffers, which are
set up during initialization. Using two frame buffers (ping-pong buffers) enables the simultaneous
operation of outputting the current video frame to the external display and updating the next video frame.
The ping-pong buffering approach is preferred in most applications.
When the Raster Controller is used, the DMA engine reads data from a frame buffer and writes it to the
input FIFO (as shown in
). The Raster Controller requests data from the FIFO for frame
refresh; as a result, the DMA’s job is to ensure that the FIFO is always kept full.
When the LIDD Controller is used, the DMA engine accesses the LIDD Controller's address and/or data
registers.
To program DMA engine, configure the following registers, as shown in
Table 23-2. Register Configuration for DMA Engine Programming
Register
Configuration
LCDDMA_CTRL
Configure DMA data format
LCDDMA_FB0_BASE
Configure frame buffer 0
LCDDMA_FB0_CEILING
LCDDMA_FB1_BASE
Configure frame buffer 1. (If only one frame buffer is used, these two
registers will not be used.)
LCDDMA_FB1_CEILING
In addition, the LIDD_CTRL register (for LIDD Controller) or the RASTER_CTRL register (for Raster
Controller) should also be configured appropriately, along with all the timing registers.
To enable DMA transfers, the LIDD_DMA_EN bit (in the LIDD_CTRL register) or the LCDEN bit (in the
RASTER_CTRL register) should be written with 1.
NOTE:
If the data left in the frame buffer is smaller than the DMA burst size, the DMA by default
transfers 1 word (4 bytes) at a time until the entire frame buffer is transferred. This
sometimes causes an input FIFO underflow, which can only be recovered through a Power
and Sleep Controller (PSC) reset. Thus, it is recommended that the size of the frame buffer
be divisible by the chosen burst size.
23.2.3.1 Interrupts
Interrupts in this LCD module are related to DMA engine operation. Three registers are closely related to
this subject:
•
The LIDD_CTRL and RASTER_CTRL registers enable or disable each individual interrupt sources.
•
The LCD_STAT register collects all the interrupt status information.
23.2.3.1.1 LIDD Mode
When operating in LIDD mode, the DMA engine generates one interrupt signal every time the specified
frame buffer has been transferred completely.
•
The DONE_INT_EN bit in the LIDD_CTRL register specifies if the interrupt signal is delivered to the
system interrupt controller, which in turn may or may not generate an interrupt to CPU.
•
The EOF1, EOF0, and DONE bits in the LCD_STAT register reflect the interrupt signal, regardless of
being delivered to the system interrupt controller or not.