Issue #26: Hardware,  Library

Peter Norton

Some successful computer books have earned memorable nicknames. There is the “K&R” book, the “Gang of Four” book, and, to please generations of board and role game players, there are also the “Wizard Book“, the “Dragon Book“, and the “Dinosaur Book“. There’s the “Camel” book and the “Pickaxe” book. And then, with a decidedly more corporate look and feel, let us talk today about the “Pink Shirt” book, officially titled “The Peter Norton Programmer’s Guide to the IBM PC.” More corporate, yes, because the PC was after all a business machine coming from a business corporation.

As a reference for our younger readers, many of which might be reading this publication on an IBM PC (nowadays more commonly referred to as Windows PCs,) it is important to mention one historic fact. This very Mr. Peter Norton, the one appearing in the cover of the book, is the same that gave his name to famed products such as Norton Antivirus, Norton Commander (which begat a popular heir,) Norton Utilities (the most ground-breaking of which was undoubedly UNERASE), culminating with the Norton 360 suite available at the time of this writing.

The Norton name played a double role in the PC industry of the 1980s: on one side, representing the aforementioned products, which helped millions of IBM PC users in recovering deleted files and preventing virus infections. On the other side, the pre-Twitch, pre-YouTubber, pre-blogger, pre-web influencer, pre-Guy Kawasaki evangelist. The role that nowadays Scott Hanselman, Kelsey Hightower and John Sundell play for .NET, Kubernetes, and Swift, respectively.

Joel Spolsky mentioned the Pink Shirt book (twice, actually) as one of the major references that shaped his career.


Why, among the huge numbers of different architectures and standards in the market, did the IBM PC, built around the x86 CPU, became synonym with desktop computing? As explained by Norm DeWitt during his guest appearance in the March 19th, 1985 episode of The Computer Chronicles, by 1984 IBM had captured 26% of the worldwide PC market.

(By the way, that video includes a demo of IBM TopView, a series of unfortunate predictions by Mr. DeWitt, a discussion about Digital Research’s Concurrent DOS by Gary Kildall himself, and a fascinating discussion of the relationship between IBM and other smaller partners in the industry. Totally worth a watch. But I digress.)

Emerson W. Pugh, in his excellent book “Building IBM” (MIT Press, 1995) dedicates the last few words of the last chapter to this new machine, born in the Boca Raton, Florida IBU (Independent Business Unit).

To achieve broad market acceptance, for example, the PC was to have an open rather than proprietary architecture. To reduce development time and costs, the operating system was to be purchased from an independent software firm, and hardware components were to be open for competitive bids from inside and outside the company. (…)
Spurred on by a brilliant advertising campaign that featured Charlie Chaplin’s little tramp, sales of the PC soared beyond all expectations.

The introduction of the IBM PC was the defining moment of a whole market. Software vendors such as Microsoft, Software Arts, and Digital Research were all invited to provide software for this new machine. Byte Magazine started its January 1982 issue with a glowing statement:

What microcomputer has color graphics like the Apple II, an 80-column display like the TRS-80 Model II, a redefinable character set like the Atari 800, a 16-bit microprocessor like the Texas Instruments TI 99/4, an expanded memory space like the Apple III, a full-function uppercase and lowercase keyboard like the TRS-80 Model III, and BASIC color graphics like the TRS-80 Color Computer? Answer: the IBM Personal Computer, which is a synthesis of the best the microcomputer industry has offered to date.

Of course, not everybody was as enthusiastic at first. Dr. Dobb’s Journal first mentions the IBM PC in a small note in page 45 of its October 1981 edition, in a rather laconic fashion:

Late News From IBM: On August 12th, IBM announced the IBM Personal Computer, a small home machine. It will be sold, IBM announced, through Computerland stores and Sears Business Machines outlets. The machine consists of a console with keyboard, a separate video monitor (which may be a home TV), and cassette and disk units. It uses 5-inch disks (…)

