VGA vs MDA/CGA/EGA I/O compatibility?

How compatible is the VGA with the older cards, when looking at I/O ports (Looking at the different registers not specified in the FreeVGA information)? Are they actually emulated, or are they undefined?
What do you mean?

Older VGA cards? They all had to perform the basic VGA functionality. Older cards weren't necessarily as robust as newer ones -- misprogramming them could actually damage them.

EGA only fits compatibility up to the EGA modes of the VGA. Otherwise they could be programmed the same.

CGA only fits compatibility up to the CGA modes of the VGA, qualified with a 'just barely.' Use the BIOS to change video mode, etc. I don't remember much about CGA. (I basically ignored it as worthless.)

MDA cards are not compatible with a VGA. The only thing that is 'compatible' about them are the video memory layout in the proper text modes.

IIRC.
I mean that, when running older software of EGA/CGA/MDA card on a VGA card, how much would actually work? Afaik the basic indexed registers (CRTC registers, Attribute Controller registers, Sequencer registers) would still work, because of the matching I/O ports and register indexes. But is the VGA still compatible with the older I/O ports of the older chips?

Also how is the VGA's compatibility with the Moterola 6845? I currently have the default VGA ports (explained in the FreeVGA documents) implemented. I also have the redirect ports (3B0-3B3, 3D0-3D3, 3B6-3B7, 3D6-3D7) aliased to the VGA's 3B4-3B5 and 3D4-3D5. Also currently implemented 3C3 with bits 1-7 saved and bit 0 redirected to the Misc Output Register RAM Enable bit.

What about the different older registers? Ports 3B8-3BB and 3CD, 3D8-3D9, 3DB-3DC and 3DF. I don't see them defined in the FreeVGA Project. How are these mapped to the VGA registers? Are they used at all? Will the ports actually exist on a real IBM VGA? And when used and supported, how are they actually processed when the VGA is rendering? What is affected when the registers are written to?
Last edited on
The older software, if it is supposed to work for an CGA, EGA, or MDA-text mode, should work just fine. You'd have to find some to test it on your emulator to make sure.

Presence or absence of the Motorola 6845 cannot be guaranteed -- user software should not be messing with it anyway. If part of your project is to handle attempts to mess with it, then I'd leave it at a "ignore unless user software attempts to write to it." Unless you have some must work software that dinks with it, it really isn't worth your time to emulate it.

All the ports/registers you listed are non-standard. Different SVGA chip manufacturers employed them differently, so unless you are emulating a specific, known subset of cards (as in, you have to ask your user what card he wishes you to emulate: Chips&Tech, Trident, Tseng Labs, etc plus model number) then there is no reason to support writes or reads from them.

Hope this helps.
Topic archived. No new replies allowed.