LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices

Reply
 
LinkBack Search this Thread
Old 01-27-2012, 12:11 PM   #1
barbex
Member
 
Registered: Dec 2005
Location: Hamburg, Germany
Distribution: ubuntu
Posts: 39

Rep: Reputation: 15
nvidia: initialize screen if not connected


Hello!

I have a PC that I use as a media center in the living room. It has one small Monitor connected via VGA and the TV as a second screen connected via DVI -> HDMI.

I'm running ubuntu with xfce on it but I need to solve my problem on the X level.

It all works fine if the TV is turned on when the PC boots but I usually have the TV turned off. In that case the nvidia driver doesn't initialize the TV as a second display and I would have to turn it on and then restart X to get it working. (Annoying and not family friendly)

I hunted around in the nvidia driver options but I can't get it to work!

Here is my xorg.conf:

Code:
Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    Screen      1  "Screen1" LeftOf "Screen0"
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
EndSection

Section "Files"
EndSection

Section "InputDevice"

    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"

    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"

    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "GVC"
    HorizSync       31.0 - 53.0
    VertRefresh     56.0 - 85.0
    Option         "DPMS"
EndSection

Section "Monitor"

    # HorizSync source: unknown, VertRefresh source: unknown
    Identifier     "Monitor1"
    VendorName     "Unknown"
    ModelName      "Toshiba TFT-TV"
    HorizSync       15.0 - 46.0
    VertRefresh     49.0 - 61.0
    ModeLine       "1920x1080" 74.25 1920 2008 2052 2200 1080 1084 1094 1124 +hsync +vsync interlace
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce 6200"
    BusID          "PCI:2:0:0"
    Screen          0
EndSection

Section "Device"
    Identifier     "Device1"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce 6200"
    BusID          "PCI:2:0:0"
    Screen          1
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "TwinView" "0"
    Option         "TwinViewXineramaInfoOrder" "CRT-0"
    Option         "metamodes" "CRT: 800x600_60 +0+0"
    Option         "DPI"  "81 x 81"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "Monitor1"
    DefaultDepth    24
    Option         "UseEDID" "false"
    Option         "ConnectedMonitor" "DFP"
    Option         "ExactModeTimingsDVI" "TRUE"
    Option         "TwinView" "0"
    Option         "metamodes" "DFP: nvidia-auto-select +0+0"
    Option         "DPI"  "110 x 110"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection
And here is what the log says after booting:

Code:
 24.884] (II) NVIDIA(0): NVIDIA GPU GeForce 6200 (NV44) at PCI:2:0:0 (GPU-0)
