Get the latest tech news

The VGA Attribute Controller Is Weird


few days ago I finally swatted a VGA emulation bug that I had known about for several years, but couldn’t identify until recently. The problem affected only Windows 3.1 running in Standard mode.

The attribute controller flip-flop mechanism lent itself to using the REP OUTSB instruction directed to port 3C0h to quickly write a set of index/data pairs. For example the 1996 Cirrus Logic CL-GD5446 Technical Reference Manual, usually a reliable source of information, documents the attribute controller registers as follows. The VGA emulation fix was trivial, making reads from 3C0h always return the current index register value, regardless of the flip-flop state.

Get the Android app

Or read this on Hacker News