8-18
DS785UM1
Copyright 2007 Cirrus Logic
Graphics Accelerator
EP93xx User’s Guide
8
8
8
7. Setup BLOCKCTRL Register
For (example) 16-bit pixels and Mask AND Mode:
A. Clear the
register by writing 0x0000_0000 to it
B. Write Fill = ‘1’, BG = ‘0’, M = 0x1, P = 0x4, and INTEN = ‘1’ to the
register
C. Write EN = ‘1’ to the
register
8. Wait for an Interrupt or Poll for EN = ‘0’ in the BLOCKCTRL Register.
When the EN bit becomes cleared to ‘0’, the Block Fill Algorithm function is complete.
8.6.4 Block Copy Function
The following sequence describes how to set up the registers used for a Block Copy function:
1. Setup Source Memory
A. Write the desired values to the SPEL field and the EPEL field in the
register.
SPEL is the starting pixel position within the word that the pixel-copy will begin with.
EPEL is the ending pixel position within the word that the pixel-copy will end with. See
For example, if the image to be copied is at position (51, 75) and the pixel depth is 16-
bits, the value for SPEL is (51 x 16)% 32 = 16 = 0x10 and the value for EPEL is (75 x
16)% 32 = 16 = 0x10
B. Write the word-aligned value of the SDRAM address ‘for the beginning of the image
that is to be copied’ to the
register.
C. Write the line length value to the LEN field in the
register,
where LEN is determined by:
(1).Find how many pixels occupy a 32-bit word. For example, four 8-bit pixels can
occupy a 32-bit word.
(2).Find the width of the display in pixels. For example, a 640x480 display has a
width of 640 pixels.
(3).The line length, LEN, is determined by the stride of the display, that is, how
many 32-bit words are needed to populate the width of the display with pixels.
From steps 1 and 2, the stride for this example is 640 pixels divided by 4,
where 4 is the number of 8-bit pixels that occupy a word. So, for this example,
line length is 640 divided by 4 = 160 = 0xA0.
Usually the same LEN value is used in both the
register
and the
register.
D. Write the value of the WIDTH field to the
register, where WIDTH
is the number of 32-bit words, minus 1, that are needed to contain the pixels that
Summary of Contents for EP93 Series
Page 28: ...P 6 DS785UM1 Copyright 2007 Cirrus Logic Preface EP93xx User s Guide PP P ...
Page 162: ...5 36 DS785UM1 Copyright 2007 Cirrus Logic System Controller EP93xx User s Guide 55 5 ...
Page 576: ...15 18 DS785UM1 Copyright 2007 Cirrus Logic UART2 EP93xx User s Guide 1515 15 ...
Page 634: ...17 38 DS785UM1 Copyright 2007 Cirrus Logic IrDA EP93xx User s Guide 1717 17 ...
Page 648: ...19 6 DS785UM1 Copyright 2007 Cirrus Logic Watchdog Timer EP93xx User s Guide 1919 19 ...
Page 688: ...21 32 DS785UM1 Copyright 2007 Cirrus Logic I2S Controller EP93xx User s Guide 2121 21 ...
Page 790: ...27 20 DS785UM1 Copyright 2007 Cirrus Logic IDE Interface EP93xx User s Guide 2727 27 ...
Page 808: ...28 18 DS785UM1 Copyright 2007 Cirrus Logic GPIO Interface EP93xx User s Guide 2828 28 ...