[    24.884] (--) NVIDIA(0): Memory: 262144 kBytes
[    24.885] (--) NVIDIA(0): VideoBIOS: 05.44.a2.03.00
[    24.885] (II) NVIDIA(0): Detected AGP rate: 8X
[    24.885] (--) NVIDIA(0): Interlaced video modes are supported on this GPU
[    24.885] (--) NVIDIA(0): Connected display device(s) on GeForce 6200 at PCI:2:0:0
[    24.885] (--) NVIDIA(0):     GVC (CRT-0)
[    24.885] (--) NVIDIA(0): GVC (CRT-0): 400.0 MHz maximum pixel clock
[    24.885] (II) NVIDIA(0): Display Device found referenced in MetaMode: CRT-0
[    24.885] (II) NVIDIA(0): Assigned Display Device: CRT-0
[    24.885] (II) NVIDIA(0): Validated modes:
[    24.885] (II) NVIDIA(0):     "CRT:800x600_60+0+0"
[    24.885] (II) NVIDIA(0): Virtual screen size determined to be 800 x 600
[    24.887] (**) NVIDIA(0): DPI set to (81, 81); computed from "DPI" X config option
[    24.887] (==) NVIDIA(0): Enabling 32-bit ARGB GLX visuals.
[    24.887] (**) NVIDIA(1): Depth 24, (--) framebuffer bpp 32
[    24.887] (==) NVIDIA(1): RGB weight 888
[    24.887] (==) NVIDIA(1): Default visual is TrueColor
[    24.887] (==) NVIDIA(1): Using gamma correction (1.0, 1.0, 1.0)
[    24.887] (**) NVIDIA(1): Option "UseEDID" "false"
[    24.887] (**) NVIDIA(1): Option "ConnectedMonitor" "DFP"
[    24.887] (**) NVIDIA(1): Option "TwinView" "0"
[    24.887] (**) NVIDIA(1): Option "MetaModes" "DFP: 1920x1080_60 +0+0"
[    24.887] (**) NVIDIA(1): Option "ExactModeTimingsDVI" "TRUE"
[    24.887] (**) NVIDIA(1): Option "DPI" "110 x 110"
[    24.887] (**) NVIDIA(1): Enabling RENDER acceleration
[    24.888] (II) NVIDIA(1): NVIDIA GPU GeForce 6200 (NV44) at PCI:2:0:0 (GPU-0)
[    24.892] (--) NVIDIA(1): Memory: 262144 kBytes
[    24.892] (--) NVIDIA(1): VideoBIOS: 05.44.a2.03.00
[    24.892] (II) NVIDIA(1): Detected AGP rate: 8X
[    24.892] (--) NVIDIA(1): Interlaced video modes are supported on this GPU
[    24.892] (--) NVIDIA(1): Connected display device(s) on GeForce 6200 at PCI:2:0:0
[    24.892] (--) NVIDIA(1):     GVC (CRT-0)
[    24.892] (--) NVIDIA(1): GVC (CRT-0): 400.0 MHz maximum pixel clock
[    24.892] (EE) NVIDIA(1): Unable to find available Display Devices for screen 1.
[    24.892] (EE) NVIDIA(1): No display devices found for this X screen.
[    24.892] (II) UnloadModule: "nvidia"
[    24.892] (II) UnloadModule: "wfb"
[    24.892] (II) UnloadModule: "fb"
[    24.892] (--) Depth 24 pixmap format is 32 bpp
[    24.893] (II) NVIDIA(0): Initialized AGP GART.
[    24.903] (II) NVIDIA(0): Setting mode "CRT:800x600_60+0+0"
[    25.005] (II) Loading extension NV-GLX
[    25.229] (II) NVIDIA(0): Initialized OpenGL Acceleration
[    25.236] (==) NVIDIA(0): Disabling shared memory pixmaps
[    25.236] (II) NVIDIA(0): Initialized X Rendering Acceleration
[    25.236] (==) NVIDIA(0): Backing store disabled
[    25.236] (==) NVIDIA(0): Silken mouse enabled
[    25.237] (**) NVIDIA(0): DPMS enabled
[    25.237] (II) Loading extension NV-CONTROL
[    25.237] (II) Loading extension XINERAMA
[    25.237] (II) Loading sub module "dri2"
[    25.237] (II) LoadModule: "dri2"
[    25.238] (II) Reloading /usr/lib/xorg/modules/extensions/libdri2.so
[    25.238] (II) NVIDIA(0): [DRI2] Setup complete
[    25.238] (==) RandR enabled
From what I read in the nvidia readme Option "ConnectedMonitor" "DFP" is supposed to do exactly what I want but it doesn't work.

Anything else I can try?
 
Old 01-29-2012, 01:24 AM   #2
ukiuki
Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian, Ubuntu, Tinycore
Posts: 464

Rep: Reputation: 81
I believe there is a way to switch monitors and probably it can be done with some applet, when you say restart X you mean shut it down and restart it? Have you tried to just logout/login? Your xorg.conf seen alright it is just a matter to find a way to switch monitors.

Does this only show in the log when the TV is off?:
Code:
[    24.892] (EE) NVIDIA(1): Unable to find available Display Devices for screen 1.
[    24.892] (EE) NVIDIA(1): No display devices found for this X screen.
Regards
 
Old 01-30-2012, 12:11 PM   #3
barbex
Member
 
Registered: Dec 2005
Location: Hamburg, Germany
Distribution: ubuntu
Posts: 39

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by ukiuki View Post
Have you tried to just logout/login? Your xorg.conf seen alright it is just a matter to find a way to switch monitors.
I just tested it and it is indeed enough! If I turn on the TV and then logout - login the screen does get initialized.

Quote:
Does this only show in the log when the TV is off?:
Code:
[    24.892] (EE) NVIDIA(1): Unable to find available Display Devices for screen 1.
[    24.892] (EE) NVIDIA(1): No display devices found for this X screen.
Yes that only appears when the TV is turned off, when it is turned on while the PC boots, the X screen knows where to go.
All I want is, that it does that no matter what is connected.
 
Old 01-31-2012, 12:42 AM   #4
ukiuki
Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian, Ubuntu, Tinycore
Posts: 464

Rep: Reputation: 81
Another thing you could try is, open the nvidia settings, there is an option to detect screens/monitors i believe that will work as well, not 100% sure. But give a try !

Regards
 
Old 02-01-2012, 02:20 AM   #5
barbex
Member
 
Registered: Dec 2005
Location: Hamburg, Germany
Distribution: ubuntu
Posts: 39

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by ukiuki View Post
Another thing you could try is, open the nvidia settings, there is an option to detect screens/monitors i believe that will work as well, not 100% sure. But give a try !
No it doesn't. It detects the TV (if it's turned on) but then it can't save the configuration cause a new display is to deep in X territory or something.
Sigh, I don't know what to do, logout/login only works for me cause I know the password, I don't want my kids to know that.
 
Old 02-01-2012, 02:53 AM   #6
ukiuki
Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian, Ubuntu, Tinycore
Posts: 464

