English
Language : 

MB87P2020 Datasheet, PDF (70/356 Pages) Fujitsu Component Limited. – Colour LCD/CRT/TV Controller
MB87J2120, MB87P2020-A Hardware Manual
GDC_CMD_NOP();
}
Figure 1-19: DMA programming example with help of C-API
The first step is to initialize MCU-DMAC as well as GDC-DMAC with help of API function
’ULB_DMA_HDG’. This function does not start the transfer; it sets only DMA parameters for the following
transfer.
Afterwards the command for writing compressed bitmaps to display controller is sent to command register
together with the dimensions of the bitmap. See chapter 1.5 for more details about command execution.
With help of API function ’GDC_FIFO_INP’ DMA transfer is started. Note that the last function param-
eter is ’1’ which means that DMA transfer is enabled (see chapter 1.5.1 for a discussion about this function).
In order to synchronize DMA data flow with program flow a wait loop for end of DMA transfer is included
into the source code. This is not necessary in any case since the API functions ’ULB_DMA_HDG’ and
’GDC_FIFO_INP’ wait for the end of previous DMA transfer before they perform any action.
In the example in figure 1-19 the DMA synchronization is necessary in order to make sure that all data are
transferred when a NoOp command is sent to display controller to force a input FIFO flush. Without this
synchronization not sent data would be kept for the next command after NoOp.
Page 70