• Programmable width and height of the OSD window,
built from maximum 1152 characters
• 8 different colours for foreground and background
inclusive transparent colours
• Overlay port for external OSD controller.
1.5Video output
• Single pixel/clock (24-bit) or double pixel/clock (48-bit)
digital RGB output
• Generation of synchronization and validation signals for
the Thin Film Transistor (TFT) display
• Frame rate control (temporal dithering) for displaying
true colour graphics on high colour displays
• Free programmable timing for displays of several
manufacturers.
1.6Memory interface
• Support of both 1M × 16 SDRAM,256k × 32 SGRAM or
128k × 32 SGRAM devices
• Maximum memory clock frequency of 125 MHz
• Scalable memory size built of either 2, 3 or 4 SDRAM,
or of 1 or 2 SGRAM devices
• Special mode for operation without external memory.
1.7Miscellaneous
• Internal Phase-Locked Loop (PLL) for memory and
panel clock generation from the system clock
2
C-bus interface with 2 selectable addresses
• I
• Boundary scan test circuit and Joint Test Action Group
(JTAG) test controller.
1999 May 113
Philips SemiconductorsPreliminary specification
SXGA RGB to TFT graphics engineSAA6721E
2GENERAL DESCRIPTION
The SAA6721E is a graphics engine, which converts
digital RGB or YUV data into video signals suitable for TFT
displays. It supports SXGA input resolution as well as true
colour. Independent horizontal and vertical up and
downscaling can display the input data arbitrarily on the
connected TFT display. Multi-sync capability allows the
applied graphics mode to be detected.
Overlay signals can be generated either by an internal
The SAA6721E must be embedded into a system
containing a microcontroller with an I
2
C-bus serial
interface. For multi-sync capabilities a frame buffer built
from SGRAM or SDRAM is needed. The size of this frame
buffer depends on the maximum resolution and bandwidth
needed for the application. For converting the analog RGB
stream into a digital data stream one or two ADCs with
3 channels each for R, G and B are needed. If the YUV
input is used, a video front-end chip such as the SAA7113
must be used in front of the YUV port.
OSD generator or supplied via the overlay port from an
external OSD controller.
3QUICK REFERENCE DATA
SYMBOLPARAMETERMIN.TYP.MAX.UNIT
V
I
DDD
V
V
DDD
i
o
digital supply voltage3.03.33.6V
digital supply current−600840mA
input voltagesLVTTL compatible
output voltages memory portLVTTL compatible
output voltages TFT portCMOS compatible
1. Generally all inputs are 5 V tolerant TTL inputs. All outputs are CMOS, except the memory interface ports, which are
LVTTL compatible.
2. Connect to ground when not using the JTAG controller.
7FUNCTIONAL DESCRIPTION
7.1Data path
Input video data is sampled either as RGB data in single
pixels from only one ADC or in double pixels in interleaved
format from two ADCs. Alternatively the input interface can
sample interlaced or non-interlaced YUV data. The clock
for sampling the data will always be provided from external
circuitry. The video stream will be adapted from the input
frame rate to the output frame rate needed by the panel.
Therefore a frame buffer built of SDRAMs or SGRAMs is
used. If the panel supports the incoming frame rate from
the RGB port, the adaption can be done without external
memory. If the video stream is in interlaced format the
memory interface activates its de-interlacing unit.
If zooming must be performed the upscaler behind the
memory interface will be enabled. For downscaling the
downscaler in front of the memory interface in the data
path will be used. A colour correction can be done via a
look-up table. The resulting video stream can now be
positioned elsewhere in the output data stream by the
panning unit. If an external OSD controller is embedded
into the system, its OSD window will be put into the video
stream by the OSD overlay port. Additionally the internal
OSD will be inserted in the next stage. The temporal
dithering allows true colour pictures to be displayed on
high colour panels. The output interface provides the
timing and control signals necessary for the connected
panel.
7.2System clocks
7.2.1I
NPUT INTERFACE CLOCK (VCLK)
This clock is used for sampling the incoming RGB or YUV
data stream. In RGB mode this clock varies from
25 to 150 MHz in single ADC mode. If two ADCs are used
the RGB input clock is between 12.5 and 75 MHz. In YUV
mode the clock lies in the range of approximately 30 MHz.
The clocks are generated from external devices.
The RGB clock can be generated by the external ADCs or
an external video PLL. The YUV clock must be generated
by the video decoder which also provides the YUV video
data.
7.2.2M
EMORY INTERFACE CLOCK (MCLKI)
The memory clock is the synchronous clock for the
external frame buffer. Depending on the bandwidth
needed by the application, and the connected SDRAM or
SGRAM devices, the clock varies from 83 to 125 MHz.
It can be generated internally by the PLL from the system
clock (CLK), or by an external quartz oscillator.
If the internal PLL is used, the memory clock frequency
can be derived from the following formula:
f_memory
f_system
----------------------- N
16×=
Where N = pre-divider ratio and f_system = clock at
pin CLK.
1999 May 1113
Philips SemiconductorsPreliminary specification
SXGA RGB to TFT graphics engineSAA6721E
7.2.3I2C-BUS INTERFACE CLOCK (SCL)
This clock drives the interface to the external
microcontroller. Its frequency range is from
100 kHz to 1 MHz.
7.2.4S
YSTEM CLOCK (CLK)
This clock is used to drive the internal PLL. The frequency
range is from 24 to 50 MHz.
7.2.5TFT
PANEL CLOCK (PCLK)
This clock is the timing reference for the panel.
The frequency is the same as the system clock, or it can
be generated from the internal PLL by using the following
formula:
f_tft
f_system
----------------------- N
32
×=
-----M
Where N = pre-divider ratio and M = post-divider ratio.
7.3RGB input port
The RGB input port can operate in two modes; single pixel
mode (24 bits) and double pixel mode (48 bits). For single
pixel mode only ports VPA7 to VPA0, VPB7 to VPB0, and
VPC7 to VPC0 are internally sampled. For double pixel
mode two pixels must be provided at the RGB input port.
Therefore ports VPD7 to VPD0, VPE7 to VPE0, and
VPF7 to VPF0 are also needed.
The VPA/B/C ports are sampled on the rising edge of the
RGB input clock (VCLK), and the VPD/E/F ports on the
falling edge (see Fig.3).
The synchronization pulses from the graphics card are
used to identify the frame outline. The vertical
synchronization pulse is connected to pin VVS, and the
horizontal synchronization pulse is connected to pin VHS.
For calibrating the connected Analog-to-Digital Converter
(ADC) the SAA6721E delivers a clamp pulse at
pin CLAMP, and a gain correction pulse at pin GAINC
(see Fig.4).
The sample window of the RGB input port is controlled by
four counters; horizontal and vertical offset, and horizontal
and vertical window size.
The offset counters start at the inactive or second edge of
their corresponding synchronization signal.
handbook, full pagewidth
VCLK
VPA/B/C
VPD/E/F
Fig.3 RGB input port timing.
1999 May 1114
MHB243
Philips SemiconductorsPreliminary specification
SXGA RGB to TFT graphics engineSAA6721E
handbook, full pagewidth
VHS
RGB data
GAINC
CLAMP
Fig.4 Clamp and gain correction pulses.
7.4YUV input port
The YUV input port supports interlaced video streams and
provides an easy connection to most common decoder
ICs. It consists of the luminance port VPA7 to VPA0, the
chrominance port VPB7 to VPB0, and eventually
VPC7 to VPC0, which are CCIR 601 level compatible
(Y: 16 to 235, and UV: 16 to 240).
Supported at this port are the formats YUV 4 : 1 : 1,
YUV4:2:2 and YUV 4:2:2 with CCIR 656 codes
(see Table 2).
blanking
MHB244
YUV 4:4:4 data can be applied at VPA7 to VPA0 (Y),
VPB7 to VPB0 (U), and VPC7 to VPC0 (V). Input data is
sampled with respect to the clock at pin VCLK if pin VPD7
(CREF) is asserted.
The start of active video data in a line is marked by the
rising edge at pin VPD6 (HREF) and the end of valid video
data is marked by the falling edge at pin VPD6. Figure 5
illustrates this at a YUV 4 :2:2 example.
For YUV 4 :4:4 the Y, U, and V components are available
in parallel.
If non-interlaced video data is applied, it is treated as odd
fields. Interlaced video data is sampled odd field,
even field, odd field, even field, etc. If there are equal
subsequent frames, only the first of these frames will be
handbook, full pagewidth
VCLK
Y7 to Y0
FF...Y1V0Y0U0SAV0000XX
Fig.6 CCIR 656 SAV code.
handbook, full pagewidth
VCLK
Y7 to Y0
U718XXEAV0000FFY719V718Y718...
sampled. The decoding of odd and even fields is done with
HREF. In CCIR 656 data streams the included codes are
used for identifying even and odd frames, blanking and
active video data. The codes start with the byte sequence
FF 00 00, followed by the reference code byte;
see Figs 6 and 7.
MHB246
MHB247
Fig.7 CCIR 656 EAV code.
1999 May 1116
Philips SemiconductorsPreliminary specification
SXGA RGB to TFT graphics engineSAA6721E
The CCIR 656 code byte contains vertical and horizontal
blanking as well as odd and even field information, the
protection bits P3 to P0 are ignored.
Table 3 CCIR 656 code byte
MSBLSB
76543210
1F
(2)
V
(3)
H
P3P2P1P0
(1)
Notes
1. F = 0: odd field (field 1); F = 1: even field (field 2).
2. V = 0: in active field lines; V = 1: in field blanking.
3. H = 0: SAV (Start of Active Video);
H = 1: EAV (End of Active Video).
The sample window of the YUV input port is controlled by
four counters; horizontal and vertical offset, and horizontal
and vertical window size. The vertical offset counter starts
counting from the inactive or second edge of its
corresponding reference signal. The horizontal offset
counter starts with the active edge of the HREF signal.
7.5.2DOUBLE PIXEL MODE
The double pixel mode is used for direct connection of TFT
panels with double pixel input. Both output ports are used.
The first pixel is applied at port A, and the second at port B.
7.6Memory port
The memory port connects the SAA6721E to the external
frame buffer. This frame memory can be built from either
1M × 16 SDRAM or 256k × 32 SGRAM devices.
Supported are RAM devices with clock frequencies up to
125 MHz. This clock can be provided either by the internal
PLL, or externally be applied to pin MCLKI.
The memory data bus is split into 4 ports:
port 0 (DQ0 to DQ15), port 1 (DQ16 to DQ31),
port 2 (DQ32 to DQ47) and port 3 (DQ48 to DQ63).
To adapt the external memory to the needs of the
application by means of memory size and bandwidth, it is
possible to scale the external memory by using only the
number of subsequent ports needed to build up the frame
buffer and to achieve the memory bandwidth. As a second
step for bandwidth optimization several speed grades of
memory devices can be used.
7.5TFT output port
The TFT output port consists of two pixel ports (A and B),
each containing red, green and blue colour information
with a resolution of 8 bits per colour. The first pixel port is
mapped to PAR7 to PAR0, PAG7 to PAG0, and
PAB7 to PAB0. The second port is mapped to
PBR7 to PBR0, PBG7 to PBG0, and PBB7 to PBB0.
The vertical and horizontal synchronization signals are
mapped to pins PVS and PHS. A data validation signal
framing visible pixels is available at pin PDE.
All of the above mentioned signals are synchronized to the
output clock at pin PCLK. The active edge of this clock is
programmable.
7.5.1SINGLE PIXEL MODE
The single pixel mode is designed to support TFT panels
with single pixel input, and for direct connection of panel
link transmitters. Only the first pixel port PAR7 to PAR0,
PAG7 to PAG0, and PAB7 to PAB0 is used. The data is
applied at double the frequency in comparison to the
double pixel output mode.
7.6.1SDRAM
MEMORY CONFIGURATION
SDRAMs are available in sizes from 16 Mbits. For this
application a wide data bus is required, so that at least
1M × 16 devices must be used. To achieve the desired
bandwidth, 2 to 4 devices must be used in parallel, which
results in a frame buffer size of 4 to 8 Mbytes. But only half
of this memory will be used by the SAA6721E.
The memory port of the SAA6721E can be divided into
4 SDRAM channels. Each channel is 16 bits wide, and
provides in High Speed Channel (HSC) mode with a
125 MHz memory clock and an effective bandwidth of
228 Mbits/s. A Medium Speed Channel (MSC) with a
100 MHz memory clock gives an effective bandwidth of
182 Mbits/s, 91% effective bandwidth assumed.
Table 4 gives the channel configuration for several input
and panel resolutions.
SGRAM devices organized to 256k × 32 bits are available,
and feature the wide data bus for high speed applications.
With these devices a frame buffer can be built, without
wasting memory because of bandwidth. In case of
SGRAM usage, the memory data bus of the SAA6721E
Each channel gives, in HSC mode with 125 MHz clock
frequency, an effective bandwidth of 456 Mbits/s; and in
MSC mode, with 100 MHz clock speed, an effective
bandwidth of 364 Mbits/s.
Table 5 gives the channel configuration for several input
and panel resolutions.
This serial interface consists of only two signals, the serial
clock line (SCL) and the serial data line (SDA).
The maximum supported frequency on this bus is 1 MHz.
Spikes with a maximum pulse length of 50 ns are
suppressed by the internal input filter.
The SAA6721E operates as a slave and cannot initiate
any data transfer, so the clock line is always input. Via the
data line, data is transmitted and received, so this pin must
be input/output. The SCL and SDA lines are driven by
open-drain stages and pull-up resistors. When a logic 0 is
applied, the bus is set to ground level via the output
buffers. When a logic 1 is applied, the output buffer
switches to 3-state and the pull-up resistors pull the bus up
to +5 V.
Data transfer changes on SDA are allowed only when SCL
is LOW. Data is sampled on the positive edge of SCL.
In Idle state the output buffers are in 3-state, and the bus
is HIGH. A data transfer must be initiated by an I2C-bus
master device. This is done by sending a START condition
when SDA changes from HIGH to LOW when SCL is HIGH
(see Fig.8).
The device address of the SAA6721E must then be sent
with the desired I/O direction.
If the SAA6721E reads its device address, it
acknowledges this by sending a single bit ACK to the
master. If write mode was selected, the master sends the
register address to be written and then the data bytes.
If read mode was selected, the SAA6721E sends the data
bytes starting from the last address accessed either by
write command or the next address at a read command.
All byte transfers are acknowledged from the receiving
device. The data transfer is aborted by sending a STOP
condition, when SDA changes from LOW to HIGH when
SCL is HIGH (see Fig.9).
If a new address has to be read or written, it is possible to
send a new START condition without a preceding STOP
condition. In this case the bus is still occupied by the
master, and it can initiate a new data transfer. This is
useful for read activities, where at first the register address
must be sent in write mode and after that a read command
will be sent to read data from this and following addresses.
handbook, full pagewidth
SCL
SDA
handbook, full pagewidth
SCL
SDAD7D4D5D6D1D0ACKD2D3A/A
START condition
A4A1A2A3A6A5ACKR/W
A0R5R7R6
Fig.8 Start of a data transfer.
Fig.9 End of a data transfer.
acknowledge
D1D0
acknowledge/
not acknowledge
MHB248
STOP condition
MHB249
1999 May 1119
Philips SemiconductorsPreliminary specification
SXGA RGB to TFT graphics engineSAA6721E
If the data transfer was a read transfer and the master was
receiver, the master must not generate an acknowledge
before the STOP condition.
7.8De-interlacing algorithms
The SAA6721E features several de-interlacing algorithms
for processing interlaced video data. Depending on the
algorithm different memory bandwidths and field
memories are needed.
7.8.1STATIC MESH MODE
This mode allows de-interlacing without any image
processing and filtering. A field store for 2 fields is
necessary. De-interlacing is achieved by simply putting
lines together in the right order from the odd and even
fields in the field store and generating the output frame.
7.8.2S
PATIAL FILTERING
The spatial filtering mode requires 2 field memories, but
only one memory is used at a time. For the calculation of
the whole frame from an odd field, the missing even lines
are interpolated from the odd lines before and after.
Processing of the even field is done in the same way.
7.8.3T
EMPORAL FILTERING
The filtering algorithm needs 4 field memories and will be
applied temporally to subsequent fields.
The missing even line in an odd frame will be calculated by
interpolation from the corresponding even lines in the even
fields before and after. The odd line handling is done in the
same way.
7.9Scaling algorithm
The SAA6721E features different scaling engines for up
and downscaling, for both horizontal and vertical
processing. The horizontal scaling engines are
independent from each other. The vertical scaling engines
share the line buffer, so they cannot operate in parallel.
7.9.1U
PSCALING
The upscaling engine is used for enlarging the incoming
video frames. It can be used for zooming both RGB and
YUV video data. The magnification can be programmed
individually for horizontal and vertical scaling.
The maximum scaling factor for both directions is 64.
The implemented filter algorithm (see Fig.10) uses
interpolation with pixel enhancement, based on a free
programmable transition function. It is therefore possible
to define the transition between two calculated pixels to
obtain different sharpness characteristics. This transition
function must be defined in the 7 bits × 64 look-up table,
with a number ranging from 0 to 64. Different functions can
be programmed for horizontal and vertical scaling.
handbook, full pagewidth
AB
O
(1) The linear interpolation results in smoothing the sharp edges of the original picture if a pixel must be calculated.
(2) Some kind of1⁄xfunction results in sharper edges, because of the smaller transition interval.
(3) Phase correct pixel repetition can be done with this function.
intensity of
output pixel O
100% A,
0% B
0% A,
100% B
100% A,
0% B
(3)
(2)
0% A,
100% B
Fig.10 Interpolation function definition.
1999 May 1120
(1)
MHB250
ratio between
input pixels A, B
Philips SemiconductorsPreliminary specification
SXGA RGB to TFT graphics engineSAA6721E
7.9.2DOWNSCALING
The downscaling engine is used for reducing the incoming
RGB data stream, i.e. for displaying high resolution input
frames on panels with a smaller resolution. The scaling
ratio can be programmed independently for both horizontal
and vertical downscaling units. The algorithm uses pixel
accumulation, achieving a minimum scaling factor of1⁄64.
8SYSTEM DESCRIPTION
8.1Programming registers
The SAA6721E is a highly integrated device with many
features. To get the desired functionality and performance
it must be programmed correctly. In general, before
programming, the device must be switched to the internal
reset state to prevent unwanted functions while changing
the registers.
Table 7 Programming register overview
ADDRESS R/WD7D6D5D4D3D2D1D0
State
0Rreserved
1Rreserved
2R/W iic_test_register[7 to 0]
3Rintr
After writing to all registers the internal reset can be
released. There are some registers (mainly offset
counters) that can be changed during data processing
without an internal reset. All accesses to the on screen
display can be done during data processing.
2
Table 6 I
MSBLSB
011101SADR/
Bit SAD = 0 the address is 74H, while bit SAD = 1 the
address is 76H.
Table 7 shows the programming model.
C-bus device address
W
RGB mode detection
4Rpos_
vsync
5Rv_lines[7 to 0]
6Rv_lines[10 to 8]
7Rh_clocks[7 to 0]
8Rh_clocks[11 to 8]
RGB auto-adjustment
9Wref_line[7 to 0]
10Wref_line[10 to 8]
11Wref_pixel[7 to 0]
12Wref_pixel[11 to 8]
13Wref_colour[7 to 0]
14Rref_pixel_red[7 to 0]
15Rref_pixel_green[7 to 0]
16Rref_pixel_blue[7 to 0]
17Rblack_lines[7 to 0]
18Rblack_pixels[7 to 0]
pos_
hsync
no_
vsync
no_
hsync
1999 May 1121
Philips SemiconductorsPreliminary specification
SXGA RGB to TFT graphics engineSAA6721E
ADDRESS R/WD7D6D5D4D3D2D1D0
19Rblack_
pixels[8]
20Rnon_black_lines[7 to 0]
21Rnon_black_lines[10 to 8]
22Rnon_black_pixels[7 to 0]
23Rnon_black_pixels[11 to 8]
General configuration
24Wintr_clearsingle_
adc_mode
25Wyuv_clk_
Clock distribution
26Wpor_mclkpre_div_
enable
27Wpre_div_clock_p_high[3 to 0]pre_div_clock_p_low[3 to 0]
28Wpre_div_clock_n_high[3 to 0]pre_div_clock_n_low[3 to 0]
29Wpre_div_clock_n_offs[3 to 0]
30Wpost_div_clock_p_high[3 to 0]post_div_clock_p_low[3 to 0]
31Wpost_div_clock_n_high[3 to 0]post_div_clock_n_low[3 to 0]
32Wpost_div_clock_n_offs[3 to 0]
post_div_
enable
no_
memory_
mode
mux
pre_div_
half_clock
memory_
init
csm_
bypass
post_div_
half_clock
reset_
input_path
frc_onblank_
pll_enable pll_pclkpll_mclk
reset_
memory_
path
screen
reset_
proc_path
power_
down
Input interface
33Wrgb_interl_onin_form_onrgb_proc_onadc_
sample_
seq
34Wfield_
reverse
35Wv_offset[7 to 0]
36Wv_offset[10 to 8]
37Wh_offset[7 to 0]
38Wh_offset[11 to 8]
39Wv_length[7 to 0]
40Wv_length[10 to 8]
41Wh_length[7 to 0]
42Wh_length[11 to 8]
43Wclamp_on[7 to 0]
44Wclamp_off[7 to 0]
45Wgainc_on_delay[7 to 0]
46Wgainc_off_delay[7 to 0]
yuv_field_mode
[1 and 0]
gainc_polclamp_pol vs_polhs_pol
yuv_input_mode
[1 and 0]
yuv_href_
pol
yuv_cref_
pol
1999 May 1122
Loading...
+ 50 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.