• Please review our updated Terms and Rules here

True CGA vs VGA card in CGA mode

Fallo

Experienced Member
Joined
Jan 2, 2009
Messages
432
"Glassy"?

Well, maybe not the best choice of words, but you know what I mean.

I once read a review of the PC version of Archon which said (among other things) that it had jerky animation compared to the C64 and Amiga versions. The guy that wrote the review in all probability never played it on a real CGA card.
 
Last edited:

Trixter

Veteran Member
Joined
Aug 31, 2006
Messages
7,259
Location
Chicagoland, Illinois, USA
Well, maybe not the best choice of words, but you know what I mean.

Actually, I don't know what you mean, which is why I asked :) What do you mean by "glassy"? Do you mean that the motion is very smooth without any jerky movement or jumps?


I once read a review of the PC version of Archon which said (among other things) that it had jerky animation compared to the C64 and Amiga versions. The guy that wrote the review in all probability never played it on a real CGA card.

No, he's right, it is jerky.

The smoothness of any game has to do with how well it is programmed. I've seen smooth 60Hz animation on a CGA card (ie. great) and I've seen juddery animation on EGA (ie. terrible) so it all depends on how good the programmer was.

Working on the hardest part tonight of the CGA tester -- M6845 register tests. I will include an interlaced test :) Hopefully I will have it ready tonight or tomorrow night.
 

Fallo

Experienced Member
Joined
Jan 2, 2009
Messages
432
Actually, I don't know what you mean, which is why I asked :) What do you mean by "glassy"? Do you mean that the motion is very smooth without any jerky movement or jumps?

Yes, that's it.

No, he's right, it is jerky.

The smoothness of any game has to do with how well it is programmed. I've seen smooth 60Hz animation on a CGA card (ie. great) and I've seen juddery animation on EGA (ie. terrible) so it all depends on how good the programmer was.

If you ask me, the reviewer was exaggerating. Archon is one of the better games I've seen for smoothness of animation, if not as good as the C64 and Amiga versions (keeping in mind that those both had hardware sprites).
 

per

Veteran Member
Joined
Jan 21, 2008
Messages
3,006
Location
Western Norway
(sorry if I get a little off-topic here)
While we're on the topic of jerky animations, I would like to make a comment about Microsoft Flight-Simulator 4.

It seems like it runs jerked on very slow systems.
at higher processor speeds, the animations smooths out (almost compleetely at about 25-50MHz).
However, if the processor speed is too high (say somewhere above 500MHz), the game slows awfully down.

I guess this has something to do with how the timing routines in the simulator are programmed.
 

Fallo

Experienced Member
Joined
Jan 2, 2009
Messages
432
(sorry if I get a little off-topic here)
While we're on the topic of jerky animations, I would like to make a comment about Microsoft Flight-Simulator 4.

It seems like it runs jerked on very slow systems.

at higher processor speeds, the animations smooths out (almost compleetely at about 25-50MHz).
However, if the processor speed is too high (say somewhere above 500MHz), the game slows awfully down.

I guess this has something to do with how the timing routines in the simulator are programmed.

How about California Raisins? The PC version of this game displays a startup message saying "Adjusting for CPU speed...". What's cute is that if the system is faster than about 16 Mhz, it then displays a message saying "Wow, that's some computer you have there!". I guess in 1987, the fastest PC available was a 16 Mhz 386. Because of the timing routine CR uses, it actually runs slower at speeds above 16 Mhz than it does at 4.77 Mhz.
 

Trixter

Veteran Member
Joined
Aug 31, 2006
Messages
7,259
Location
Chicagoland, Illinois, USA
New version ready for testing:

http://www.oldskool.org/pc/cgacomp/

I would appreciate some test/bug reports :) especially for the video card detection since I put a lot of time into it (I grabbed VGA stuff from a library, but the cga/mda/hercules/+/incolor/ega code is mind).

If I get a few favorable test reports, I will make a final version and more importantly a reference video so that people can see what a 100% IBM CGA does in response to the tester.
 

vwestlife

