Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 11-04-05, 10:23 AM   #1
CyberTron
Registered User
 
Join Date: Oct 2004
Posts: 7
Default Dualhead is working, but it is always on..

Hi!

I have a problem, and I expect that others have too...

I have a laptop, with a geforce4200go in it, and most of the time I am not connected to an external monitor, but once in a while I have my lcd-tv connected and therefore I have created a dual-head setup...It is working flawlessly...

but now for my problem, I only wanna use this WHEN, and only when, the external monitor is connected, as I have now, it is always configured to run, which starts up two instances of my vm and so on...(which is fine when using the other monitor)....

How can I do "a detection" that the screen isn't in use and in some way get the driver/xorg.conf file realize that I only have one screen actiive?

here is my xorg.conf (note: I will NOT use xinerama nor twinview)
if anyone has an idea, please share, I would prefer not using two xorg.conf's but if that is the only way, please explain where one might do a cat /some/file |grep "second monitor" and then do a bash-script which would choose to start either one of the xorg.conf -files

Code:
Section "ServerLayout"
	Identifier     "Default Layout"
	Screen      0  "Screen0" 0 0
	Screen      1  "ScreenTV" RightOf "Screen0"
	InputDevice    "Mouse0" "CorePointer"
	InputDevice    "Keyboard0" "CoreKeyboard"
	Option	       "Xinerama" "false"
EndSection

Section "Extensions"
  Option "Composite" "Enable"
EndSection

# *********************************************************************
#  Files section.  This allows default font and rgb paths to be set
#      not to self, this section should be good to go
# ********************************************************************
Section "Files"
    RgbPath    "/usr/X11R6/lib/X11/rgb"    
    ModulePath "/usr/X11R6/lib/modules"
    FontPath   "/usr/share/fonts/"
    FontPath   "/usr/X11R6/lib/X11/fonts/misc/"
    FontPath   "/usr/X11R6/lib/X11/fonts/75dpi/"
    FontPath   "/usr/X11R6/lib/X11/fonts/100dpi/"
    FontPath   "/usr/X11R6/lib/X11/fonts/Type1/"
    FontPath   "/usr/X11R6/lib/X11/fonts/TTF/"
    FontPath   "/usr/X11R6/lib/X11/fonts/Speedo/"
    FontPath   "/usr/X11R6/lib/X11/fonts/local/"
    FontPath   "/usr/X11R6/lib/X11/fonts/CID/"
    FontPath   "/usr/X11R6/lib/X11/fonts/artwiz-fonts/"
EndSection

# **********************************************************************
# Module section -- this is an optional section which is used to specify
# which run-time loadable modules to load when the X server starts up.
# **********************************************************************
Section "Module"
    Load  "glx"
    Load  "record"
    Load  "extmod"
    Load  "dbe"
    Load  "xtrap"
    Load  "freetype"
    Load  "type1"
EndSection

# **********************************************************************
# Keyboards         -  need to fix this...
# **********************************************************************
Section "InputDevice"
    Identifier "Keyboard0"
    Driver "kbd"
    Option "AutoRepeat" "500 30"
    Option "XkbModel" "pc105"
    Option "XkbLayout" "se"
EndSection

# **********************************************************************
# Mice (one section takes care of all)
# **********************************************************************
Section "InputDevice"
    Identifier  "Mouse0"
    Driver  "mouse"
    Option  "CorePointer"
    Option  "Protocol"        "ExplorerPS/2"
    Option  "Device"          "/dev/input/mice"
    Option  "ZAxisMapping"   "6 7"
    Option  "Buttons"	     "7"
    Option  "Emulate3Buttons" "on"
EndSection

Section "Monitor"
    Identifier  "Monitor0"
    ModelName "Dell Inspiron 8500 WXGA Panel"
    HorizSync   15-100.0
    VertRefresh 15.0-120.0
    DisplaySize  426 266
    # 60Hz
    Modeline "640x480" 25.175 640 664 760 800 480 491 493 525
    Modeline "800x600" 40.12 800 848 968 1056 600 601 605 628
    Modeline "1024x768" 85 1024 1056 1152 1360 768 784 787 823
    Modeline "1360x768"  84.50  1360 1392 1712 1744 768  783  791  807
    Modeline "1680x1050" 147.14 1680 1784 1968 2256 1050 1051 1054 1087
    # 75Hz
    Modeline "1680x1050" 188.07 1680 1800 1984 2288 1050 1051 1054 1096
    # 85Hz
    Modeline "1680x1050" 214.51 1680 1800 1984 2288 1050 1051 1054 1103
    # 100Hz
    Modeline "1680x1050" 256.20 1680 1808 1992 2304 1050 1051 1054 1112
