我试图让 X 从我的笔记本电脑上使用 3 个外接显示器。
TLDR;它有 10% 的时间工作。 arandr
显示一个包含监视器的浅灰色框(见图)。当显示器不完全适合时,我会出错。
X 的配置中调用的浅灰色背景框是什么(见图)? 如何设置浅灰色框的大小?
这在 10% 的时间内有效:
- 1x 笔记本电脑屏幕 eDP1 (1920x1080),
- 2x 外部 DVI-I-1 和 DVI-I-2 (1920x1080) 通过此 USB3 设备
- 1 个外部 HDMI1 (1680x900)
这是 arandr 构建的脚本(为可读性添加了换行符)。
#!/bin/sh
xrandr --output VIRTUAL1 --off
--output eDP1 --primary --mode 1920x1080 --pos 0x1080 --rotate normal
--output HDMI1 --mode 1600x900 --pos 1920x1080 --rotate normal
--output VGA1 --off --output DVI-I-1 --mode 1920x1080 --pos 1920x0 --rotate normal
--output DVI-I-2 --mode 1920x1080 --pos 0x0 --rotate normal
问题似乎出在 HDMI 显示器上,分辨率为 1600x900。当 x 尝试自动配置它时,它使宽度为 1920+1600 而不是 1920+1920。见下图。
脚本给出错误
如果未插入 HDMI:
xrandr:找不到模式 1600x900
如果 HDMI 已插入,但 DVI-I-1 在浅灰色背景框之外
XRandR 失败:XRandR 返回错误代码 1:X 失败请求错误:BadValue(整数参数超出操作范围)失败请求的主要操作码:140(RANDR)失败请求的次要操作码:21(RRSetCrtcConfig)失败请求中的值: 0x780 失败请求的序列号:53 输出流中的当前序列号:53
或下图中的错误(最常见)
这偶尔会起作用,当所有东西都插入时,笔记本电脑会神奇地配置,或者
- USB 或 HDMI 显示器不工作或
- 屏幕缓冲区损坏,我必须按 ctrl-alt-backspace 或
- 随机效果掷 d20(镜像等)。
arandr
如下所示(注意 DVI-I-1 如何位于浅灰色背景之外)。在玩了很多之后:
- 当浅灰色背景不适合显示器时,它永远不会工作。
- 当浅灰色背景适合显示器时,它总是有效。
- 当我最后插入 HDMI 显示器时,它有时会起作用,但不可靠。
如果我运行这个 xrandr(没有 HDMI),我会得到一个错误:
☀ ./3up.sh
X Error of failed request: BadValue (integer parameter out of range for operation)
Major opcode of failed request: 140 (RANDR)
Minor opcode of failed request: 21 (RRSetCrtcConfig)
Value in failed request: 0x780
Serial number of failed request: 53
Current serial number in output stream: 53
michael@mc-desktop ~
☔ cat 3up.sh
#!/bin/sh
xrandr --output VIRTUAL1 --off \
--output eDP1 --primary --mode 1920x1080 --pos 0x1080 --rotate normal \
--output VGA1 --off \
--output DVI-I-1 --mode 1920x1080 --pos 1920x0 --rotate normal \
--output DVI-I-2 --mode 1920x1080 --pos 0x0 --rotate normal \
--output HDMI1 --off
我在 System76 笔记本电脑上使用 Linux Mint 18。
谢谢!