使用英特尔 GPU 设置 Ubuntu-Server 以实现自定义分辨率

使用英特尔 GPU 设置 Ubuntu-Server 以实现自定义分辨率

简洁版本:
如何完全禁用 DisplayPort 和显示克隆,并在 CRT 上仅使用自定义分辨率为 1920x240 (15KHz) 的 VGA。可能需要创建自定义 xorg.conf


长版本:
我正在努力在 Ubuntu Server 中安装 RetroPie,我想在 SONY PVM 15KHz CRT 显示器上使用。一旦 RetroArch 启动,一切都会正常,游戏会通过 CRTswitchRes 功能显示,并在屏幕上看起来很棒 - 只是 Linux 环境让我很为难。

我选择使用所谓的“超级分辨率”,这种分辨率非常宽(例如 1920x240),当输入到 CRT 时看起来是正确的。为了能够导航前端,必须将控制台设置为类似的设置,并且有一些我想解决的陷阱。

首先,这是我使用的硬件:HP Compaq Elite 8000 Ultra Small Desktop [电子邮件保护]、8GB DDR3、英特尔 GMA 4500 DisplayPort(连接至三星显示器)、VGA(使用定制电缆连接至 CRT)

主要问题似乎是 Xorg 无法做任何事情,因为 CRT 不会通过 EDID 提供任何信息。另外,我读到过,使用英特尔时不能使用显示克隆,否则系统总是使用两个显示器都支持的分辨率。

简而言之:xrandr 输出始终是: 无法打开显示

Ubuntu 的版本其实并不重要,我尝试了 14、16 和 18 LTS,结果相同:RetroArch 可以工作,控制台不行。我不想切换到 Ubuntu-Desktop,因为我希望它尽可能流畅。现在我正在尝试使用 18.10 LTS。

所以,不管有没有 RetroPie,我都尽力去得到想要的分辨率:

  • 创建 EDID 二进制文件并在 /etc/default/grub 中引用它
  • 在 grub 文件中尝试了许多不同的参数
  • 用这个修补内核:https://github.com/TiBeN/15khz-arcade-pkg/blob/master/doc/15khz-package-documentation.md
  • 安装了英特尔驱动程序 xf86-video-intel 和 xserver-xorg-video-intel,但两者都给我的 RetroPie 带来了性能问题。
  • 由于 xorg.conf 自动创建失败,我尝试自己创建,但前端甚至无法启动,因为我不知道该在里面放什么。

我收集的一些系统信息:

hwinfo --gfxcard

07: PCI 02.0: 0300 VGA compatible controller (VGA)              
  [Created at pci.366]
  Unique ID: _Znp.QUyWiVSQCGD
  SysFS ID: /devices/pci0000:00/0000:00:02.0
  SysFS BusID: 0000:00:02.0
  Hardware Class: graphics card
  Model: "Intel 4 Series Chipset Integrated Graphics Controller"
  Vendor: pci 0x8086 "Intel Corporation"
  Device: pci 0x2e12 "4 Series Chipset Integrated Graphics Controller"
  SubVendor: pci 0x103c "Hewlett-Packard Company"
  SubDevice: pci 0x3648 
  Revision: 0x03
  Driver: "i915"
  Driver Modules: "drm"
  Memory Range: 0xf0000000-0xf03fffff (rw,non-prefetchable)
  Memory Range: 0xe0000000-0xefffffff (ro,non-prefetchable)
  I/O Ports: 0x1230-0x1237 (rw)
  IRQ: 31 (33735 events)
  I/O Ports: 0x3c0-0x3df (rw)
  Module Alias: "pci:v00008086d00002E12sv0000103Csd00003648bc03sc00i00"
  Driver Info #0:
    Driver Status: i915 is active
    Driver Activation Cmd: "modprobe i915"
  Config Status: cfg=new, avail=yes, need=no, active=unknown

08: PCI 02.1: 0380 Display controller
  [Created at pci.366]
  Unique ID: ruGf.xwJ9cLl4Ut2
  SysFS ID: /devices/pci0000:00/0000:00:02.1
  SysFS BusID: 0000:00:02.1
  Hardware Class: graphics card
  Model: "Intel 4 Series Chipset Integrated Graphics Controller"
  Vendor: pci 0x8086 "Intel Corporation"
  Device: pci 0x2e13 "4 Series Chipset Integrated Graphics Controller"
  SubVendor: pci 0x103c "Hewlett-Packard Company"
  SubDevice: pci 0x3648 
  Revision: 0x03
  Memory Range: 0xf0400000-0xf04fffff (rw,non-prefetchable,disabled)
  Module Alias: "pci:v00008086d00002E13sv0000103Csd00003648bc03sc80i00"
  Config Status: cfg=new, avail=yes, need=no, active=unknown