EndSection

Section "Monitor"
	Identifier   "MonitorTV"
	VendorName   "Centrum"
	ModelName    "Centrum 32 widescreen TV"
	HorizSync    31.4 - 61
	VertRefresh  56-75
       DisplaySize  810 400
    #    Modeline    "1024x768@100" 85 1024 1056 1152 1360 768 784 787 823
	#Modeline    "1024x576@60" 45.81 1024 1056 1224 1256 576 587 593 605
	Modeline "1360x768" 85.750 1360 1432 1568 1776 768 771 776 798 -hsync +vsync
    #    Modeline "1360x768"  84.50  1360 1392 1712 1744 768  783  791  807
    #    ModeLine "1366x768" 88.03 1366 1424 1680 1816 768 770 782 808
        ModeLine "1368x768" 84.97 1368 1400 1720 1752 768 783 791 807


#	Option	    "TVStandard" "PAL-B"
#	Option	    "TVOutFormat" "SVIDEO"
EndSection

Section "Device"
	Identifier  "Videocard0"
	Driver      "nvidia"
	VendorName  "NVidia"
	BoardName   "NVIDIA GeForce 4200 Go"
	Option	    "NoLogo" "true"
	Option      "NvAGP" "3"
	BusID       "PCI:1:0:0"
    VideoRam 65536
    Option "DPMS" "true"
    BusID  "PCI:1:0:0"
    Option "RenderAccel" "true"
    Option "NoRenderExtension" "false"
#    Option "FlatPanelProperties" "Scaling = aspect-scaled"
    Option "NoPowerConnectorCheck" "true"
    Option "dpms"
    Option "UseEdidFreqs"   "yes"
    Option "IgnoreEDID" "false"
    Option "AllowDDCCI" "true"
    Option "Coolbits" "1"
    Option "AllowGLXWithComposite" "true"
    Option "NoFlip" "false"
    Option "RandRRotation" "false"
#    Option "DigitalVibrance" "2"
#		Option "SWCursor" "0"
#		Option "HWCursor" "1"
#		Option "CursorShadow" "1"
#		Option "CursorShadowAlpha" "64"
#		Option "CursorShadowXOffset" "4"
#		Option "CursorShadowYOffset" "2"
     Option "ConnectedMonitor" "DFP"
#    Option "TwinView" "1"
#    Option "TwinViewOrientation" "Clone"
#   Option "MetaModes" "1360x768, 1360x768; 800x600, 800x600; 640x480, 640x480"
#   Option "MetaModes" "DFP-0: 1360x768, CRT-0: 1360x768"
#    Option "NoTwinViewXineramaInfo" "1"
#    Option "TVStandard" "PAL-B"
#    Option "TVOutFormat" "SVIDEO"
#    Option "ConnectedMonitor" "DFP-0, TV-0"
#    Option "HorizSync" "DFP-0: 15-100; CRT-0: 30-60"
#    Option "VertRefresh" "DFP-0: 15-120; CRT-0: 30-60"
#    Option "TVOverScan" "0.6"
EndSection

Section "Device"
	Identifier  "VideocardTV"
	Driver      "nvidia"
	VendorName  "NVidia"
	BoardName   "NVIDIA GeForce 4200 Go"
	Option	    "NoLogo" "true"
	Option	    "ConnectedMonitor" "CRT"
	Option	    "NvAGP" "3"
	BusID       "PCI:1:0:0"
    VideoRam 65536
    Option "DPMS" "true"
    Option "RenderAccel" "true"
    Option "NoRenderExtension" "false"
    Option "NoPowerConnectorCheck" "true"
    Option "AllowGLXWithComposite" "true"
    Option "NoFlip" "false"
    Option "AllowDDCCI" "true"
    Option "Coolbits" "1"

    Option "RandRRotation" "false"
#    Option "DigitalVibrance" "2"
#		Option "SWCursor" "0"
#		Option "HWCursor" "1"
#		Option "CursorShadow" "1"
#		Option "CursorShadowAlpha" "64"
#		Option "CursorShadowXOffset" "4"
#		Option "CursorShadowYOffset" "2"
	Screen      1