The Pink Shirt book covers subjects applicable to the five kinds of IBM PCs available in 1985: The 5150 PC, the 5160 XT, the 5170 AT, the 5155 Portable, and what was arguably the first major flop in the PC industry, the IBM PCjr.

To give an idea of the type of hardware we are talking about: all of these machines used the Intel 8088 CPU, except for the AT, which used the 80286. None included the 8087 / 80287 “arithmetic coprocessor” (sold separately!) for which the PCjr did not even have a dedicated slot in the motherboard! Let us be clear: the Intel 8088 could only perform integer math, and floating-point operations were executed in software. Gaming on a PC was not going to be a thing until almost a decade later. This is the world this book was born into.

GPUs were not even a science fiction thing back then.


In many ways, the Pink Shirt book is akin to “The Linux Programming Interface” by Michael Kerrisk. Of course, instead of Linux syscalls, you get lists of DOS interrupts. But the idea is the same; to be able to write efficient, fast software for this new kind of computer, using the lowest possible interface available in the original PC. (Ironically enough, there is a 1999 book co-written by Peter Norton about Linux, but we will leave it for a future edition of this magazine.)

Take, for example, the list of DOS interrupts detailed in chapter 16, called “Universal DOS Functions”; there one finds all that is needed to read and write files, command I/O from the keyboard and to peripherals. The book is sprinkled with bits and pieces of the design philosophy used in the creation of the IBM PC, most of them turning around a central theme:

The basic philosophy of the PC family is: Let the BIOS do it; don’t mess with direct control.

Mr. Norton will stress this notion several times across his text: to build durable, compatible software across all IBM PC clones, always use interrupts, follow IBM’s advice, and do not circumvent this rule.

The Pink Shirt book is aimed at practicioners; its pages are filled with practical bits and pieces of information, from insider tips and tricks, to actual code snippets. Suffice to mention the “actual production code” taken from the Norton Utilities, shown in page 292, aimed at the calculation of weekdays. Or the section about “Terminate-but-Stay-Resident” (interrupt 39) in page 252, allowing a severely crippled DOS architecture to provide users with an experience similar to that of a multitasking system. Or Appendix B, providing a timeless explanation of hexadecimal arithmetic.

Coupled with its deep detail, there is a honest, down-to-earth tone throughout the book. Mr. Norton is not shy of literally saying “I don’t know” when the time comes; for example in page 37, when explaining how a small snippet of BASIC code can… completly lock up a PCjr. A good example of what I called “honestization” in a previous edition of this magazine.

Last but not least, the Pink Shirt book included two chapters (19 and 20) dedicated to the creation of programs, using the five most important programming languages available at this point in time: assembly language, interpreted BASIC, compiled BASIC, Pascal, and of course C. A delightful reading for anyone curious about programming languages history.


Why is the Pink Shirt book still relevant, almost 40 years later? I will let Raymond Chen answer this question with a quote from his classic book “The Old New Thing” (Addison-Wesley, 2007)

Every company has its own collection of line-of-business (LOB) applications. These are programs that the company uses for its day-to-day business, programs the company simply cannot live without. (…)
If a Windows upgrade breaks a LOB application, it’s game over. No upgrade. (…)
And it happens that a lot of these LOB applications are 16-bit programs. Some are DOS.

This book comes from a time when computers filled entire desks, weighted tens of kilos, had noisy fans, and only a few had mice attached to them. Mr. Norton’s thoughts around portability and architecture are still valid and stand the test of time.

And most surprisingly, most of the assembly code snippets will still work on any standard Windows PC, in a show of perenniality that is very rare in our industry. Now go, grab that old Pentium PC in your garage, install FreeDOS on it, and write some apps.

Cover photo by the author.

Adrian Kosmaczewski is a software consultant and evangelist. He is a published writer, trainer and speaker. He holds a Master's degree from the University of Liverpool.