修改xorg.conf来实现龙芯2f高分辨率和彩色S-VEDIO输出

盒子到手以后,对了xorg.conf进行很多次的修改,首先是进行修改,以实现1280×1024分辨率,然后是调整S-VEDIO的输出。

摸索了很多方法,查了一些资料, 改来改去最后发现官方论坛的一个网友提供的sisctrl配置工具是最简单的生成合适xorg.conf的工具,下面就使用 这个工具进习惯配置的方法简单介绍一下。

先说,xorg.conf是xserver的配置文件,路径是:/etc/X11/xorg.conf。

然后下载这个工具:ftp://csjfyy.kmip.net/pxy/sisctrl_0.0.20051202-1_mipsel.deb 安装方法是dpkg -i ,用新德利也可以 。

安装以后,修改xorg.conf,加入: Option “EnableSiSCtrl” “yes” ,然后打开终端,使用命令sisctrl打开配置工具 ,这个时候就可以进行相关的设置,设置完毕以后,在 current 标签的窗口里 显示的 是 现在最合适的 xorg.conf配置,其中红色的部分是需要新添加的,对照系统原来的配置,进行修改即可。

在配置工具中可以直接配置更高的分辨率,这个不需要多讲,记得配置完后,看一下current标签的内容,对xorg.conf进行修改就可以了。

重要的是如何让电视机输出为彩色。这个问题,其实不是所有的电视机都存在,只是一些相对较老的CRT电视机存在。

参考网友帖子:
http://www.lemote.com/bbs/viewthread.php?tid=17042&extra=page%3D1 ,很快就配置完成。

具体的配置是把S-VEDIO连接好以后 ,打开电视机,然后盒子开机,这个时候pmon的加载显示应该是正常,可能到内核加载以及后续的启动过程就黑掉了(我这里就是),然后最后电视机会猛闪一阵,登录界面出现。但是可能是黑白的。那么现在登录,然后执行sisictrl,出现熟悉的sis的配置工具,然后切换到TV的选项,调整,”SISTVColorCalibCoarse” “SISTVColorCalibFine”,两项,基本上对”SISTVColorCalibCoarse”进行细微调整就可以了,我这里配置的值是-2,由于使用鼠标操作误差太大,因此建议直接使用键盘方向键操作。调整电视的色彩正常以后,记得看current的显示,对xorg.conf进习惯你修改,保存就可以了。

下面是我的盒子上自带rays系统上的配置,分辨率1280×1024,25寸老厦华CRT电视彩色s-vedio

loongson@RAYS-b0f748fa:~$ cat /etc/X11/xorg.conf
# /etc/X11/xorg.conf (xorg X Window System server configuration file)
#
# This file was generated by dexconf, the Debian X Configuration tool, using
# values from the debconf database.
#
# Edit this file with caution, and see the /etc/X11/xorg.conf manual page.
# (Type “man /etc/X11/xorg.conf” at the shell prompt.)
#
# This file is automatically updated on xserver-xorg package upgrades *only*
# if it has not been modified since the last upgrade of the xserver-xorg
# package.
#
# If you have edited this file but would like it to be automatically updated
# again, run the following command:
# sudo dpkg-reconfigure -phigh xserver-xorg

Section “Files”
FontPath “/usr/share/fonts/X11/misc”
# FontPath “/usr/share/fonts/X11/cyrillic”
FontPath “/usr/share/fonts/X11/100dpi/:unscaled”
FontPath “/usr/share/fonts/X11/75dpi/:unscaled”
FontPath “/usr/share/fonts/X11/Type1″
FontPath “/usr/share/fonts/X11/100dpi”
FontPath “/usr/share/fonts/X11/75dpi”
# path to defoma fonts
# FontPath “/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType”
EndSection

Section “Module”
Load “bitmap”
#Load “ddc”
Load “dri”
Load “extmod”
Load “freetype”
#Load “GLcore”
#Load “glx”
# Load “int10″
#Load “vbe”
EndSection

Section “InputDevice”
Identifier “Generic Keyboard”
Driver “kbd”
Option “CoreKeyboard”
Option “XkbRules” “xorg”
Option “XkbModel” “pc104″
Option “XkbLayout” “us”
EndSection

Section “InputDevice”
Identifier “Configured Mouse”
Driver “mouse”
Option “CorePointer”
Option “Device” “/dev/input/mice”
Option “Protocol” “ImPS/2″
EndSection

