Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

dual monitors



I've been using nvidia Control (NV Control) and nvidia-settings without
problems on my ThinkPad + Ubuntu; sometimes to extend the display to drive
the laptop screen plus an LCD (my home office dock); and at work (again
using the thinkpad dock which is capable of driving two external displays)
to turn off the laptop screen and extend the display to two external LCDs

In addition to using the nvidia control GUI, I've found it useful to play
with disper or xrandr (much faster and I know what's going on better).

# this simple command should just switch off the LCD screen
# and enable the external VGA monitor at it optimal resolution
xrandr --output VGA-0 --auto --output LVDS --off


xrandr --verbose --output LVDS --off --output VGA-0 --mode 1680x1050


# Ask disper to tell us what it knows about our displays
disper -l
display DFP-0: LEN
 resolutions: 320x175, 320x200, 360x200, 320x240, 400x300, 416x312, 512x384,
640x350, 576x432, 640x400, 680x384, 720x400, 640x480, 720x450, 640x512,
700x525, 800x512, 840x525, 800x600, 960x540, 832x624, 960x600, 1024x768,
1152x864, 1360x768, 1440x900
display CRT-0: LEN L2240pwD
 resolutions: 320x240, 400x300, 512x384, 680x384, 640x480, 720x450, 700x525,
840x525, 800x600, 960x540, 832x624, 960x600, 1024x768, 1152x864, 1360x768,
1280x960, 1440x900, 1280x1024, 1400x1050, 1600x1000, 1600x1200, 1920x1080,
1920x1200, 1680x1050
display DFP-1: LEN L2240pwD
 resolutions: 320x175, 320x200, 360x200, 320x240, 400x300, 416x312, 512x384,
640x350, 576x432, 640x400, 680x384, 720x400, 640x480, 720x450, 640x512,
700x525, 800x512, 840x525, 800x600, 960x540, 832x624, 960x600, 896x672,
928x696, 960x720, 1024x768, 1152x864, 1360x768, 1280x960, 1440x900,
1280x1024, 1400x1050, 1600x1000, 1600x1024, 1680x1050

# a command to move the display off the laptop
# onto the two extended displays
disper --extend --displays CRT-0,DFP-1

# the above works when you have two external displays attached to the dock.
# if you just have one display attached to the dock and that display is on
the left
disper --displays=auto -e --direction=left



#!/bin/sh
#
# Detect displays and move panels to the primary display
# This script tries to move the Gnome panel to the screen that you want
# to make primary
#

# disper command will detect and configure monitors
disper --displays=auto -e

# parse output from disper tool how many displays we have attached
# disper prints 2 lines per displer
lines=`disper -l|wc -l`

display_count=$((lines / 2))

echo $display_count

echo "Detected display count:" $display_count

# Make sure that we move panels to the correct display based
# on the display count
if [ $display_count = 1 ] ; then
echo "Moving panels to the internal LCD display"
gconftool-2 \
--set "/apps/panel/toplevels/bottom_panel_screen0/monitor" \
--type integer "0"
gconftool-2 \
--set "/apps/panel/toplevels/top_panel_screen0/monitor" \
--type integer "0"
else
echo "Moving panels to the external display"
gconftool-2 \
--set "/apps/panel/toplevels/bottom_panel_screen0/monitor" \
--type integer "1"
gconftool-2 \
--set "/apps/panel/toplevels/top_panel_screen0/monitor" \
--type integer "1"
fi




Greg Rundlett





BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org