DDDR/2 - 8514/A Display Driver
By IBM
Reprint Courtesy of International Business Machines Corporation, © International Business Machines Corporation
8514/A Display Driver
The IBM 8514/A display driver shares its basic functionality with the 16- bit VGA display driver. See 16-Bit VGA Display Driver for details about privilege levels, graphics engine interface, graphics engine functions, dispatch tables, and debugging. For the most part, these topics, as covered in that chapter, apply also to the 8514/A display driver.
Overview
This chapter covers the differences between the 16-bit VGA display driver and the 8514/A display driver, followed by 8514/A device-specific programming information.
Operating Modes
The 8514/A graphics adapter operates in the following modes:
- Video-graphics array (VGA)
This is the power-on mode; the functionality of the 16-bit VGA display driver is available.
- Advanced-function
This mode provides a programming interface for the adapter. The primary advantage of the 8514/A display driver over the 16-bit VGA display driver is that the advanced-mode adapter interface handles much of the hardware programming for you. Instead of programming directly into the bit-plane memory, the adapter provides an interface supporting most of the required display functions.
Both modes of operation are selectable under program control.
Macros for Utilizing Available Hardware Capabilities
The 8514/A display driver includes a set of macros to access the adapter interface. When called by the driver, through the entry points, the interface provides a set of functions to utilize the hardware capabilities of the display adapter. Each of the macros is addressed in detail in the sections that follow.
|
Tests an I/O port for a particular value, as follows:
Port | The port number to be polled. If not present, it is assumed that the port number is already loaded into the DX register. |
Sense | The sense of jump needed to remain in the polling loop. |
Mask | If present, the value that will be ANDed with the polled contents of Port. |
EquVal | If present, the value that must match the Portcontents, after masking (if Maskis present). |
SaveRegs | This parameter is present if registers used in polling are to be saved and restored. The actual content of this parameter is ignored; only its presence matters. |
WaitIO macro | Port,Sense,Mask,EquVal,SaveRegs |
|
Waits for the 8514/A graphics adapter output queue to contain available data.
SaveRegs | This parameter is present if registers used in polling are to be saved and restored. The actual content of this parameter is ignored; only its presence matters. |
WaitQIN macro | SaveRegs |
|
Waits for the 8514/A graphics adapter input queue to be ready to accept data.
SaveRegs | This parameter is present if registers used in polling are to be saved and restored. The actual content of this parameter is ignored; only its presence matters. |
WaitQOUT macro | SaveRegs |
|
Check for the underrun or overrun state after execution of a variable data command to the 8514/A graphics adapter.
SaveRegs | This parameter is present if registers used in polling are to be saved and restored. The actual content of this parameter is ignored; only its presence matters. |
ChkERRSTATUS macro | SaveRegs |
|
Waits for the 8514/A adapter input queue to have a minimum number of words of free space. The queue may contain up to eight words. The number of words still to be dequeued can be ascertained at any time.
MinQSpace | If at least this many words are available in the queue, fall out of wait loop. This parameter must be present. |
SaveRegs | This parameter is present if registers used in polling are to be saved and restored. The actual content of this parameter is ignored; only its presence matters. |
WaitQ macro | MinQSpace,SaveRegs |
|
Outputs a word value to the 8514/A input queue.
Port | The port number for which written data will be queued. If this parameter is not present, it will be assumed that the port number is already loaded into the DX register. |
Data | The immediate or indirect specification of data that will be output to Port. If this parameter is not present, it will be assumed that the data is already loaded into the AX register. |
SaveRegs | This parameter is present if registers used in polling are to be saved and restored. The actual content of this parameter is ignored; only its presence matters. |
outwQ macro | Port,Data,SaveRegs |
|
Outputs a byte value to the 8514/A input queue. This macro differs from outwQin that it is assumed that only the low half of the AX register needs to be loaded. A slight saving in code size is achieved thereby.
Port | A port number for which written data will be queued. If this parameter is not present, it will be assumed that the port number is already loaded into the DX register. |
Data | An immediate or indirect specification of data that will be output to Port. If this parameter is not present, it will be assumed that the data is already loaded into the AX register. |
SaveRegs | This parameter is present if registers used in polling are to be saved and restored. The actual content of this parameter is ignored; only its presence matters. |
outbQ macro | Port,Data,SaveRegs |
Bit-Plane Model
The bit-plane memory in the adapter is arranged in planes of 1024 x 1024 bits. The displayed data is taken from the low 1024 x 768 or 640 x 480 bits . The undisplayed bit-plane memory is used by the adapter as auxiliary storage for functions, like area-fill working storage, as a cache for programmable character sets and marker drawing.
The number of planes available depends on the adapter mode and the amount of video RAM installed, up to a maximum of 32 planes. They are numbered from 0 to 31, with plane 0 associated with bit 0 of the color index. The 8514 display driver provides the following memory mapping for high- resolution mode:
+--------------------------------------------------------+ | | | | | onscreen area | | | | | | (32x32) 64 128 196 | | (40x40) 80 160 240 | | (64x64) 128 256 | 768 |--------------------------------------------------------| | ptr | ptr | ptr | ptr | work | | | and | xor | save | color | area | SaveScreenBits | | mask | mask | area | bitmp | | area | 848 |--------------------------------------------------------| | Pattern Cache | 864 |--------------------------------------------------------| | | | | | Font storage area and 3-op BLT temporary space | | | | | 1023 +--------------------------------------------------------+