Primary display adapter: #7

++++++++++++++++++++++++++++++++++++++++++++++++++++++

hwinfo --monitor

20: None 00.0: 10002 LCD Monitor                                
  [Created at monitor.125]
  Unique ID: rdCR.k6CV94ujG82
  Parent ID: _Znp.QUyWiVSQCGD
  Hardware Class: monitor
  Model: "SAMSUNG SyncMaster"
  Vendor: SAM "SAMSUNG"
  Device: eisa 0x01ae "SyncMaster"
  Serial ID: "HS3P601288"
  Resolution: 720x400@70Hz
  Resolution: 640x480@60Hz
  Resolution: 640x480@67Hz
  Resolution: 640x480@72Hz
  Resolution: 640x480@75Hz
  Resolution: 800x600@56Hz
  Resolution: 800x600@60Hz
  Resolution: 800x600@72Hz
  Resolution: 800x600@75Hz
  Resolution: 832x624@75Hz
  Resolution: 1024x768@60Hz
  Resolution: 1024x768@70Hz
  Resolution: 1024x768@75Hz
  Resolution: 1280x1024@75Hz
  Resolution: 1600x1200@60Hz
  Resolution: 1280x1024@60Hz
  Resolution: 1280x960@60Hz
  Resolution: 1152x864@75Hz
  Size: 408x306 mm
  Year of Manufacture: 2007
  Week of Manufacture: 24
  Detailed Timings #0:
     Resolution: 1600x1200
     Horizontal: 1600 1664 1856 2160 (+64 +256 +560) +hsync
       Vertical: 1200 1201 1204 1250 (+1 +4 +50) +vsync
    Frequencies: 162.00 MHz, 75.00 kHz, 60.00 Hz
  Driver Info #0:
    Max. Resolution: 1600x1200
    Vert. Sync Range: 56-75 Hz
    Hor. Sync Range: 30-81 kHz
    Bandwidth: 162 MHz
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #2 (VGA compatible controller)

++++++++++++++++++++++++++++++++++++++++++++++++++++++

lspci | grep VGA

00:02.0 VGA compatible controller: Intel Corporation 4 Series Chipset Integrated Graphics Controller (rev 03)

++++++++++++++++++++++++++++++++++++++++++++++++++++++

glxgears -info

Error: couldn't open display (null)

++++++++++++++++++++++++++++++++++++++++++++++++++++++

xrandr

Can't open display 

++++++++++++++++++++++++++++++++++++++++++++++++++++++

ls /sys/class/drm/

card0  card0-DP-1  card0-HDMI-A-1  card0-VGA-1  controlD64  renderD128  version

++++++++++++++++++++++++++++++++++++++++++++++++++++++

/etc/default/grub

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
#   info -f grub -n 'Simple configuration'

GRUB_DEFAULT=saved
GRUB_SAVEDEFAULT=true
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=0
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
#GRUB_CMDLINE_LINUX_DEFAULT="gfxpayload=640x480x16,640x480 video=card0-VGA-1:640x480@60ec"
GRUB_CMDLINE_LINUX_DEFAULT="video=card0-VGA-1:640x240ec drm_kms_helper.edid_firmware=card0-VGA-1:/lib/f$
GRUB_CMDLINE_LINUX="quiet splash consoleblank=0 video=card0-VGA-1:640x240ec drm_kms_helper.edid_firmwar$

# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
GRUB_GFXMODE="640x240x32 ; 640x240x24 ; 640x240x16"
GRUB_GFXPAYLOAD="640x240x32 ; 640x240x24 ; 640x240x16"

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"

++++++++++++++++++++++++++++++++++++++++++++++++++++++

该套装的图片
RetroArch 启动后,一切立即生效
1920x240 在 CRT 上看起来完美

答案1

我不知道如果我通过 SSH 触发 xrandr,预期输出的是“无法打开显示”消息。我解决了这个问题,并能够创建满足我需求的模式行。

相关内容