Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

If I recall correctly you could run CGA and Hercules and the same time as they used different memory areas.

There were even a few debuggers that used this into the VGA era - program would be on the color monitor and your debugger on the black and white (actually usually orange or green).



Yes, originally CGA and MDA at the same time. Hercules was a non-IBM standard, based on MDA. Hercules has 64k of memory, where 32k is in the area of MDA, and the second 32k overlaps with the CGA area. You could disable the second 32k when you had a CGA card in your system. EGA and VGA were also made backwards compatible, and could co-exist with an MDA or Hercules card.

The demo Stars by NoooN (https://www.pouet.net/prod.php?which=301) has an easter egg for a combination of VGA and MDA/Hercules: on the monochrome screen, a Snake game appears, which can be played via keyboard while the demo is running.


I did actually use this debugging technique while making a couple of the effects of Area 5150 (the lake effect at the end, and the one two effects before that).


This is correct. The Borland debugger supported this, it was the only real way to debug a "graphics mode" program back in the day.


I used to run a dual head VGA/mono debugging setup back in the day. I used this to great effect cracking one of the Mechwarrior games for myself.


I remember cracking Mech Warrior (2?) via flipping a bit on the executable (and changing the drive letter of a path somewhere), it was so amazing when it just worked!


Oh wow, I'd forgotten all about that! It felt like science fiction when I got that working.


I actually find it quite impressive what kind of things the IBM engineers thought of right from the start, given it was their very first PC ever.

Design a text and a graphics card, make them have different base addresses so you can have dual monitor. Or allow having an option ROM at a specific address that can hook into the boot process of the BIOS, adding additional boot sources, eg network boot (whatever you can cram into 32k).


It was also VGA and beyond -- and Hercules at the same time. And almost every debugger, including Microsoft CodeView, supported this mode. Most developers back in the late 80s and early 90s had a mono monitor on their PC, even into the Windows 3.1 and early Windows 95 days.


Was useful for CAD as well, commands on mono text, visualization on color graphics (although, often black and white there for aesthetics)


And because less color meant more resolution in the same amount of video RAM. If you were happy with monochrome CAD (no gray tones), you got 8 pixel in a single byte!


IIRC VGA was at a000h and text at b800h.


And monochrome at b000h.


Does anyone know why cards did not map video memory into the C000-C800 or the D000-E000 segments? Did many machines have an option ROM or expanded memory there?


1992 Cirrus Logic GD5402/AVGA2 (ISA Bus) allowed you to enable special 128KB linear window directly mapping A0000-Bffff to VGA memory. Only ISA VGA chip fully supporting linear framebuffer access was ATI Mach64. Since ISA bus is limited to 16MB address space you had a choice of either no more than 12MB of ram, or finding a motherboard supporting "Memory Hole At 15M-16M" Bios option. VLB and PCI graphic cards mostly didnt have this problem (some mapped itself at 64MB assuming nobody would be crazy enough to cram that much ram into a computer in 1993). It popped once again at the end of AGP life/start of PCIE when we ran out of 32bit memory, this is why fitting 4GB of ram often resulted in 3.5GB usable at most.

Of course this problem is with us even today. PCIE Resizable BAR is a brand spanking new feature, first proposed in 2008, enabling expanding directly mapped buffer from previous limit of 256MB to full capacity of VRAM. AMD tried to repackage it under different name (Smart Access Memory) and upsell as exclusive to only highend brand new parts, Intel new lol GPUs require it to work reasonably fast, but lock out support on non Intel platforms.


Part of that was used for option ROMs like hard drive controllers, the EGA/VGA BIOS, network adapters, and for EMS; other areas were just marked by IBM as "reserved", which might have scared people off. In early machines there probably wasn't much of anything there, but then video memory needs were still modest enough that A000-BFFF sufficed.

Probably a good thing, because then those 'holes' could be used for UMBs...


The C000 segment was used for the EGA/VGA extension ROM. I'm guessing that using D000-EFFF would be unnecessary (because of the planar addressing squeezing 256kB of video memory into a 64kB address space), inconvenient (because the addresses wouldn't be contiguous - EGA and VGA were designed to coexist with either CGA or monochrome adapters in B000-BFFF) and (for VGA) insufficient - you'd still not have enough to map the entire 256kB of VRAM linearly. I also expect that IBM's engineers didn't want to take up all the extension ROM space because then it wouldn't be possible to add EMS cards, network cards, and whatever else ended up being mapped there. Though 192kB of write-only video memory in that space would be an interesting design!


A lot of early hard disc controllers used segment C800 for BIOS extensions. Other adaptors could map into the Dxxx and Exxx ranges.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: