How do I configure X-Windows using xf86config?

This subsection deals with the question of configuration of X-windows.  The procedure is not Distribution specific and should work in most cases (except in cases, of course, that  the Display Adapter is not supported by XFree86.  In such cases, one might be able to download later versions of drivers off the web.  But for now, the concentration is basically on how the entire setup should be made.  This is a no-frills procedure and should work in a majority of the cases.

First, before xf86config is called, you should know the make and model of your Display Adapter and the amount of memory on the adapter.   You can find this out by issuing the command:-

[root@localhost /]# SuperProbe

The following message should appear:-

SuperProbe Version 2.15 (4 August 1997)
        (c) Copyright 1993,1994 by David Wexelblat <dwex@xfree86.org>

        This work is derived from the 'vgadoc2.zip' and
        'vgadoc3.zip' documentation packages produced by Finn
        Thoegersen, and released with all appropriate permissions
        having been obtained.  Additional information obtained from
        'Programmer's Guide to the EGA and VGA, 2nd ed', by Richard
        Ferraro, and from manufacturer's data books

The author welcomes bug reports and other comments mailed to
the electronic mail address above.  In particular, reports of
chipsets that this program fails to correctly detect are
appreciated.

Before submitting a report, please make sure that you have the
latest version of SuperProbe (see http://www.xfree86.org/FAQ).

WARNING - THIS SOFTWARE COULD HANG YOUR MACHINE.
          READ THE SuperProbe.1 MANUAL PAGE BEFORE
          RUNNING THIS PROGRAM.

          INTERRUPT WITHIN FIVE SECONDS TO ABORT!
 

After a short while, something like the following should appear:-

        First video: Super-VGA
        Chipset: ATI 264CT (Port Probed)
        Memory:  2048 Kbytes
        RAMDAC:  ATI Mach64 integrated 15/16/24/32-bit DAC w/clock
                 (with 6-bit wide lookup tables (or in 6-bit mode))
                 (programmable for 6/8-bit wide lookup tables)
        Attached graphics coprocessor:
                Chipset: ATI Mach64
                Memory:  2048 Kbytes
 

This is the detected Display Adapter on your system.  Take down the details, such as chipset and memory.

Issue xf86config:-

[root@localhost /]# xf86config

The following message should appear:-

This program will create a basic XF86Config file, based on menu selections you
make.

The XF86Config file usually resides in /usr/X11R6/lib/X11 or /etc/X11. A sample
XF86Config file is supplied with XFree86; it is configured for a standard
VGA card and monitor with 640x480 resolution. This program will ask for a
pathname when it is ready to write the file.

You can either take the sample XF86Config as a base and edit it for your
configuration, or let this program produce a base XF86Config file for your
configuration and fine-tune it. Refer to /usr/X11R6/lib/X11/doc/README.Config
for a detailed overview of the configuration process.

For accelerated servers (including accelerated drivers in the SVGA server),
there are many chipset and card-specific options and settings. This program
does not know about these. On some configurations some of these settings must
be specified. Refer to the server man pages and chipset-specific READMEs.

Before continuing with this program, make sure you know the chipset and
amount of video memory on your video card. SuperProbe can help with this.
It is also helpful if you know what server you want to run.

Press enter to continue, or ctrl-c to abort.
 
Press <enter>.

This program will create a basic XF86Config file, based on menu selections you
make.

The XF86Config file usually resides in /usr/X11R6/lib/X11 or /etc/X11. A sample
XF86Config file is supplied with XFree86; it is configured for a standard
VGA card and monitor with 640x480 resolution. This program will ask for a
pathname when it is ready to write the file.

You can either take the sample XF86Config as a base and edit it for your
configuration, or let this program produce a base XF86Config file for your
configuration and fine-tune it. Refer to /usr/X11R6/lib/X11/doc/README.Config
for a detailed overview of the configuration process.

For accelerated servers (including accelerated drivers in the SVGA server),
there are many chipset and card-specific options and settings. This program
does not know about these. On some configurations some of these settings must
be specified. Refer to the server man pages and chipset-specific READMEs.

Before continuing with this program, make sure you know the chipset and
amount of video memory on your video card. SuperProbe can help with this.
It is also helpful if you know what server you want to run.

Press enter to continue, or ctrl-c to abort.

Press <enter> again.

This program will create a basic XF86Config file, based on menu selections you
make.

The XF86Config file usually resides in /usr/X11R6/lib/X11 or /etc/X11. A sample
XF86Config file is supplied with XFree86; it is configured for a standard
VGA card and monitor with 640x480 resolution. This program will ask for a
pathname when it is ready to write the file.

You can either take the sample XF86Config as a base and edit it for your
configuration, or let this program produce a base XF86Config file for your
configuration and fine-tune it. Refer to /usr/X11R6/lib/X11/doc/README.Config
for a detailed overview of the configuration process.

For accelerated servers (including accelerated drivers in the SVGA server),
there are many chipset and card-specific options and settings. This program
does not know about these. On some configurations some of these settings must
be specified. Refer to the server man pages and chipset-specific READMEs.

Before continuing with this program, make sure you know the chipset and
amount of video memory on your video card. SuperProbe can help with this.
It is also helpful if you know what server you want to run.

Press enter to continue, or ctrl-c to abort.

Press <enter>.
 

First specify a mouse protocol type. Choose one from the following list:

 1.  Microsoft compatible (2-button protocol)
 2.  Mouse Systems (3-button protocol)
 3.  Bus Mouse
 4.  PS/2 Mouse
 5.  Logitech Mouse (serial, old type, Logitech protocol)
 6.  Logitech MouseMan (Microsoft compatible)
 7.  MM Series
 8.  MM HitTablet
 9.  Microsoft IntelliMouse

If you have a two-button mouse, it is most likely of type 1, and if you have
a three-button mouse, it can probably support both protocol 1 and 2. There are
two main varieties of the latter type: mice with a switch to select the
protocol, and mice that default to 1 and require a button to be held at
boot-time to select protocol 2. Some mice can be convinced to do 2 by sending
a special sequence to the serial port (see the ClearDTR/ClearRTS options).

Enter a protocol number: 4

If you have PS/2 type mouse then select 4, then <Enter>.   Otherwise, the safest selection is 1, then <Enter>.
 
If your mouse has only two buttons, it is recommended that you enable
Emulate3Buttons.

Please answer the following question with either 'y' or 'n'.
Do you want to enable Emulate3Buttons? y

Now give the full device name that the mouse is connected to, for example
/dev/tty00. Just pressing enter will use the default, /dev/mouse.

Mouse device:

Press <Enter>
 
Beginning with XFree86 3.1.2D, you can use the new X11R6.1 XKEYBOARD
extension to manage the keyboard layout. If you answer 'n' to the following
question, the server will use the old method, and you have to adjust
your keyboard layout with xmodmap.

Please answer the following question with either 'y' or 'n'.
Do you want to use XKB? y

Press 'y' then <Enter>

List of preconfigured keymaps:

  1  Standard 101-key, US encoding
  2  Microsoft Natural, US encoding
  3  KeyTronic FlexPro, US encoding
  4  Standard 101-key, US encoding with ISO9995-3 extensions
  5  Standard 101-key, German encoding
  6  Standard 101-key, French encoding
  7  Standard 101-key, Thai encoding
  8  Standard 101-key, Swiss/German encoding
  9  Standard 101-key, Swiss/French encoding
 10  None of the above

Enter a number to choose the keymap.

1

Press "1" then <Enter>
 

Now we want to set the specifications of the monitor. The two critical
parameters are the vertical refresh rate, which is the rate at which the
the whole screen is refreshed, and most importantly the horizontal sync rate,
which is the rate at which scanlines are displayed.

The valid range for horizontal sync and vertical sync should be documented
in the manual of your monitor. If in doubt, check the monitor database
/usr/X11R6/lib/X11/doc/Monitors to see if your monitor is there.

Press enter to continue, or ctrl-c to abort.

Press <Enter>

You must indicate the horizontal sync range of your monitor. You can either
select one of the predefined ranges below that correspond to industry-
standard monitor types, or give a specific range.

It is VERY IMPORTANT that you do not specify a monitor type with a horizontal
sync range that is beyond the capabilities of your monitor. If in doubt,
choose a conservative setting.

    hsync in kHz; monitor type with characteristic modes
 1  31.5; Standard VGA, 640x480 @ 60 Hz
 2  31.5 - 35.1; Super VGA, 800x600 @ 56 Hz
 3  31.5, 35.5; 8514 Compatible, 1024x768 @ 87 Hz interlaced (no 800x600)
 4  31.5, 35.15, 35.5; Super VGA, 1024x768 @ 87 Hz interlaced, 800x600 @ 56 Hz
 5  31.5 - 37.9; Extended Super VGA, 800x600 @ 60 Hz, 640x480 @ 72 Hz
 6  31.5 - 48.5; Non-Interlaced SVGA, 1024x768 @ 60 Hz, 800x600 @ 72 Hz
 7  31.5 - 57.0; High Frequency SVGA, 1024x768 @ 70 Hz
 8  31.5 - 64.3; Monitor that can do 1280x1024 @ 60 Hz
 9  31.5 - 79.0; Monitor that can do 1280x1024 @ 74 Hz
10  31.5 - 82.0; Monitor that can do 1280x1024 @ 76 Hz
11  Enter your own horizontal sync range

Enter your choice (1-11): 4

"4" is normally safe.   After that, press <Enter>.

You must indicate the vertical sync range of your monitor. You can either
select one of the predefined ranges below that correspond to industry-
standard monitor types, or give a specific range. For interlaced modes,
the number that counts is the high one (e.g. 87 Hz rather than 43 Hz).

 1  50-70
 2  50-90
 3  50-100
 4  40-150
 5  Enter your own vertical sync range

Enter your choice: 4

"4" is once again, normally safe.  After that, press <Enter>.

The strings are free-form, spaces are allowed.
Enter an identifier for your monitor definition:
Enter the vendor name of your monitor:
Enter the model name of your monitor:

Press <Enter> to each of the above.

Now we must configure video card specific settings. At this point you can
choose to make a selection out of a database of video card definitions.
Because there can be variation in Ramdacs and clock generators even
between cards of the same model, it is not sensible to blindly copy
the settings (e.g. a Device section). For this reason, after you make a
selection, you will still be asked about the components of the card, with
the settings from the chosen database entry presented as a strong hint.

The database entries include information about the chipset, what server to
run, the Ramdac and ClockChip, and comments that will be included in the
Device section. However, a lot of definitions only hint about what server
to run (based on the chipset the card uses) and are untested.

If you can't find your card in the database, there's nothing to worry about.
You should only choose a database entry that is exactly the same model as
your card; choosing one that looks similar is just a bad idea (e.g. a
GemStone Snail 64 may be as different from a GemStone Snail 64+ in terms of
hardware as can be).

Do you want to look at the card database?

Press <y> and Press <Enter>  until you come across the Display Adapter on your machine.
 

 0  2 the Max MAXColor S3 Trio64V+                    S3 Trio64V+
  1  928Movie                                          S3 928
  2  AGX (generic)                                     AGX-014/15/16
  3  ALG-5434(E)                                       CL-GD5434
  4  ASUS PCI-AV264CT                                  ATI-Mach64
  5  ASUS PCI-V264CT                                   ATI-Mach64
  6  ASUS Video Magic PCI V864                         S3 864
  7  ASUS Video Magic PCI VT64                         S3 Trio64
  8  ATI 3D Pro Turbo                                  ATI-Mach64
  9  ATI 3D Xpression                                  ATI-Mach64
 10  ATI 3D Xpression+ PC2TV                           ATI-Mach64
 11  ATI 8514 Ultra (no VGA)                           ATI-Mach8
 12  ATI All-in-Wonder                                 ATI-Mach64
 13  ATI Graphics Pro Turbo                            ATI-Mach64
 14  ATI Graphics Pro Turbo 1600                       ATI-Mach64
 15  ATI Graphics Ultra                                ATI-Mach8
 16  ATI Graphics Ultra Pro                            ATI-Mach32
 17  ATI Graphics Xpression with 68875 RAMDAC          ATI-Mach64

Enter a number to choose the corresponding card definition.
Press enter for the next page, q to continue configuration.
 

In our case, the card is not listed in this first part, so we press <Enter> for the next screen and so on.

 18  ATI Graphics Xpression with AT&T 20C408 RAMDAC    ATI-Mach64
 19  ATI Graphics Xpression with CH8398 RAMDAC         ATI-Mach64
 20  ATI Graphics Xpression with Mach64 CT (264CT)     ATI-Mach64
 21  ATI Graphics Xpression with STG1702 RAMDAC        ATI-Mach64
 22  ATI Mach64                                        ATI-Mach64
 23  ATI Mach64 3D RAGE II+, Internal RAMDAC           ATI-Mach64
 24  ATI Mach64 3D RAGE II, Internal RAMDAC            ATI-Mach64
 25  ATI Mach64 CT (264CT), Internal RAMDAC            ATI-Mach64
 26  ATI Mach64 GT (264GT), aka 3D RAGE, Internal RAMDACATI-Mach64
 27  ATI Mach64 VT (264VT), Internal RAMDAC            ATI-Mach64
 28  ATI Mach64 with AT&T 20C408 RAMDAC                ATI-Mach64
 29  ATI Mach64 with CH8398 RAMDAC                     ATI-Mach64
 30  ATI Mach64 with IBM RGB514 RAMDAC                 ATI-Mach64
 31  ATI Ultra Plus                                    ATI-Mach32
 32  ATI Video Xpression                               ATI-Mach64
 33  ATI Win Boost with AT&T 20C408 RAMDAC             ATI-Mach64
 34  ATI Win Boost with CH8398 RAMDAC                  ATI-Mach64
 35  ATI Win Boost with Mach64 CT (264CT)              ATI-Mach64

Enter a number to choose the corresponding card definition.
Press enter for the next page, q to continue configuration.

25
 

The card on our machine here is found, so we key in "25" and Press <Enter>.  Do the same for your own card with the corresponding number.
 
 

Your selected card definition:

Identifier: ATI Mach64 CT (264CT), Internal RAMDAC
Chipset:    ATI-Mach64
Server:     XF86_Mach64
Do NOT probe clocks or use any Clocks line.

Press enter to continue, or ctrl-c to abort.
 
 

Press <Enter>.
 

Now you must determine which server to run. Refer to the manpages and other
documentation. The following servers are available (they may not all be
installed on your system):

 1  The XF86_Mono server. This a monochrome server that should work on any
    VGA-compatible card, in 640x480 (more on some SVGA chipsets).
 2  The XF86_VGA16 server. This is a 16-color VGA server that should work on
    any VGA-compatible card.
 3  The XF86_SVGA server. This is a 256 color SVGA server that supports
    a number of SVGA chipsets. On some chipsets it is accelerated or
    supports higher color depths.
 4  The accelerated servers. These include XF86_S3, XF86_Mach32, XF86_Mach8,
    XF86_8514, XF86_P9000, XF86_AGX, XF86_W32, XF86_Mach64, XF86_I128 and
    XF86_S3V.

These four server types correspond to the four different "Screen" sections in
XF86Config (vga2, vga16, svga, accel).

 5  Choose the server from the card definition, XF86_Mach64.

Which one of these screen types do you intend to run by default (1-5)? 5
 

Key in "5" and press <Enter>.
 

The server to run is selected by changing the symbolic link 'X'. For example,
'rm /usr/X11R6/bin/X; ln -s /usr/X11R6/bin/XF86_SVGA /usr/X11R6/bin/X' selects
the SVGA server.

Please answer the following question with either 'y' or 'n'.
Do you want me to set the symbolic link? y
 
 

Key in "y" and press <Enter>.

Now you must give information about your video card. This will be used for
the "Device" section of your video card in XF86Config.

You must indicate how much video memory you have. It is probably a good
idea to use the same approximate amount as that detected by the server you
intend to use. If you encounter problems that are due to the used server
not supporting the amount memory you have (e.g. ATI Mach64 is limited to
1024K with the SVGA server), specify the maximum amount supported by the
server.

How much video memory do you have on your video card:

 1  256K
 2  512K
 3  1024K
 4  2048K
 5  4096K
 6  Other

Enter your choice: 4
 

In our case here, the Display Adapter has 2 MB RAM,  so we key in "4" and Press <Enter>.
 
You must now enter a few identification/description strings, namely an
identifier, a vendor name, and a model name. Just pressing enter will fill
in default names (possibly from a card definition).

Your card definition is ATI Mach64 CT (264CT), Internal RAMDAC.

The strings are free-form, spaces are allowed.
Enter an identifier for your video card definition:
You can simply press enter here if you have a generic card, or want to
describe your card with one string.
Enter the vendor name of your video card:
Enter the model (board) name of your video card:
 

Press <Enter> to all of the above.
 

The RAMDAC setting only applies to the S3, AGX, W32 servers, and some
drivers in the SVGA servers. Some RAMDAC's are auto-detected by the server.
The detection of a RAMDAC is forced by using a Ramdac "identifier" line in
the Device section. The identifiers are shown at the right of the following
table of RAMDAC types:

  1  AT&T 20C490 (S3 and AGX servers, ARK driver)                att20c490
  2  AT&T 20C498/21C498/22C498 (S3, autodetected)                att20c498
  3  AT&T 20C409/20C499 (S3, autodetected)                       att20c409
  4  AT&T 20C505 (S3)                                            att20c505
  5  BrookTree BT481 (AGX)                                       bt481
  6  BrookTree BT482 (AGX)                                       bt482
  7  BrookTree BT485/9485 (S3)                                   bt485
  8  Sierra SC15025 (S3, AGX)                                    sc15025
  9  S3 GenDAC (86C708) (autodetected)                           s3gendac
 10  S3 SDAC (86C716) (autodetected)                             s3_sdac
 11  STG-1700 (S3, autodetected)                                 stg1700
 12  STG-1703 (S3, autodetected)                                 stg1703
 

Enter a number to choose the corresponding RAMDAC.
Press enter for the next page, q to quit without selection of a RAMDAC.

q
 

In most of our encounters we have found that there is no corresponding selection.  If you are unsure, press "q".  After that, Press <Enter>.
 

A Clockchip line in the Device section forces the detection of a
programmable clock device. With a clockchip enabled, any required
clock can be programmed without requiring probing of clocks or a
Clocks line. Most cards don't have a programmable clock chip.
Choose from the following list:

 1  Chrontel 8391                                               ch8391
 2  ICD2061A and compatibles (ICS9161A, DCS2824)                icd2061a
 3  ICS2595                                                     ics2595
 4  ICS5342 (similar to SDAC, but not completely compatible)    ics5342
 5  ICS5341                                                     ics5341
 6  S3 GenDAC (86C708) and ICS5300 (autodetected)               s3gendac
 7  S3 SDAC (86C716)                                            s3_sdac
 8  STG 1703 (autodetected)                                     stg1703
 9  Sierra SC11412                                              sc11412
10  TI 3025 (autodetected)                                      ti3025
11  TI 3026 (autodetected)                                      ti3026
12  IBM RGB 51x/52x (autodetected)                              ibm_rgb5xx

Just press enter if you don't want a Clockchip setting.
What Clockchip setting do you want (1-12)?
 
 

Press <Enter>.
 

For most configurations, a Clocks line is useful since it prevents the slow
and nasty sounding clock probing at server start-up. Probed clocks are
displayed at server startup, along with other server and hardware
configuration info. You can save this information in a file by running
'X -probeonly 2>output_file'. Be warned that clock probing is inherently
imprecise; some clocks may be slightly too high (varies per run).

At this point I can run X -probeonly, and try to extract the clock information
from the output. It is recommended that you do this yourself and add a clocks
line (note that the list of clocks may be split over multiple Clocks lines) to
your Device section afterwards. Be aware that a clocks line is not
appropriate for drivers that have a fixed set of clocks and don't probe by
default (e.g. Cirrus). Also, for the P9000 server you must simply specify
clocks line that matches the modes you want to use.  For the S3 server with
a programmable clock chip you need a 'ClockChip' line and no Clocks line.

You must be root to be able to run X -probeonly now.

The card definition says to NOT probe clocks.
Do you want me to run 'X -probeonly' now? n
 

Since our card definition says NOT to probe clocks, we key in "n" and then Press <Enter>.
 

For each depth, a list of modes (resolutions) is defined. The default
resolution that the server will start-up with will be the first listed
mode that can be supported by the monitor and card.
Currently it is set to:

"640x480" "800x600" "1024x768" "1280x1024" for 8bpp
"640x480" "800x600" "1024x768" for 16bpp
"640x480" "800x600" for 24bpp
"640x480" "800x600" for 32bpp

Note that 16, 24 and 32bpp are only supported on a few configurations.
Modes that cannot be supported due to monitor or clock constraints will
be automatically skipped by the server.

 1  Change the modes for 8pp (256 colors)
 2  Change the modes for 16bpp (32K/64K colors)
 3  Change the modes for 24bpp (24-bit color, packed pixel)
 4  Change the modes for 32bpp (24-bit color)
 5  The modes are OK, continue.

Enter your choice: 1
 

First, select "1" and Press <Enter>.

Select modes from the following list:

 1  "640x400"
 2  "640x480"
 3  "800x600"
 4  "1024x768"
 5  "1280x1024"
 6  "320x200"
 7  "320x240"
 8  "400x300"
 9  "1152x864"
10  "1600x1200"
11  "1800x1400"
12  "512x384"

Please type the digits corresponding to the modes that you want to select.
For example, 432 selects "1024x768" "800x600" "640x480", with a
default mode of 1024x768.

Which modes? 432
 

Key in "432" and press <Enter>.
 

You can have a virtual screen (desktop), which is screen area that is larger
than the physical screen and which is panned by moving the mouse to the edge
of the screen. If you don't want virtual desktop at a certain resolution,
you cannot have modes listed that are larger. Each color depth can have a
differently-sized virtual screen

Please answer the following question with either 'y' or 'n'.
Do you want a virtual screen that is larger than the physical screen?n

Since we do not wish to have a virtual screen, we press "n" (otherwise press "y").  Press <Enter> and repeat the same for "2", "3" and "4".   After "4", naturally "5", but "5" will
bring you to the following screen:-

I am going to write the XF86Config file now. Make sure you don't accidently
overwrite a previously configured one.

Shall I write it to /etc/X11/XF86Config?

Key in "y" and press <Enter>.
 
There, your installation is complete and the author will probably have more than just carpal syndrome by the time he is finished with this.  To start the X-window system, simply
type

[root@localhost /]# startx

If you wish to have 16-bit color

[root@localhost /]# startx -- -bpp 16

If you wish to have 24-bit color

[root@localhost /]# startx -- -bpp 24
 

IMPORTANT:  If, when you call startx, and the display jitters and rolls, TERMINATE IMMEDIATELY by pressing <Ctrl> <Altr> <Backspace>.  Otherwise, you may end up frying your monitor in which case, Digital Systems bear NO responsibility.

To switch between resolutions, press <Ctrl><Alt><+> (numeric keypad) or <Ctrl><Alt><->.