Thursday, June 07, 2012


This post is about Extended Display Identification Data.
It's the information your monitor or TV sends to your PC or media player to let it know what video/audio formats are supported. Most of the time it's correct and everything works like you want it to. There are several reasons to modify or override the EDID data coming from your TV/monitor via the DDC2B protocol (I2C address 0x50 and 0x30).
  • Get higher refreshrates than 60Hz.
  • Solve ghosting or other quirks in 3D interlaced/checkerboard mode.
  • Tell attached equipment to pass DTS audio. Your TV often does not know that your audio receiver can handle DTS.
First, some fiddling with OSX to retrieve EDID data from attached display:

ioreg -l | grep -5 IODisplayEDID

Returns some long number...

Save that to EDID.txt or something and look at the details with edid-decode.
cat EDID.txt | xxd -r -p | ./edid-decode

Now we want to tinker with it! There are some options to do that.

Phoenix EDID Designer (Windows, yuck)This program accepts only files in a special format, so we need to convert it somehow.

cat EDID.txt | xxd -r -p | (echo 'EDID BYTES:';\
echo '0x   00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F';\
echo '    ------------------------------------------------';\
xxd -g 1 -c 16 | sed -E 's/00000(..): (.{47}).*/\1 | \2/g'\
) | tr abcdef ABCEDF | sed 's/$'"/`printf '\r'`/g" > conv.dat

Compare the exported raw data with original:
cat EDID.txt | xxd -r -p | ./edid-decode > left.txt
cat exported.raw | ./edid-decode > right.txt
diff left.txt right.txt

The new data will show:
EDID block does NOT conform to EDID 1.3!
Missing monitor ranges
That's too bad!

010 Editor

I made a template file for 010 Editor, which is a nifty binary editor.
Download the template here.
Somehow they did not put the CRC fixing script (.1sc extension) there, but it's quite short:

file.checksum = -Checksum(CHECKSUM_SUM8, startof(file), startof(file.checksum) - startof(file));
local int i;
for (i=0; exists(file.extensions[i]); i++) file.extensions[i].checksum = -Checksum(CHECKSUM_SUM8, startof(file.extensions[i]), 127);

That's pretty neat uh?

Create EDID override file for OS X (method 1)

Assuming you have saved the modified exported.raw, generate a hex dump like so:

xxd -ps exported.raw

Create a plist file (without extension) and open with XCode or Property List Editor.
The VID/PID in the directory/filename are in unpadded lowercase hexadecimal format.

DisplayProductName String "My modified display name"
DisplayProductID Number 1 (displayed in decimal)
DisplayVendorID Number 7789 (displayed in decimal)
IODisplayEDID Data <00ffffff...> (paste the data between brackets)

Create EDID override file for OS X (method 2)

Paste the result of
(echo -n '<data>'; (cat exported.raw | base64 | tr -d '\n'); echo '</data>')
into the override file (see method 1) where you can use the following as a base:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">
    <string>My modified display name</string>


Somehow, the resolution went back to 960x540 (HiDPI) whenever I change the EDID and replug my video connector.
Also, I have to find out how to reprogram my LG TV with new EDID data. There is some option in the service menu, but haven't looked how to do it yet.
It's nice that I can override EDID data in OS X, but I cannot override it on my PS3 for example. Thus, I need the optical audio output if I want DTS.

Video timing calculator
EDID 1.3 data format