Chinaunix首页 | 论坛 | 博客
  • 博客访问: 104594431
  • 博文数量: 19283
  • 博客积分: 9968
  • 博客等级: 上将
  • 技术积分: 196062
  • 用 户 组: 普通用户
  • 注册时间: 2007-02-07 14:28
文章分类

全部博文(19283)

文章存档

2011年(1)

2009年(125)

2008年(19094)

2007年(63)

分类: LINUX

2008-04-30 09:40:05

作者:宝生的HOME  出自:

今天参考了编写显示器驱动的文章,自己写了个破烂HPC CA776显示器的驱动,显示器型号可以加入displayconfig-gtk这个显示配置工具的显示器列表,并且可以选择了。但是仅选择这个显示器型号仍然不行,还是需要手动修改xorg.conf,并且一种分辨率的对应一个xorg.conf,主要使用1280X1024和1024X768分辨率,以下将显示器驱动以及两个分辨率对应的xorg.conf写法列出来,以便作为个人备份。
显示器驱动----CA776.inf

; CA776.INF
;
; Version 3.9
;
; This is setup information file for
; CA776 Technology Co., Ltd. monitor product.
;
; Copyright (c) 1994-2002, hpc Technology Co., Ltd.
; Revision date: 8/08/02

[Version]
Signature="CHICAGO$"
Class=Monitor
Provider=%HPC%

[Manufacturer]
%HPC%=HPC

[HPC]
%CA776%=CA776, Monitor\CA776
[CA776]
DelReg=DEL_CURRENT_REG
AddReg=CA776.Add,1280,DPMS
[DEL_CURRENT_REG]
HKR,MODES
HKR,,MaxResolution
HKR,,DPMS
HKR,,ICMProfile

[1280]
HKR,,MaxResolution,,"1280,1024"
[DPMS]
HKR,,DPMS,,1

[ICM9]
HKR,,ICMProfile,1,9

[CA776.Add]
HKR,"MODES\1280,1024",Mode1,,"31.0-72.0,50.0-150.0,+,+"

[Strings]
HPC="HPC"
CA776="CA776"


1280X1024分辨率的xorg.conf

# xorg.conf (X.Org 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 xorg.conf manual page.
# (Type "man 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 "InputDevice"
Identifier "Generic Keyboard"
Driver "kbd"
Option "XkbRules" "xorg"
Option "XkbModel" "pc105"
Option "XkbLayout" "us"
EndSection

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
EndSection

Section "Device"
Identifier "Configured Video Device"
Boardname "Intel 945"
Busid "PCI:0:2:0"
Driver "intel"
Screen 0
Vendorname "Intel"
EndSection

Section "Monitor"
Identifier "Configured Monitor"
Vendorname "HPC"
Modelname "CA776"
Horizsync 31.0-72.0
Vertrefresh 50.0-150.0
modeline "640x480@85" 36.0 640 696 752 832 480 481 484 509 -vsync -hsync
modeline "800x600@85" 56.3 800 832 896 1048 600 601 604 631 +hsync +vsync
modeline "1024x768@85" 94.5 1024 1072 1168 1376 768 769 772 808 +hsync +vsync
modeline "1280x1024@60" 108.0 1280 1328 1440 1688 1024 1025 1028 1066 +hsync +vsync
Gamma 1.0
EndSection

Section "Screen"
Identifier "Default Screen"
Monitor "Configured Monitor"
Device "Configured Video Device"
Defaultdepth 24
SubSection "Display"
Depth 24
Virtual 1280 1024
Modes "1280x1024@60" "1024x768@85" "800x600@85" "640x480@85"
EndSubSection
EndSection

Section "ServerLayout"
Identifier "Default Layout"
screen 0 "Default Screen" 0 0
EndSection
Section "Module"
Load "glx"
Load "GLcore"
Load "dri"
Load "v4l"
EndSection
Section "ServerFlags"
EndSection


1024X768分辨率的xorg.conf内容

# xorg.conf (X.Org 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 xorg.conf manual page.
# (Type "man 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 "InputDevice"
Identifier "Generic Keyboard"
Driver "kbd"
Option "XkbRules" "xorg"
Option "XkbModel" "pc105"
Option "XkbLayout" "us"
EndSection

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
EndSection

Section "Device"
Identifier "Configured Video Device"
Boardname "Intel 945"
Busid "PCI:0:2:0"
Driver "intel"
Screen 0
Vendorname "Intel"
EndSection

Section "Monitor"
Identifier "Configured Monitor"
Vendorname "HPC"
Modelname "CA776"
Horizsync 31.0-72.0
Vertrefresh 50.0-150.0
modeline "640x480@85" 36.0 640 696 752 832 480 481 484 509 -vsync -hsync
modeline "800x600@85" 56.3 800 832 896 1048 600 601 604 631 +hsync +vsync
modeline "1024x768@85" 94.5 1024 1072 1168 1376 768 769 772 808 +hsync +vsync
Gamma 1.0
EndSection

Section "Screen"
Identifier "Default Screen"
Monitor "Configured Monitor"
Device "Configured Video Device"
Defaultdepth 24
SubSection "Display"
Depth 24
Virtual 1024 768
Modes "1024x768@85" "800x600@85" "640x480@85"
EndSubSection
EndSection

Section "ServerLayout"
Identifier "Default Layout"
screen 0 "Default Screen" 0 0
EndSection
Section "Module"
Load "glx"
Load "GLcore"
Load "dri"
Load "v4l"
EndSection
Section "ServerFlags"
EndSection
阅读(342) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~