Dual-head Monitor Setup on Ubuntu Linux with Xorg and radeon

Let me briefly summarize two methods to configure a dual-head setup with an external monitor connected to a laptop’s HDMI port on Ubuntu Linux 12.10 Natty. My setup includes a Lenovo Z565 laptop with an AMD/ATI Mobility Radeon HD 5470 graphics card and a Samsung S24A650D monitor. We assume that we rely Xorg’s open-source radeon driver throughout the tutorial.

Dynamic Configuration

We will use xrandr to configure a temporary dual-head setup during runtime. After connecting the monitor to the laptop, obtain the labels the system assigned to the monitors by a

xrandr -q

In my case, the output read

Screen 0: minimum 320 x 200, current 1920 x 1848, maximum 8192 x 8192
LVDS connected 1366x768+0+1080 (normal left inverted right x axis y axis) 0mm x 0mm
   1366x768       60.0*+
   1280x720       59.9  
   1152x768       59.8  
 (...) 
HDMI-0 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 531mm x 299mm
   1920x1080      60.0*+   50.0  
   1600x1200      60.0  
   1680x1050      59.9  
 (...)
VGA-0 disconnected (normal left inverted right x axis y axis)

The laptop’s internal monitor is called LVDS and the external monitor HDMI-0. By another call to xrandr, we activate the dual-head setup:

xrandr --output HDMI-0 --primary --left-of LVDS

The command line is to be understood literally: The HDMI monitor shall be the primary screen (e.g. displaying gnome’s titlebar) and shall be positioned left of the laptop’s internal monitor. For other placements, see xrandr’s –left-of, –right-of, –above and –below options or the very general –pos argument.

Permanent Configuration

For a permanent static configuration of a dual-head setup, we create a configuration file for the X server with an editor of your choice,

/etc/X11/xorg.conf

You will need root privileges for this. The contents of xorg.conf is as follows:

Section "Device"
        Identifier      "Mobility Radeon HD 5400 Series"
        Driver          "radeon"
        Option          "monitor-LVDS" "monitor_internal"
        Option          "monitor-HDMI-0" "monitor_external"
EndSection

Section "Monitor"
        Identifier      "monitor_internal"
        Option          "RightOf" "monitor_external"
EndSection

Section "Monitor"
        Identifier      "monitor_external"
        Option          "Primary" "true"
EndSection

In the device section, we specify to use Xorgs’s open source radeon driver and setup two aliases for the monitors. Please note that the monitor ID is composed of the static prefix monitor- and the monitor label as returned by xrandr -q (see above). The remaining configuration places the laptop’s internal monitor right of the external monitor. The latter is configured to be the primary screen.

Further Information

For more information, have a look at

  • Xorg’s documentation of the radeon driver
  • An article at Intel about configuring dual-head setups
  • and the man pages for the radeon driver (man radeon) and xrandr (man xrandr)
Advertisements

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 )

Google+ photo

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

Connecting to %s