Veteran Member
Joined
May 2, 2008
Messages
5,174
Location
central NJ
New version ready for testing:
Drat! It says "Numeric co-processor required." :( Neither of my two Tandys (original 1000 and 1000RL), which are really my ideal CGA machines, even have an 8087 socket at all, while my CompuAdd 810 and Zenith SupersPORT both have the socket but no chip. I think my IBM PC has an 8087 installed, but it's currently awaiting blown capacitor replacements on both the motherboard and the original IBM CGA board. :eek: Oh well...

I tried it on my Compaq PIII with modern-era onboard Super VGA video, and it failed most of the tests miserably. Even things that I know VGA is capable of doing, such as border colors and high-intensity background colors, didn't work. I guess the registers just don't match up with CGA.
 

per

Veteran Member
Joined
Jan 21, 2008
Messages
3,006
Location
Western Norway
Here is the test results from my XT using an ATI "Small Wonder" Graphics Solution Version 2 hooked up to an IBM 5151 monitor emulating CGA:

  • Video RAM Read: 303 Kb/s
  • Video RAM Write: 304 Kb/s
  • Video RAM Interl. OpCode Read: 179 Kb/s
  • Video RAM Interl. OpCode Write: 184 Kb/s
----------
  • Overscan: Failed, no overscan
  • Med.Res. Background: Ok
  • Hi.Res. Foreground: Ok
  • Med.Res. Graphics Palettes: Ok*

*(not really easy to spot any differences due to output converted to shades of green)
----------
  • 40 Columns textmode: Ok
  • Textmode Hi-Color Backgrounds: Ok
  • Textmode Cursors: Failed, no change at all
  • CGA Snow: Failed, nice and clear black area
  • Textmode 8*8 font: Not 100% similar, but difficult to spot any differences
----------
Calibration works just fine
----------
  • Vertical retrace: 49,19 Hz (due outputing to an IBM 5151)
  • Horizontal retrace: Ok
  • Textmode Row reprogramming: Ok
  • Textmode Row/Column reprogramming: First screen Ok, but failed on second screen, some of the picture appear ghostish and inverted behind the main picture (I guess I should not try that test again)
  • Interlached text: Unsure, the text appear as BIG letters filling the screen below normal letters.
  • Dipslay positioning: Didn't see that one :crazy: , and therefore not tested
----------
Hardware detection [actual facts]:
  • Machine type: Unknown [IBM PC/XT]
  • CPU: Intel 80C88 [8088]
  • CPU Speed: 5 MHz [~4.77 MHz]
  • Video Adapter: CGA [MGA/CGA Clone]
  • BIOS: 1501512 Corp. IBM 1981 (11/08/82, Rev. 244) [First rev. IBM 5160 PC/XT BIOS]
 

Trixter

Veteran Member
Joined
Aug 31, 2006
Messages
7,259
Location
Chicagoland, Illinois, USA
Drat! It says "Numeric co-processor required."

Dammit! I knew I forgot something! I'll try to get a new version uploaded that doesn't require one.


I tried it on my Compaq PIII with modern-era onboard Super VGA video, and it failed most of the tests miserably. Even things that I know VGA is capable of doing, such as border colors and high-intensity background colors, didn't work. I guess the registers just don't match up with CGA.

They don't match up at all (the same regs are used for completely different functions). So the moniker "CGA compatibility tool" is accurate :)
 

Trixter

Veteran Member
Joined
Aug 31, 2006
Messages
7,259
Location
Chicagoland, Illinois, USA
Here is the test results from my XT using an ATI "Small Wonder" Graphics Solution Version 2 hooked up to an IBM 5151 monitor emulating CGA:

This is fascinating, especially since it detected as CGA. Some things are clearly wrong (50Hz output, because of the monitor), some things are better than real CGA (memory speeds), and others are enhanced/fixed (no snow).

The fact that it detects as CGA but has a 50Hz refresh rate might cause a handful of games (California Games, Super Zaxxon, others) that used tricks to not work.

Textmode Row/Column reprogramming: First screen Ok, but failed on second screen, some of the picture appear ghostish and inverted behind the main picture (I guess I should not try that test again)

Correct, do NOT do that test again. That's the most "dangerous" test in the suite, although it doesn't hurt my 5153. That test was designed for RGB monitors, not monochrome -- I might put an additional warning in there.

Working on a version that doesn't use a mathco, should be uploaded in less than an hour.
 

Trixter

Veteran Member
Joined
Aug 31, 2006
Messages
7,259
Location
Chicagoland, Illinois, USA
If this is true, then I cannot use the tool either. My XT has no co-processor..

Okay, I've fixed this. It should work on systems without a mathco now. You can get version 0.3 from http://www.oldskool.org/pc/cgacomp/ . Test away! :)

I just realized I forgot to implement one of the tests: The start address register. I will add that to version 0.4 in a few days as I'm currently sick with a bronchial infection. Once that's done, and I'm not coughing up a lung, I'll make a video of it in action and then post the final version along with the source code.
 

per

Veteran Member
Joined
Jan 21, 2008
Messages
3,006
Location
Western Norway
This is fascinating, especially since it detected as CGA. Some things are clearly wrong (50Hz output, because of the monitor), some things are better than real CGA (memory speeds), and others are enhanced/fixed (no snow).

The fact that it detects as CGA but has a 50Hz refresh rate might cause a handful of games (California Games, Super Zaxxon, others) that used tricks to not work.
I think that the stuff that's incompatible is because of it's set to emulate CGA for a 5151, and because of that, using the MDA font and the fixed MDA refresh-rates.

It might be more CGA compatible (like supporting stuff like overscan and reprogrammable Row/Column stuff) if it is set to emulate CGA for a 5153.
Correct, do NOT do that test again. That's the most "dangerous" test in the suite, although it doesn't hurt my 5153. That test was designed for RGB monitors, not monochrome -- I might put an additional warning in there.

Working on a version that doesn't use a mathco, should be uploaded in less than an hour.
The monitor still works ;) , but I know that it takes about nothing to fry a monitor.