Rep: Reputation: 81
I found this worth take a look: http://ubuntuforums.org/showthread.p...detect+monitor
With some tweaking on your xorg.conf you will be able to get that going.

Somelines have to be changed, try this:
Code:
Section "Screen"
...
    Option         "ConnectedMonitor" "DFP-1, CRT-1"
    Option         "UseDisplayDevice" "DFP-1, CRT-1"
    Option         "TwinView" "TRUE"
...
EndSection

Regards

Last edited by ukiuki; 02-01-2012 at 03:04 AM. Reason: added info
 
Old 02-05-2012, 09:39 AM   #7
barbex
Member
 
Registered: Dec 2005
Location: Hamburg, Germany
Distribution: ubuntu
Posts: 39

Original Poster
Rep: Reputation: 15
No, that doesn't work either.

As the nvidia readme says:
Quote:
When assigning display devices to X screens, the NVIDIA X driver walks through the list of all (not already assigned) display devices detected as connected. When the "UseDisplayDevice" X configuration option is specified, the X driver will only consider connected display devices which are also included in the "UseDisplayDevice" list. This can be thought of as a "mask" against the connected (and not already assigned) display devices.

Note the subtle difference between this option and the "ConnectedMonitor" option: the "ConnectedMonitor" option overrides which display devices are actually detected, while the "UseDisplayDevice" option controls which of the detected display devices will be used on this X screen.
So unless the screen is detected, "UseDisplayDevice" won't use it (Yes, I tried it anyway). Which brings me back to "ConnectedMonitor" that really should do what I want but doesn't.


Now with the second option,I'm not quite sure where to put it. I have two Screen sections in my xorg.conf:
Code:
Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "TwinView" "0"
    Option         "TwinViewXineramaInfoOrder" "CRT-0"
    Option         "metamodes" "CRT: 800x600_60 +0+0"
    Option         "DPI"  "81 x 81"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "Monitor1"
    DefaultDepth    24
    Option         "UseEDID" "false"
    Option         "ConnectedMonitor" "DFP"
    Option         "ExactModeTimingsDVI" "TRUE"
    Option         "TwinView" "0"
    Option         "metamodes" "DFP: 1920×1080_60 +0+0"
    Option         "DPI"  "110 x 110"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection
should I write Option "ConnectedMonitor" "DFP-1, CRT-1" in both sections only switched around?


Would Twinview really change any of this? I'm reluctant to try that, separate X screens work well for me.
 
Old 02-05-2012, 02:21 PM   #8
ukiuki
Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian, Ubuntu, Tinycore
Posts: 464

Rep: Reputation: 81
For the second cos DPF-0 would be the first. I dont think you need both.

I did notice that in your file it is using binary for Twinview but over there in the other forum they are using boolean.
Binary uses 1 to say yes or activate and zero to say no or deactivate.
Boolean uses true or false to do the same thing.
I don't think it does use both that isn't how things are usually made. But there is chance to some options use more than one type of flags.

You will need to find which is the correct value for your current xorg, i found this: http://en.wikibooks.org/wiki/NVidia/Twin_View, you can see there is says "On", so you will have to try to see which one really works.
Here i see different way and here like yours. So yes you have to try.

I hope this helps.

In that Nvidia Readme says:
Option "TwinView" "boolean"

Regards

Last edited by ukiuki; 02-05-2012 at 02:29 PM. Reason: added info
 
Old 02-08-2012, 02:18 AM   #9
barbex
Member
 
Registered: Dec 2005
Location: Hamburg, Germany
Distribution: ubuntu
Posts: 39

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by ukiuki View Post
For the second cos DPF-0 would be the first. I dont think you need both.

I did notice that in your file it is using binary for Twinview but over there in the other forum they are using boolean.
Binary uses 1 to say yes or activate and zero to say no or deactivate.
Boolean uses true or false to do the same thing.

In that Nvidia Readme says:
Option "TwinView" "boolean"
How can something so simple be so confusing?

Thanks, I'll check it out.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
(EE) NVIDIA(0): Failed to initialize the NVIDIA Kernel module latino Linux - Hardware 5 06-03-2008 03:55 AM
(EE) NVIDIA(0): Failed to initialize the nvidia kernel hutchingson Fedora 1 06-16-2006 04:34 PM
(EE) NVIDIA(0): Failed to initialize the nvidia kernel module necbrownie Slackware 18 06-16-2006 02:20 AM
(EE) NVIDIA(0): Failed to initialize the NVIDIA kernel module! Stan the caddy Linux - Hardware 8 01-18-2004 04:21 PM
(EE) NVIDIA (0) Failed to initialize the NVIDIA kernel module Isjhe Mandriva 14 09-25-2003 09:29 PM


All times are GMT -5. The time now is 06:09 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration