1 .\" $NetBSD: edid.9,v 1.1 2006/05/11 21:00:20 gdamore Exp $
3 .\" Copyright 2006 Itronix Inc.
4 .\" All rights reserved.
6 .\" Written by Garrett D'Amore for Itronix Inc.
8 .\" Redistribution and use in source and binary forms, with or without
9 .\" modification, are permitted provided that the following conditions
11 .\" 1. Redistributions of source code must retain the above copyright
12 .\" notice, this list of conditions and the following disclaimer.
13 .\" 2. Redistributions in binary form must reproduce the above copyright
14 .\" notice, this list of conditions and the following disclaimer in the
15 .\" documentation and/or other materials provided with the distribution.
16 .\" 3. The name of Intronix Inc. may not be used to endorse
17 .\" or promote products derived from this software without specific prior
18 .\" written permission.
20 .\" THIS SOFTWARE IS PROVIDED BY INTRONIX INC. ``AS IS'' AND
21 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
22 .\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23 .\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL ITRONIX INC. BE LIABLE FOR ANY
24 .\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26 .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28 .\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
30 .\" POSSIBILITY OF SUCH DAMAGE.
37 .Nd VESA Extended Display Identification Data
39 .In dev/videomode/edidvar.h
40 .In dev/videomode/edidreg.h
48 .Fa "struct edid_info *info"
52 .Fa "struct edid_info *info"
56 functions provide support parsing the Extended Display Identification Data
57 which describes a display device such as a monitor or flat panel display.
61 function simply tests if the EDID block in
63 contains valid data. This test includes a verification of the checksum,
64 and that valid vendor and product idenfication data is present. The data
65 block contain at least 128 bytes.
69 function parses the supplied
71 block (which again, must be at least 128 bytes), writing the relevant
72 data into the structure pointed to by
77 function prints the data in the given
79 structure to the console device.
82 .\" XXX It sure would be nice to have documentation about the details of the
83 .\" XXX edid_info structure itself. This takes more time, though, and
84 .\" XXX hopefully someone else will write it up. In the meantime, the code
85 .\" XXX references should be useful.
90 function returns 0 if the data block is valid, and
95 function returns zero if the data was successfully parsed, and
98 This section describes places within the
100 source tree where actual code implementing or using the
101 EDID subsystem can be found.
102 All pathnames are relative to
105 The EDID subsystem is implemented within the file
106 .Pa sys/dev/videomode/edid.c .
108 The EDID subsystem also makes use of VESA Generalized Timing Formula located
110 .Pa sys/dev/videomode/vesagtf.c
111 and the generic videomode database located in
112 .Pa sys/dev/videomode/videomode.c .
114 The following code uses these functions
115 to retrieve and print information about a monitor:
117 .Bd -literal -compact
118 struct edid_info info;
123 /* initialize i2c tag... */
125 if ((ddc_read_edid(tag, buffer, 128) == 0) &&
126 (edid_parse(buffer, &info) == 0))
135 These routines were added in
138 .An Garrett D'Amore Aq gdamore@NetBSD.org