EndSection

Section "Screen"
	Identifier "Screen0"
	Device     "Videocard0"
	Monitor    "Monitor0"
	DefaultDepth     24
    Subsection "Display"
        Depth       8
        Modes       "1680x1050" "1360x768" "1024x768" "800x600" "640x480"
        #ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       16
        Modes       "1680x1050" "1360x768" "1024x768" "800x600" "640x480"
        #ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       24
        Modes       "1680x1050" "1360x768" "1024x768" "800x600" "640x480"
        #ViewPort    0 0
    EndSubSection
EndSection

Section "Screen"
	Identifier "ScreenTV"
	Device     "VideocardTV"
	Monitor    "MonitorTV"
	DefaultDepth     24
	Subsection "Display"
        Depth       8
        Modes       "1360x768" "1024x768@60" "800x600@60" "640x480@60"
        #ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       16
        Modes       "1360x768" "1024x768" "800x600" "640x480"
        #ViewPort    0 0
    EndSubsection
    Subsection "Display"
        Depth       24
        Modes       "1368x768" "1360x768" "1024x768" "800x600" "640x480"
        #ViewPort    0 0
    EndSubSection
EndSection
CyberTron is offline   Reply With Quote
Old 11-04-05, 12:30 PM   #2
Thunderbird
 
Join Date: Jul 2002
Location: Netherlands, Europe
Posts: 2,105
Default Re: Dualhead is working, but it is always on..

What you want is not possible, there's no autodetection. You need to start X for instance using a different config file or a different serverlayout in your current config file. There's no other way.
Thunderbird is offline   Reply With Quote
Old 11-04-05, 01:03 PM   #3
CyberTron
Registered User
 
Join Date: Oct 2004
Posts: 7
Default Re: Dualhead is working, but it is always on..

ok, so it is not possiböe to make a bash script that does

if [ connected monitor crt and lcd ]
then
startx --config X
else
startx --config Y

??

I see the problem, but then again some /proc /sys file should have some knowledge about if there are a connected screen or not
CyberTron is offline   Reply With Quote
Old 11-04-05, 01:06 PM   #4
Thunderbird
 
Join Date: Jul 2002
Location: Netherlands, Europe
Posts: 2,105
Default Re: Dualhead is working, but it is always on..

Information about connected monitors can be queried using both nvclock and nvidia-settings but this only works when X is already running.
Thunderbird is offline   Reply With Quote
Old 11-04-05, 01:09 PM   #5
CyberTron
Registered User
 
Join Date: Oct 2004
Posts: 7
Default Re: Dualhead is working, but it is always on..

ok, then i have to live with that :/

thanks for your help anyway
CyberTron is offline   Reply With Quote
Old 11-04-05, 01:36 PM   #6
JanR
Registered User
 
Join Date: Oct 2005
Location: Berlin, Germany
Posts: 12
Default Re: Dualhead is working, but it is always on..

Hi,

I'm not 100% sure... but what about X -probeonly? Is this making DDC detection of monitors? I would expect that. If yes, than you can change your startup script in a way that it first runs X -probeonly, then parses the output and makes the right choice of X config.

Greetings,

Jan
JanR is offline   Reply With Quote
Old 11-25-05, 07:38 PM   #7
senfman
Registered User
 
Join Date: Nov 2005
Posts: 1
Default Re: Dualhead is working, but it is always on..

Quote:
Originally Posted by JanR
I'm not 100% sure... but what about X -probeonly? Is this making DDC detection of monitors? I would expect that. If yes, than you can change your startup script in a way that it first runs X -probeonly, then parses the output and makes the right choice of X config.
I've just tested this solution and it seems to work.
senfman is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
Tony Hawk devs working on Call of Duty News Gaming Headlines 0 06-15-12 10:30 AM
RH7.3, 3123, was working, now it isn't phips NVIDIA Linux 2 10-03-02 02:08 PM
Nvidia 3123 not working on Mandrake 8.2 UP with Geforce 440 MMX tariqf NVIDIA Linux 1 09-17-02 08:22 AM
TV-out not working nomatter what driver.. Dr_Gigolo NVIDIA Windows Graphics Drivers 11 09-11-02 11:11 AM
How do I get Dual Head working? Heath NVIDIA Linux 1 08-22-02 12:44 PM

All times are GMT -5. The time now is 05:45 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright ©1998 - 2014, nV News.