Section “Device”
Identifier “card0″
VendorName “Silicon”
BoardName “Silicon Integrated Systems [SiS] 315PRO PCI/AGP VGA Display Adapter”
Driver “sis”
BusID “PCI:0:8:0″
Option “UseFBDev” “False” # [<bool>]
Option “DisableGLXRootClipping” “false”
Option “AddARGBGLXVisals” “true”
Option “AllowGLXWithComposite” “true”
Option “EnablePageFlip” “true”
Option “AccelMethod” “XAA”
Option “ColorTiling” “true”
Option “RenderAccel” “true”
Option “AGPFastWrite” “true”
Option “NoBackBuffer” “false” # [<bool>]
Option “DMAForXv” “True” # [<bool>]
#Option “MonitorLayout” “TMDS,CRT” # [<str>]
#Option “CRT2HSync” “30-70″ # [<str>]
#Option “CRT2VRefresh” “50-75″ # [<str>]
#Option “MergedFB” “True” # [<bool>]
Option “MergedNonRectangular” “True” # [<bool>]
Option “NoInt10″ “True”
#Option “PanelSize” “1024×768″ # [<str>]
Option “CPusecTimeout” “0″
Option “EnableDepthMoves” “true”
Option “AccelDFS” “true”
Option “CPPIOMode” “true”
#Option “FBTexPercent” “2″
#Option “Shadowfb” “false”
#for firefox
Option “XAANoOffscreenPixmaps” “false”
Option “EnableSiSCtrl” “yes”
# [sisctrl] Set CRT1 device type (Note: overrides auto-detection)
Option “ForceCRT1Type” “VGA”

# [sisctrl] Set CRT2 device type (Note: overrides auto-detection)
#Option “ForceCRT2Type” “SVIDEO”

# [sisctrl] TV related options
Option “TVStandard” “PAL”
Option “SISTVAntiFlicker” “adaptive”
Option “SISTVSaturation” “0″
Option “SISTVColorCalibCoarse” “-2″
Option “SISTVColorCalibFine” “0″
Option “SISTVCFilter” “on”
Option “SISTVYFilter” “1″
Option “SISTVXScale” “0″
Option “SISTVYScale” “0″
Option “TVXPosOffset” “0″
Option “TVYPosOffset” “0″

# [sisctrl] Enable/disable Gamma correction for CRT1
Option “CRT1Gamma” “on”

# [sisctrl] Enable/disable gamma correction for CRT2
Option “CRT2Gamma” “on”

# [sisctrl] Brightness/contrast for CRT1 and CRT2
# The driver does NOT write these to the hardware. Instead, for
# using brightness/contrast, you need to execute sisctrl with the
# -setgammabrightness (or -sg) switch at X server start. It is
# most convenient to do this by adding this to your ~/.xsession
# or ~/.xinitrc file:
# sisctrl -sg
# If you run Xinerama, do that twice for both screens. Add this:
# sisctrl -screen 1 -sg
Option “Brightness” “0.000 0.000 0.000″
Option “Contrast” “0.000 0.000 0.000″

# Xv (video overlay) head selection
Option “XvOnCRT2″ “no”

# [sisctrl] Xv (video overlay) related options
Option “XvDefaultContrast” “2″
Option “XvDefaultBrightness” “10″
Option “XvDefaultHue” “0″
Option “XvDefaultSaturation” “0″
Option “XvDefaultDisableGfxLR” “no”
Option “XvGamma” “off”
EndSection

Section “Monitor”
Identifier “Generic Monitor”
#Option “DPMS”
#DisplaySize 1280 1024
# Gamma correction for CRT1 and CRT2
Gamma 0.830 0.830 0.830
EndSection

Section “Screen”
Identifier “Default Screen”
Device “card0″
Monitor “Generic Monitor”
DefaultDepth 24
#Option “Accel”
SubSection “Display”
Depth 16
Modes “1280×1024″
EndSubSection
SubSection “Display”
Depth 24
Modes “1280×1024″
EndSubSection
SubSection “Display”
Depth 8
Modes “1024×768″
EndSubSection
SubSection “Display”
Depth 15
Modes “1024×768″
EndSubSection
SubSection “Display”
Depth 16
Modes “1024×768″
EndSubSection
SubSection “Display”
Depth 24
Modes “1024×768″
EndSubSection
EndSection

Section “ServerLayout”
Identifier “Default Layout”
Screen “Default Screen”
InputDevice “Generic Keyboard”
InputDevice “Configured Mouse”
Option “AIGLX” “false”
EndSection

Section “DRI”
Group 0
Mode 0666
EndSection

另外经测试,发现在电视机上800×600分辨率效果最佳,看电影很爽。

Post a Comment

Your email is never shared. Required fields are marked *

*
*