However, the card actually does support reprogrammable Row/Column stuff in text-mode, but they are activated another way than the CGA ones are activated.



Anyways, my 8087 does at least work, but why does it report my 8088 as an 80C88?
 

Trixter

Veteran Member
Joined
Aug 31, 2006
Messages
7,259
Location
Chicagoland, Illinois, USA
It might be more CGA compatible (like supporting stuff like overscan and reprogrammable Row/Column stuff) if it is set to emulate CGA for a 5153.

Indeed, it should be perfect.

The monitor still works ;) , but I know that it takes about nothing to fry a monitor.

What usually fries a monochrome monitor is trying to drive it faster than it is meant to be driven. I don't drive it faster, I just try to display more in the visible area. So although the test gives you a scare, it is still somewhat safe.

Anyways, my 8087 does at least work, but why does it report my 8088 as an 80C88?

Because it is an 80C88, the later 8088 with the CMOS static design. More info here: http://en.wikipedia.org/wiki/Intel_8088

The code in particular checks for a true 8088 by seeing if it suffers from the rep es: lodsb bug. If it doesn't have the bug, then it is either an NEC V20 or an 80c88 where they fixed it. I then differentiate between the NEC and the 80c88 by trying to do an undocumented instruction (AAD with an operand of 16 instead of 10) and if it fails, it's an nec; if succeeds, it's an 80c88. I then further check to see if it's an 80x88 vs. 80x86 by measuring the size of the prefetch queue via self-modifying code.

If you open up your machine and your CPU does NOT say 80c88 on the top of it, I would like to know, as I was very proud of that piece of code and expect it to work properly.
 

vwestlife

Veteran Member
Joined
May 2, 2008
Messages
5,174
Location
central NJ
Okay, NOW I've fixed this. I use some mathco tricks in the detection code, so for systems without an 8087 I linked in an 8087 emulator. It should work on systems without a mathco now. Version 0.4 is at http://www.oldskool.org/pc/cgacomp/ . *Now* test away :)
Now it works! :) My Tandy 1000RL passed all the tests with flying colors, except for interlaced mode, which it seems to ignore entirely. With some adjustment of my CM-11's controls, I was even able to get the full 90x30 text mode visible on the screen.

One peculiarity is that Tandy modified the text mode font on quite a few characters, versus IBM's CGA font. For example, Tandy displays the capital letter O as more squared-off and the number 0 as more rounded with a dot in the middle, while IBM's font displays capital O as more rounded and number 0 as more blocky with a slash through it. Nonetheless, this doesn't seem to cause any problems with any programs I've ever used, and even the fact that Tandy extends the CGA text mode to 225 lines of resolution -- adding an extra blank line between each row of text for better readability, so the bottom of a "g" won't touch the top of a "T" in the row below it, for example -- doesn't seem to cause any problems, either.

One small gripe: in the disclaimer, "any damage that may occur during it's use" should read "...during its use." Just like "his," "hers," "yours," and "ours," the possessive "its" does not use an apostrophe. ;)
 

JohnElliott

Veteran Member
Joined
Sep 1, 2006
Messages
587
Location
Sussex, UK
I tried it on the two XTs I happen to have set up at the moment: an IBM 3270 PC and a Compaq Deskpro. On the Compaq I did the tests twice, once with the monitor set for hi-res text mode and once with it set for standard CGA-resolution text mode.

3270 PC:
  • Read: 341 Kb/s
  • Write: 403 Kb/s
  • Interleaved read: 206 Kb/s
  • Interleaved write: 214 Kb/s
Numerous weirdnesses in the other tests, of course, since it has no 40-column mode, only 8 colours, selecting the red/cyan/white palette clears video RAM, and so on. And one test (I think it was the snow test) appeared to lock up completely.

Compaq (hi-res mode):
  • Read: 394 Kb/s
  • Write: 443 Kb/s
  • Interleaved read: 248 Kb/s
  • Interleaved write: 278 Kb/s
Nearly all tests in this mode passed, though the cursor shapes were a bit odd because characters are 14 lines high not 8. Interlacing, overscan, 90x30 and so on were fine, though of course the refresh rate was ~50Hz not ~60Hz. Colours were, of course, all green.

Compaq (lo-res mode):
  • Read: 379 Kb/s
  • Write: 417 Kb/s
  • Interleaved read: 242 Kb/s
  • Interleaved write: 280 Kb/s
Colours, again, were all green.
 

vwestlife

Veteran Member
Joined
May 2, 2008
Messages
5,174
Location
central NJ
One curious glitch with v0.4: although it runs fine on my old Tandy (8086 without coprocessor), on my Compaq PIII-600 it crashes with "Runtime error 200 at 04C7:0091", while v0.3 worked fine on it. :confused: Not much of a loss, though, since modern-era Super VGA fails most of the tests miserably, anyway. :p
 
Top