Dual monitor setup in Ubuntu 10.04 using EDID and CustomEDID

I just got a new monitor and was having trouble getting my nvidia card to detect my old monitors native resolution(s) over the VGA port.

Here is my setup:

  • GeForce 6600 GT (using nvidia binary drivers)
  • Dell E228 WFP (22″ LCD) over VGA
  • Hans G HH281 (28″ LCD) over DVI (DVI from card to HDMI input on monitor)
  • Ubuntu 10.04 X11 server
And the solution:
xorg.conf’s CustomEDID option. EDID is essentially a set of bits that describes your monitors settings to your video card and hence your OS/display and/or windowing manager.  If you are familiar with X11 and xorg.conf you know how big of a pain in the ass it can be when it does not detect your monitor settings correctly – you have to mess around with modeline and a bunch of other stuff that should be autodetected.

The EDID comes right from your monitor, and in a single tiny binary file, it contains all the info your vid card needs – resolution, frefresh rates etc.

So how do you get your monitor’s EDID? If you have an nvidia card and at least 1 DVI input its stupid easy.  First install nvidia settings 

sudo apt-get install nvidia-settings

Now plug the monitor you want to extract the EDID of, into your DVI port.  You may ultimately plug this monitor into the VGA slot, but you need to initially plug it into the DVI port to extract the EDID.  Restart your computer (or just log out and back in to restart X). Then startup nvidia-settings (under the administration menu).  Your resolution at this point may be all jacked up, but be patient.

From the NVIDIA X Server Settings, select your monitor from the “GPU X” category.  Mine was DFP-0 by default. Now click the ‘extract EDID’ button.  Save this to a common place, like /etc/X11/edids or something.  Make sure everyone can read (sudo chmod a+r nameofyouredid.bin)

Now you’ll need to setup your xorg.conf.  NOTE: make a backup of this file before continuing (cp /etc/X11/xorg.conf /etc/X11/xorg.conf.bak).  I’ll inline my xorg.conf for reference, but basically just add ‘option “CustomEDID” “CRT-0:<full edid.bin=”” file=”” path=”” to=”” your=””>” to the Device section.</full>

Here is my xorg.conf:

Section “ServerLayout”
    Identifier     “Layout0”
    Screen      0  “Screen0” 0 0
    InputDevice    “Keyboard0” “CoreKeyboard”
    InputDevice    “Mouse0” “CorePointer”
    Option         “Xinerama” “0”

Section “Files”

Section “InputDevice”
    Identifier     “Mouse0”
    Driver         “mouse”
    Option         “Protocol” “auto”
    Option         “Device” “/dev/psaux”
    Option         “Emulate3Buttons” “no”
    Option         “ZAxisMapping” “4 5”

Section “InputDevice”
    Identifier     “Keyboard0”
    Driver         “kbd”

Section “Monitor”
    Identifier     “Monitor0”
    VendorName     “Unknown”
    ModelName      “DELL E228WFP”
    HorizSync       30.0 – 83.0
    VertRefresh     56.0 – 75.0
    Option         “DPMS”

Section “Device”
    Identifier     “Device0”
    Driver         “nvidia”
    VendorName     “NVIDIA Corporation”
    BoardName      “GeForce 6600 GT”
    Option         “CustomEDID” “CRT-0:/hdd2/monitorEDID/E228WFPedid.bin”

Section “Screen”
    Identifier     “Screen0”
    Device         “Device0”
    Monitor        “Monitor0”
    DefaultDepth    24
    Option         “TwinView” “1”
    Option         “TwinViewXineramaInfoOrder” “DFP-0”
    Option         “metamodes” “CRT: 1680x1050_60 +0+0, DFP: nvidia-auto-select +1680+0”
    SubSection     “Display”
        Depth       24

‘nvidia-auto-select’ should work for the monitor that is plugged into your DVI. 1680x1050_60 is the native res of my monitor – not sure its needed here cuz of the CustomEDID, but was just to be safe.  Also, not sure if HorizSync or VertRefresh is needed, but I knew em so I left it in.

Now log out and back in, and you should be able to launch up nvidia-settings and tweak your monitor layout how you wish (determine which monitor is primary etc).

If stuff gets messed up, and you want to do trial and error, simply copy back your xorg.conf.back, logout/restart tweak, and retry.

Hope this helps.

Here are some handy edid tools if you dont roll NVIDIA: http://manpages.ubuntu.com/manpages/lucid/man1/get-edid.1.html


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this:
search previous next tag category expand menu location phone mail time cart zoom edit close