home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 13 / 13.iso / p / p078 / 10.img / DISPLAYS.PLB / GENDRIVE.DOC < prev    next >
Encoding:
Text File  |  1989-05-15  |  7.6 KB  |  145 lines

  1. Title:  Gendrive - Description and Use              File: GENDRIVE.DOC
  2. Date:   May 5, 1989
  3.  
  4.  
  5. OVERVIEW
  6.  
  7. GENDRIVE is a utility that allows OrCAD users to modify the internals
  8. of a generic driver so that a new driver can be created that provides
  9. the proper functionality and performance for the graphics card.
  10. GENDRIVE can handle most display adapters that claim to be EGA or VGA
  11. compatible with resolutions up to 800 horizontal x 600 vertical.
  12.  
  13.  
  14. CAUTION
  15.  
  16. A GENDRIVE produced driver has limited checking for adapter compatibility.
  17. If video adapter and the new driver are not compatible, you may see either
  18. a blank screen or a screen that has random looking patterns on it that do
  19. not make sense. If you select one of the predefined driver configurations,
  20. this shouldn't happen to you, but if it does, you may need to re-boot your
  21. computer to get back to DOS by holding the Ctrl and Alt keys down and
  22. pressing the Del key.
  23.  
  24.  
  25. HOW TO USE
  26.  
  27. 1) Switch to the directory containing GENDRIVE.EXE, GENDRIVE.DAT and
  28.    GENDRIVE.DRV.  This will normally be your DRIVER directory.  If you set
  29.    up your directory structure as OrCAD recommends, this will be:
  30.        \ORCAD\DRIVER
  31.    Type:  cd \orcad\driver        and press the ENTER key.
  32.  
  33. 2) Invoke GENDRIVE.EXE
  34.    Type: gendrive                 and press the ENTER key.
  35.  
  36. 3) GENDRIVE.EXE will initialize itself and read in the OrCAD supported
  37.    set of configurations from GENDRIVE.DAT.  It will then display the
  38.    driver description part of this as a set of menu choices.
  39.  
  40.   At this point, there are 4 things you can do:
  41.      1) Type the number associated with your display adapter and press ENTER.
  42.      2) Press the M key to see More menu choices.
  43.      3) Press the Q key to Quit the GENDRIVE program. No updates will occur.
  44.      4) Press the S key to define a Special set of parameters.
  45.  
  46.   If you type a number and press ENTER, the file GENDRIVE.DRV will be modified
  47.   with the associated set of parameters. You will be asked for a new file name
  48.   for the modified driver.  After getting the name, GENDRIVE.EXE writes the
  49.   modified driver to the disk and exits.
  50.  
  51.  
  52. Title:  Gendrive - Description and Use                          Page 2
  53.  
  54.   --------------------------------------------------------------------------
  55.   In most cases, you should be able to find a menu choice that supports
  56.   your display adapter. If you do, the rest of this document can be ignored.
  57.   --------------------------------------------------------------------------
  58.  
  59.   If you press the S key, GENDRIVE.EXE will ask you to define the following
  60.   parameters:
  61.     1) The number of columns of pixels your display adapter supports.
  62.        Typical numbers here are 640, 752 and 800.
  63.     2) The number of rows of pixels your display adapter supports.
  64.        Typical numbers here are 350, 410, 480 and 600.
  65.     3) A value to be assigned to AX to set up for an Interrupt 10H.
  66.     4) A value to be assigned to BX to set up for an Interrupt 10H.
  67.        The AX and BX values must be consistent with the columns and rows
  68.        provided in 1 and 2 above.  The values for AX and BX can be gotten
  69.        from the technical reference or programmer's reference portion of
  70.        your display adapter's user manual.
  71.        Standard EGA/VGA values normally have AH=0 and AL equal either
  72.        10 (EGA 640x350) or 12 (VGA 640x480).   Hence, AX = 0010H or 0012H
  73.        for these.  Extended EGA cards often use AL=12H for 640x480 mode.
  74.        The values for sizes above 640x480 vary considerably.  In addition,
  75.        certain cards want to use a value for AH other than 0.
  76.  
  77.  
  78.   The GENDRIVE approach is designed to handle display adapters that follow
  79.   the general conventions of native mode EGA and VGA displays.
  80.     1) Display Buffer starts at address A000:0
  81.     2) There is less than 64K of addressable display memory.
  82.        Size of memory required by a display =  rows * cols / 8.
  83.        Example:  640x480 ==> 640 * 480 / 8 = 38400 bytes.
  84.        Note: 800x600 ==> 800 * 600 / 8 = 60000 bytes which is just less
  85.              than 64 kilobytes.  (1024x768 is too large.)
  86.     3) OrCAD uses 16 colors.  This implies that the Display Buffer
  87.        is really composed of 4 bit planes of 64K bytes each.
  88.     4) Pixels are stored 8 pixels per apparent byte. With the high order
  89.        bit of Byte A000:0 representing the upper left most bit on the screen.
  90.     5) The number of columns must be a multiple of 8. That is, no byte contains
  91.        bits from both the right end of a line and the left end of the next line.
  92.        (We know of no adapters that violate this rule.)
  93.     6) The mapping from bits on screen and in memory must be continuous.
  94.        For example, if byte n contains the last 8 bits on line m, then
  95.        byte (n+1) contains the first 8 bits on line (m+1).  (Various adapters
  96.        and modes violate this rule. For example, CGA and Hercules Graphics
  97.        modes.)
  98.  
  99.  
  100. Title:  Gendrive - Description and Use                          Page 3
  101.  
  102. GENDRIVE Control File: GENDRIVE.DAT
  103.  
  104.   GENDRIVE is controlled by an editable file called: GENDRIVE.DAT. You
  105.   may alter this file to make a Special (S) definition process into
  106.   menu choice.  You might do this if you have a large number of users
  107.   and a small variety of non-OrCAD-supported adapters.  If you choose
  108.   to edit the file, make sure your editor can output ASCII compatible
  109.   files containing only Carriage Return - Line Feed Sequences as line
  110.   separators.
  111.  
  112. GENDRIVE.DAT Format
  113.  
  114.   1) Any line that starts with a semicolon is a comment.  Any line that does
  115.      not start with a comment must be a mode specification.
  116.   2) A mode specification consists of 5 fields separated by commas:
  117.      Driver Description, Columns, Rows, AX value, BX value.
  118.      - Driver Description: text that will display during application
  119.        initialization.  Normally contains Columns x Rows and display adapter
  120.        description.   This field can be enclosed in either single or double
  121.        quotes.  If the field contains an embedded comma, then it must be
  122.        enclosed in quotes.  If the field contains an embedded comma and a
  123.        single/double quote, use double/single quotes to enclose it.
  124.        Example Driver Descriptions:
  125.           EGA 640x350 16 color                       no quotes
  126.           "EGA 640x350 16 color"                     optional quotes
  127.           'EGA 640x350 16 color'                     optional quotes
  128.           "EGA 640x350, 16 color"                    required quotes (,)
  129.           "John's Favorite Display Card"             optional double quotes
  130.           John's Favorite Display Card               enclosing quote not needed
  131.      - Columns: the number of columns of pixels the display will support.
  132.          Enter this number in decimal. Example values are: 640, 752 and 800.
  133.      - Rows: the number of rows of pixels that the display will support.
  134.          Enter this number in decimal. Example values are: 350, 480 and 600.
  135.      - AX value: The value to be MOVed into AX before doing an INT 10H to
  136.          initialize the card. Enter this number in hexadecimal. (Hexadecimal
  137.          is used here because most manuals show the numbers in hex.)
  138.          Example values are: 0010H (EGA 640x350) and 0012H (VGA 640x480)
  139.      - BX value: The value to be MOVed into BX before doing an INT 10H to
  140.          initialize the card. Enter this number in hexadecimal. (Hexadecimal
  141.          is used here because most manuals show the numbers in hex.)
  142.          Example values are: 0H (most cards/modes) or 0010H or 0012H. The
  143.          latter two values cause 640x350 and 640x480 modes for some extended
  144.          EGA cards.
  145.