Hubbry Logo
CP/MCP/MMain
Open search
CP/M
Community hub
CP/M
logo
8 pages, 0 posts
0 subscribers
Be the first to start a discussion here.
Be the first to start a discussion here.
CP/M
CP/M
from Wikipedia

CP/M
A screenshot of CP/M-86
DeveloperDigital Research, Inc., Gary Kildall
Written inPL/M, Assembly language
Working stateHistorical
Source modelOriginally closed source, now open source[1]
Initial release1974; 51 years ago (1974)
Latest release3.1 / 1983; 42 years ago (1983)[2]
Available inEnglish
Update methodRe-installation
Package managerNone
Supported platformsIntel 8080, Intel 8085, Zilog Z80, Zilog Z8000, Intel 8086, Motorola 68000
Kernel typeMonolithic kernel
Influenced byRT-11, OS/8
Default
user interface
Command-line interface (CCP.COM)
LicenseOriginally proprietary, now BSD-like
Succeeded byMP/M, CP/M-86
Official websiteDigital Research CP/M page

CP/M,[3] originally standing for Control Program/Monitor[4] and later Control Program for Microcomputers,[5][6][7] is a mass-market operating system created in 1974 for Intel 8080/85-based microcomputers by Gary Kildall of Digital Research, Inc. CP/M is a disk operating system[8] and its purpose is to organize files on a magnetic storage medium, and to load and run programs stored on a disk. Initially confined to single-tasking on 8-bit processors and no more than 64 kilobytes of memory, later versions of CP/M added multi-user variations and were migrated to 16-bit processors.

CP/M's core components are the Basic Input/Output System (BIOS), the Basic Disk Operating System (BDOS), and the Console Command Processor (CCP). The BIOS consists of drivers that deal with devices and system hardware. The BDOS implements the file system and provides system services to applications. The CCP is the command-line interpreter and provides some built-in commands.

CP/M eventually became the de facto standard and the dominant operating system for microcomputers,[9] in combination with the S-100 bus computers. This computer platform was widely used in business through the late 1970s and into the mid-1980s.[10] CP/M increased the market size for both hardware and software by greatly reducing the amount of programming required to port an application to a new manufacturer's computer.[11][12] An important driver of software innovation was the advent of (comparatively) low-cost microcomputers running CP/M, as independent programmers and hackers bought them and shared their creations in user groups.[13] CP/M was eventually displaced in popularity by DOS following the 1981 introduction of the IBM PC.

History

[edit]
CP/M advertisement in the 29 November 1982 issue of InfoWorld magazine

Early history

[edit]

Gary Kildall originally developed CP/M during 1974,[5][6] as an operating system to run on an Intel Intellec-8 development system, equipped with a Shugart Associates 8-inch floppy-disk drive interfaced via a custom floppy-disk controller.[14] It was written in Kildall's own PL/M (Programming Language for Microcomputers).[15] Various aspects of CP/M were influenced by the TOPS-10 operating system of the DECsystem-10 mainframe computer, which Kildall had used as a development environment.[16][17][18]

CP/M supported a wide range of computers based on the 8080 and Z80 CPUs.[19] An early outside licensee of CP/M was Gnat Computers, an early microcomputer developer out of San Diego, California. In 1977, the company was granted the license to use CP/M 1.0 for any micro they desired for $90. Within the year, demand for CP/M was so high that Digital Research was able to increase the license to tens of thousands of dollars.[20]

Under Kildall's direction, the development of CP/M 2.0 was mostly carried out by John Pierce in 1978. Kathryn Strutynski, a friend of Kildall from Naval Postgraduate School (NPS), became the fourth employee of Digital Research Inc. in early 1979. She started by debugging CP/M 2.0, and later became influential as key developer for CP/M 2.2 and CP/M Plus. Other early developers of the CP/M base included Robert "Bob" Silberstein and David "Dave" K. Brown.[21][22]

CP/M originally stood for "Control Program/Monitor",[3] a name which implies a resident monitor—a primitive precursor to the operating system. However, during the conversion of CP/M to a commercial product, trademark registration documents filed in November 1977 gave the product's name as "Control Program for Microcomputers".[6] The CP/M name follows a prevailing naming scheme of the time, as in Kildall's PL/M language, and Prime Computer's PL/P (Programming Language for Prime), both suggesting IBM's PL/I; and IBM's CP/CMS operating system, which Kildall had used when working at the NPS. This renaming of CP/M was part of a larger effort by Kildall and his wife with business partner, Dorothy McEwen[4] to convert Kildall's personal project of CP/M and the Intel-contracted PL/M compiler into a commercial enterprise. The Kildalls intended to establish the Digital Research brand and its product lines as synonymous with "microcomputer" in the consumer's mind, similar to what IBM and Microsoft together later successfully accomplished in making "personal computer" synonymous with their product offerings. Intergalactic Digital Research, Inc. was later renamed via a corporation change-of-name filing to Digital Research, Inc.[4]

Initial success

[edit]
Apple CP/M Card with manual

By September 1981, Digital Research had sold more than 250,000 CP/M licenses; InfoWorld stated that the actual market was likely larger because of sublicenses. Many different companies produced CP/M-based computers for many different markets; the magazine stated that "CP/M is well on its way to establishing itself as the small-computer operating system".[23] Even companies with proprietary operating systems, such as Heath/Zenith (HDOS), offered CP/M as an alternative for their 8080/Z80-based systems; by contrast, no comparable standard existed for computers based on the also popular 6502 CPU.[19] They supported CP/M because of its large library of software. The Xerox 820 ran the operating system because "where there are literally thousands of programs written for it, it would be unwise not to take advantage of it", Xerox said.[24] (Xerox included a Howard W. Sams CP/M manual as compensation for Digital Research's documentation, which InfoWorld described as atrocious,[25] incomplete, incomprehensible, and poorly indexed.[26]) By 1984, Columbia University used the same source code to build Kermit binaries for more than a dozen different CP/M systems, plus two generic versions.[27] The operating system was described as a "software bus",[28][29] allowing multiple programs to interact with different hardware in a standardized way.[30] Programs written for CP/M were typically portable among different machines, usually requiring only the specification of the escape sequences for control of the screen and printer. This portability made CP/M popular, and much more software was written for CP/M than for operating systems that ran on only one brand of hardware. One restriction on portability was that certain programs used the extended instruction set of the Z80 processor and would not operate on an 8080 or 8085 processor. Another was graphics routines, especially in games and graphics programs, which were generally machine-specific as they used direct hardware access for speed, bypassing the OS and BIOS (this was also a common problem in early DOS machines).[citation needed]

Bill Gates claimed that the Apple II with a Z-80 SoftCard was the single most-popular CP/M hardware platform.[31] Digital Research stated in 1982 that the operating system had been licensed for more than 450 types of computer systems.[32] Many different brands of machines ran the operating system, some notable examples being the Altair 8800, the IMSAI 8080, the Osborne 1 and Kaypro luggables, and MSX computers. The best-selling CP/M-capable system of all time was probably the Amstrad PCW. In the UK, CP/M was also available on Research Machines educational computers (with the CP/M source code published as an educational resource), and for the BBC Micro when equipped with a Z80 co-processor. Furthermore, it was available for the Amstrad CPC series, the Commodore 128, TRS-80, and later models of the ZX Spectrum. CP/M 3 was also used on the NIAT, a custom handheld computer designed for A. C. Nielsen's internal use with 1 MB of SSD memory.

Multi-user

[edit]

In 1979, a multi-user compatible derivative of CP/M was released. MP/M allowed multiple users to connect to a single computer, using multiple terminals to provide each user with a screen and keyboard. Later versions ran on 16-bit processors.

CP/M Plus

[edit]
CP/M Plus (CP/M 3) System Guide

The last 8-bit version of CP/M was version 3, often called CP/M Plus, released in 1983.[21] Its BDOS was designed by David K. Brown.[21] It incorporated the bank switching memory management of MP/M in a single-user single-task operating system compatible with CP/M 2.2 applications. CP/M 3 could therefore use more than 64 KB of memory on an 8080 or Z80 processor. The system could be configured to support date stamping of files.[21] The operating system distribution software also included a relocating assembler and linker.[2] CP/M 3 was available for the last generation of 8-bit computers, notably the Amstrad PCW, the Amstrad CPC, the ZX Spectrum +3, the Commodore 128, MSX machines and the Radio Shack TRS-80 Model 4.[33]

16-bit versions

[edit]
DEC PRO-CP/M-80 floppy-disk distribution for the Z80-A co-processor in a DEC Professional 3xx series

There were versions of CP/M for some 16-bit CPUs as well.

The first version in the 16-bit family was CP/M-86 for the Intel 8086 in November 1981.[34] Kathryn Strutynski was the project manager for the evolving CP/M-86 line of operating systems.[21][22] At this point, the original 8-bit CP/M became known by the retronym CP/M-80 to avoid confusion.[34]

CP/M-86 was expected to be the standard operating system of the new IBM PCs, but DRI and IBM were unable to negotiate development and licensing terms. IBM turned to Microsoft instead, and Microsoft delivered PC DOS based on 86-DOS. Although CP/M-86 became an option for the IBM PC after DRI threatened legal action, it never overtook Microsoft's system. Most customers were repelled by the significantly greater price IBM charged for CP/M-86 over PC DOS (US$240 and US$40, respectively).[35]

When Digital Equipment Corporation (DEC) put out the Rainbow 100 to compete with IBM, it came with CP/M-80 using a Z80 chip, CP/M-86 or MS-DOS using an 8088 microprocessor, or CP/M-86/80 using both. The Z80 and 8088 CPUs ran concurrently.[36][37] A benefit of the Rainbow was that it could continue to run 8-bit CP/M software, preserving a user's possibly sizable investment as they moved into the 16-bit world of MS-DOS.[36] A similar dual-processor adaption for the CompuPro System 816 [sr] was named CP/M 8-16. The CP/M-86 adaptation for the 8085/8088-based Zenith Z-100 also supported running programs for both of its CPUs.

Soon following CP/M-86, another 16-bit version of CP/M was CP/M-68K for the Motorola 68000. The original version of CP/M-68K in 1982 was written in Pascal/MT+68k, but it was ported to C later on. CP/M-68K, already running on the Motorola EXORmacs systems, was initially to be used in the Atari ST computer, but Atari decided to go with a newer disk operating system called GEMDOS. CP/M-68K was also used on the SORD M68 and M68MX computers.[38]

In 1982, there was also a port from CP/M-68K to the 16-bit Zilog Z8000 for the Olivetti M20, written in C, named CP/M-8000.[39][40]

These 16-bit versions of CP/M required application programs to be re-compiled for the new CPUs. Some programs written in assembly language could be automatically translated for a new processor. One tool for this was Digital Research's XLT86, which translated .ASM source code for the Intel 8080 processor into .A86 source code for the Intel 8086. The translator would also optimize the output for code size and take care of calling conventions, so that CP/M-80 and MP/M-80 programs could be ported to the CP/M-86 and MP/M-86 platforms automatically. XLT86 itself was written in PL/I-80 and was available for CP/M-80 platforms as well as for VAX/VMS.[41]

Displacement by MS-DOS

[edit]

By the early 1980s an estimated 2000 CP/M applications existed.[42] Many expected that it would be the standard operating system for 16-bit computers.[43] In 1980 IBM approached Digital Research, at Bill Gates' suggestion,[44] to license a forthcoming version of CP/M for its new product, the IBM Personal Computer. Upon the failure to obtain a signed non-disclosure agreement, the talks failed, and IBM instead contracted with Microsoft to provide an operating system.[45]

Many of the basic concepts and mechanisms of early versions of MS-DOS resemble those of CP/M. Internals like file-handling data structures are identical, and both refer to disk drives with a letter (A:, B:, etc.). MS-DOS's main innovation was its FAT file system. This similarity made it easier to port popular CP/M software like WordStar and dBase. However, CP/M's concept of separate user areas for files on the same disk was never ported to MS-DOS. Since MS-DOS has access to more memory (as few IBM PCs were sold with less than 64 KB of memory, while CP/M can run in 16 KB if necessary), more commands are built into the command-line shell, making MS-DOS somewhat faster and easier to use on floppy-based computers.

Although one of the first peripherals for the IBM PC was the Baby Blue card, a SoftCard-like expansion card that lets the PC run 8-bit CP/M software like WordStar not yet available for it,[42] and BYTE in 1982 described MS-DOS and CP/M as David and Goliath, the magazine stated that MS-DOS was "much more user-friendly, faster, with many more advantages, and fewer disadvantages".[32] InfoWorld stated in 1984 that efforts to introduce CP/M to the home market had been largely unsuccessful and most CP/M software was too expensive for home users.[46] In 1986 the magazine stated that Kaypro had stopped production of 8-bit CP/M-based models to concentrate on sales of MS-DOS compatible systems, long after most other vendors had ceased production of new equipment and software for CP/M.[47] CP/M rapidly lost market share as the microcomputing market moved to the IBM-compatible platform, and never regained its former popularity. Byte magazine, one of the leading industry magazines for microcomputers, essentially ceased covering CP/M products within a few years of the introduction of the IBM PC. For example, in 1983 there were still a few advertisements for S-100 boards and articles on CP/M software, but by 1987 these were no longer found in the magazine.

Later versions of CP/M-86 made significant strides in performance and usability and were made compatible with MS-DOS. To reflect this compatibility the name was changed, and CP/M-86 became DOS Plus, which in turn became DR-DOS.

ZCPR

[edit]

ZCPR[48] (the Z80 Command Processor Replacement) was introduced on 2 February 1982 as a drop-in replacement for the standard Digital Research console command processor (CCP) and was initially written by a group of computer hobbyists who called themselves "The CCP Group". They were Frank Wancho, Keith Petersen (the archivist behind Simtel at the time), Ron Fowler, Charlie Strom, Bob Mathias, and Richard Conn. Richard was, in fact, the driving force in this group (all of whom maintained contact through email).

ZCPR1 was released on a disk put out by SIG/M (Special Interest Group/Microcomputers), a part of the Amateur Computer Club of New Jersey.

ZCPR2 was released on 14 February 1983. It was released as a set of ten disks from SIG/M. ZCPR2 was upgraded to 2.3, and also was released in 8080 code, permitting the use of ZCPR2 on 8080 and 8085 systems.

Conn and Frank Gaude formed Echelon Inc. to publish the next version of ZCPR as a commercial product, while still distributing it as free software.[49] ZCPR3[50] was released on 14 July 1984, as a set of nine disks from SIG/M. The code for ZCPR3 could also be compiled (with reduced features) for the 8080 and would run on systems that did not have the requisite Z80 microprocessor. Features of ZCPR as of version 3 included shells, aliases, I/O redirection, flow control, named directories, search paths, custom menus, passwords, and online help. In January 1987, Richard Conn stopped developing ZCPR, and Echelon asked Jay Sage (who already had a privately enhanced ZCPR 3.1) to continue work on it. Thus, ZCPR 3.3 was developed and released. ZCPR 3.3 no longer supported the 8080 series of microprocessors, and added the most features of any upgrade in the ZCPR line. ZCPR 3.3 also included a full complement of utilities with considerably extended capabilities. While enthusiastically supported by the CP/M user base of the time, ZCPR alone was insufficient to slow the demise of CP/M.

Hardware model

[edit]
Sanco 8001 computer, running under CP/M 2.2 (1982)
CP/M cartridge for the Commodore 64

A minimal 8-bit CP/M system would contain the following components:

  • A computer terminal using the ASCII character set
  • An Intel 8080 (and later the 8085) or Zilog Z80 microprocessor
    • The NEC V20 and V30 processors support an 8080-emulation mode that can run 8-bit CP/M on a PC-DOS/MS-DOS computer so equipped, though any PC clone could run CP/M-86.[51][52]
  • At least 16 kilobytes of RAM, beginning at address 0
  • A means to bootstrap the first sector of the diskette
  • At least one floppy-disk drive

The only hardware system that CP/M, as sold by Digital Research, would support was the Intel 8080 Development System. Manufacturers of CP/M-compatible systems customized portions of the operating system for their own combination of installed memory, disk drives, and console devices. CP/M would also run on systems based on the Zilog Z80 processor since the Z80 was compatible with 8080 code. While the Digital Research distributed core of CP/M (BDOS, CCP, core transient commands) did not use any of the Z80-specific instructions, many Z80-based systems used Z80 code in the system-specific BIOS, and many applications were dedicated to Z80-based CP/M machines.

Digital Research subsequently partnered with Zilog and American Microsystems to produce Personal CP/M, a ROM-based version of the operating system aimed at lower-cost systems that could potentially be equipped without disk drives.[53] First featured in the Sharp MZ-800, a cassette-based system with optional disk drives,[54] Personal CP/M was described as having been "rewritten to take advantage of the enhanced Z-80 instruction set" as opposed to preserving portability with the 8080. American Microsystems announced a Z80-compatible microprocessor, the S83, featuring 8 KB of in-package ROM for the operating system and BIOS, together with comprehensive logic for interfacing with 64-kilobit dynamic RAM devices.[55] Unit pricing of the S83 was quoted as $32 in 1,000 unit quantities.[56]

On most machines the bootstrap was a minimal bootloader in ROM combined with some means of minimal bank switching or a means of injecting code on the bus (since the 8080 needs to see boot code at Address 0 for start-up, while CP/M needs RAM there); for others, this bootstrap had to be entered into memory using front-panel controls each time the system was started.

CP/M used the 7-bit ASCII set. The other 128 characters made possible by the 8-bit byte were not standardized. For example, one Kaypro used them for Greek characters, and Osborne machines used the 8th bit set to indicate an underlined character. WordStar used the 8th bit as an end-of-word marker. International CP/M systems most commonly used the ISO 646 norm for localized character sets, replacing certain ASCII characters with localized characters rather than adding them beyond the 7-bit boundary.

Components

[edit]

While running, the CP/M operating system loaded into memory has three components:[3][57]: 2 [58]: 1 [59]: 3, 4–5 [60]: 1-4–1-6 

  • Basic Input/Output System (BIOS),
  • Basic Disk Operating System (BDOS),
  • Console Command Processor (CCP).

The BIOS and BDOS are memory-resident, while the CCP is memory-resident unless overwritten by an application, in which case it is automatically reloaded after the application finished running. A number of transient commands for standard utilities are also provided. The transient commands reside in files with the extension .COM on disk.

The BIOS directly controls hardware components other than the CPU and main memory. It contains functions such as character input and output and the reading and writing of disk sectors. The BDOS implements the CP/M file system and some input/output abstractions (such as redirection) on top of the BIOS. The CCP takes user commands and either executes them directly (internal commands such as DIR to show a directory or ERA to delete a file) or loads and starts an executable file of the given name (transient commands such as PIP.COM to copy files or STAT.COM to show various file and system information). Third-party applications for CP/M are also essentially transient commands.

The BDOS, CCP and standard transient commands are the same in all installations of a particular revision of CP/M, but the BIOS portion is always adapted to the particular hardware.

Adding memory to a computer, for example, means that the CP/M system must be reinstalled to allow transient programs to use the additional memory space. A utility program (MOVCPM) is provided with system distribution that allows relocating the object code to different memory areas. The utility program adjusts the addresses in absolute jump and subroutine call instructions to new addresses required by the new location of the operating system in processor memory. This newly patched version can then be saved on a new disk, allowing application programs to access the additional memory made available by moving the system components. Once installed, the operating system (BIOS, BDOS and CCP) is stored in reserved areas at the beginning of any disk which can be used to boot the system. On start-up, the bootloader (usually contained in a ROM firmware chip) loads the operating system from the disk in drive A:.

By modern standards CP/M is primitive, owing to the extreme constraints on program size. With version 1.0 there is no provision for detecting a changed disk. If a user changes disks without manually rereading the disk directory the system writes on the new disk using the old disk's directory information, ruining the data stored on the disk. From version 1.1 or 1.2 onwards, changing a disk then trying to write to it before its directory is read will cause a fatal error to be signalled. This avoids overwriting the disk but requires a reboot and loss of the data to be stored on disk.

The majority of the complexity in CP/M is isolated in the BDOS, and to a lesser extent, the CCP and transient commands. This meant that by porting the limited number of simple routines in the BIOS to a particular hardware platform, the entire OS would work. This significantly reduced the development time needed to support new machines, and was one of the main reasons for CP/M's widespread use. Today this sort of abstraction is common to most OSs (a hardware abstraction layer), but at the time of CP/M's birth, OSs were typically intended to run on only one machine platform, and multilayer designs were considered unnecessary.

Console Command Processor

[edit]
Screenshot showing a CP/M 3.0 directory listing using the DIR command on a Commodore 128 home computer

The Console Command Processor, or CCP, accepts input from the keyboard and conveys results to the terminal. CP/M itself works with either a printing terminal or a video terminal. All CP/M commands have to be typed in on the command line. The console most often displays the A> prompt, to indicate the current default disk drive. When used with a video terminal, this is usually followed by a blinking cursor supplied by the terminal. The CCP awaits input from the user. A CCP internal command, of the form drive letter followed by a colon, can be used to select the default drive. For example, typing B: and pressing enter at the command prompt changes the default drive to B, and the command prompt then becomes B> to indicate this change.

CP/M's command-line interface was patterned after the Concise Command Language used in operating systems from Digital Equipment, such as RT-11 for the PDP-11 and OS/8 for the PDP-8.[citation needed] Commands take the form of a keyword followed by a list of parameters separated by spaces or special characters. Similar to a Unix shell builtin, if an internal command is recognized, it is carried out by the CCP itself. Otherwise it attempts to find an executable file on the currently logged disk drive and (in later versions) user area, loads it, and passes it any additional parameters from the command line. These are referred to as "transient" programs. On completion, BDOS will reload the CCP if it has been overwritten by application programs — this allows transient programs a larger memory space.

The commands themselves can sometimes be obscure. For instance, the command to duplicate files is named PIP (Peripheral-Interchange-Program), the name of the old DEC utility used for that purpose. The format of parameters given to a program was not standardized, so that there is no single option character that differentiated options from file names. Different programs can and do use different characters.

The CP/M Console Command Processor includes DIR, ERA, REN, SAVE, TYPE, and USER as built-in commands.[61] Transient commands in CP/M include ASM, DDT, DUMP, ED, LOAD, MOVCPM [pl], PIP, STAT, SUBMIT, and SYSGEN.[61]

CP/M Plus (CP/M Version 3) includes DIR (display list of files from a directory except those marked with the SYS attribute), DIRSYS / DIRS (list files marked with the SYS attribute in the directory), ERASE / ERA (delete a file), RENAME / REN (rename a file), TYPE / TYP (display contents of an ASCII character file), and USER / USE (change user number) as built-in commands:[62] CP/M 3 allows the user to abbreviate the built-in commands.[63] Transient commands in CP/M 3 include COPYSYS, DATE, DEVICE, DUMP, ED, GET, HELP, HEXCOM, INITDIR, LINK, MAC, PIP, PUT, RMAC, SET, SETDEF, SHOW, SID, SUBMIT, and XREF.[63]

Basic Disk Operating System

[edit]

The Basic Disk Operating System,[15][14] or BDOS,[15][14] provides access to such operations as opening a file, output to the console, or printing. Application programs load processor registers with a function code for the operation, and addresses for parameters or memory buffers, and call a fixed address in memory. Since the address is the same independent of the amount of memory in the system, application programs run the same way for any type or configuration of hardware.

Basic Input Output System

[edit]
CP/M advertisement in the 11 December 1978 issue of InfoWorld magazine

The Basic Input Output System or BIOS,[15][14] provides the lowest level functions required by the operating system.

These include reading or writing single characters to the system console and reading or writing a sector of data from the disk. The BDOS handles some of the buffering of data from the diskette, but before CP/M 3.0 it assumes a disk sector size fixed at 128 bytes, as used on single-density 8-inch floppy disks. Since most 5.25-inch disk formats use larger sectors, the blocking and deblocking and the management of a disk buffer area is handled by model-specific code in the BIOS.

Customization is required because hardware choices are not constrained by compatibility with any one popular standard. For example, some manufacturers designed built-in integrated video display systems, while others relied on separate computer terminals. Serial ports for printers and modems can use different types of UART chips, and port addresses are not fixed. Some machines use memory-mapped I/O instead of the 8080 I/O address space. All of these variations in the hardware are concealed from other modules of the system by use of the BIOS, which uses standard entry points for the services required to run CP/M such as character I/O or accessing a disk block. Since support for serial communication to a modem is very rudimentary in the BIOS or may be absent altogether, it is common practice for CP/M programs that use modems to have a user-installed overlay containing all the code required to access a particular machine's serial port.

Applications

[edit]
Distribution 5+14-inch diskettes and packaging for the last version (version 4) of WordStar word processing program released for 8-bit CP/M

WordStar, one of the first widely used word processors, and dBase, an early and popular database program for microcomputers, were originally written for CP/M. Two early outliners, KAMAS (Knowledge and Mind Amplification System) and its cut-down successor Out-Think (without programming facilities and retooled for 8080/V20 compatibility) were also written for CP/M, though later rewritten for MS-DOS. Turbo Pascal, the ancestor of Borland Delphi, and Multiplan, the ancestor of Microsoft Excel, also debuted on CP/M before MS-DOS versions became available. VisiCalc, the first-ever spreadsheet program, was made available for CP/M. Another company, Sorcim, created its SuperCalc spreadsheet for CP/M, which would go on to become the market leader and de facto standard on CP/M. Supercalc would go on to be a competitor in the spreadsheet market in the MS-DOS world. AutoCAD, a CAD application from Autodesk debuted on CP/M. A host of compilers and interpreters for popular programming languages of the time (such as BASIC, Borland's Turbo Pascal, FORTRAN and even PL/I[64]) were available, among them several of the earliest Microsoft products.

CP/M software often comes with installers that adapts it to a wide variety of computers.[65] A Kaypro II owner, for example, would obtain software on Xerox 820 format, then copy it to and run it from Kaypro-format disks.[66] The source code for BASIC programs is easily accessible, and most forms of copy protection are ineffective on the operating system.[67] While copy-protected programs for contemporary operating systems often use nonstandard disk formats that other software cannot read, CP/M users expect cross-software compatibility for their files; an unreadable disk is by definition not in a CP/M format.[68]

The lack of standardized graphics support limited video games, but various character and text-based games were ported, such as Telengard,[69] Gorillas,[70] Hamurabi, Lunar Lander, along with early interactive fiction including the Zork series and Colossal Cave Adventure. Text adventure specialist Infocom was one of the few publishers to consistently release their games in CP/M format. Lifeboat Associates started collecting and distributing user-written "free" software. One of the first was XMODEM, which allowed reliable file transfers via modem and phone line. Another program native to CP/M was the outline processor KAMAS.[citation needed]

Transient Program Area

[edit]

In the original version of CP/M for the 8080, 8085, and Z80, the read/write memory between address 0100 hexadecimal and the location just before address stored at 0006H (the lowest address of the BDOS) is the Transient Program Area (TPA) available for CP/M application programs.[57]: 2, 233  Although all Z80 and 8080 processors could address 64 kilobytes of memory, the amount available for application programs could vary, depending on the design of the particular computer. Some computers used large parts of the address space for such things as BIOS ROMs, or video display memory. As a result, some systems had more TPA memory available than others. Bank switching was a common technique that allowed systems to have a large TPA while switching out ROM or video memory space as needed. CP/M 3.0 allowed parts of the BDOS to be in bank-switched memory as well.

Debugging application

[edit]

CP/M came with a Dynamic Debugging Tool, nicknamed DDT (after the insecticide, i.e. a bug-killer), which allowed memory and program modules to be examined and manipulated, and allowed a program to be executed one step at a time.[71][72][73]

Resident programs

[edit]

CP/M originally did not support the equivalent of terminate and stay resident (TSR) programs as under DOS. Programmers could write software that could intercept certain operating system calls and extend or alter their functionality. Using this capability, programmers developed and sold auxiliary desk accessory programs, such as SmartKey, a keyboard utility to assign any string of bytes to any key.[74] CP/M 3, however, added support for dynamically loadable Resident System Extensions (RSX).[62][21] A so-called null command file could be used to allow CCP to load an RSX without a transient program.[62][21] Similar solutions like RSMs (for Resident System Modules) were also retrofitted to CP/M 2.2 systems by third-parties.[75][76][77]

Software installation

[edit]

Although CP/M provided some hardware abstraction to standardize the interface to disk I/O or console I/O, application programs still typically required installation to make use of all the features of such equipment as printers and terminals. Often these were controlled by escape sequences which had to be altered for different devices. For example, the escape sequence to select bold face on a printer would have differed among manufacturers, and sometimes among models within a manufacturer's range. This procedure was not defined by the operating system; a user would typically run an installation program that would either allow selection from a range of devices, or else allow feature-by-feature editing of the escape sequences required to access a function. This had to be repeated for each application program, since there was no central operating system service provided for these devices.

The initialization codes for each model of printer had to be written into the application. To use a program such as Wordstar with more than one printer (say, a fast dot-matrix printer or a slower but presentation-quality daisy wheel printer), a separate version of Wordstar had to be prepared, and one had to load the Wordstar version that corresponded to the printer selected (and exiting and reloading to change printers).

Disk formats

[edit]

IBM System/34 and IBM 3740's 128 byte/sector, single-density, single-sided format is CP/M's standard 8-inch floppy-disk format. No standard 5.25-inch CP/M disk format exists, with Kaypro, Morrow Designs, Osborne, and others each using their own.[78][79][25][80][68] Certain formats were more popular than others. Most software was available in the Xerox 820 format, and other computers such as the Kaypro II were compatible with it,[66][81] but InfoWorld estimated in September 1981 that "about two dozen formats were popular enough that software creators had to consider them to reach the broadest possible market".[23] JRT Pascal, for example, provided versions on 5.25-inch disk for North Star, Osborne, Apple, Heath/Zenith hard sector and soft sector, and Superbrain, and one 8-inch version.[82] Ellis Computing also offered its software for both Heath formats, and 16 other 5.25-inch formats including two different TRS-80 CP/M modifications.[83] Lifetree and some other software distributors also converted CP/M applications to various systems.[84]

Various formats were used depending on the characteristics of particular systems and to some degree the choices of the designers. CP/M supports options to control the size of reserved and directory areas on the disk, and the mapping between logical disk sectors (as seen by CP/M programs) and physical sectors as allocated on the disk. There are many ways to customize these parameters for every system[85] but once they are set, no standardized way exists for a system to load parameters from a disk formatted on another system.

While almost every CP/M system with 8-inch drives can read the aforementioned IBM single-sided, single-density format, for other formats the degree of portability between different CP/M machines depends on the type of disk drive and controller used since many different floppy types existed in the CP/M era in both 8-inch and 5.25-inch sizes.[79] Disks can be hard or soft sectored, single or double density, single or double sided, 35 track, 40 track, 77 track, or 80 track, and the sector layout, size and interleave can vary widely as well. Although translation programs can allow the user to read disk types from different machines, the drive type and controller are also factors. By 1982, soft-sector, single-sided, 40-track 5.25-inch disks had become the most popular format to distribute CP/M software on as they were used by the most common consumer-level machines of that time, such as the Apple II, TRS-80, Osborne 1, Kaypro II, and IBM PC. A translation program allows the user to read any disks on his machine that had a similar format; for example, the Kaypro II can read TRS-80, Osborne, IBM PC, and Epson disks. Other disk types such as 80 track or hard sectored are completely impossible to read. The first half of double-sided disks (like those of the Epson QX-10) can be read because CP/M accessed disk tracks sequentially with track 0 being the first (outermost) track of side 1 and track 79 (on a 40-track disk) being the last (innermost) track of side 2. Apple II users are unable to use anything but Apple's GCR format and so have to obtain CP/M software on Apple format disks or else transfer it via serial link.

The fragmented CP/M market, requiring distributors either to stock multiple formats of disks or to invest in multiformat duplication equipment, compared with the more standardized IBM PC disk formats, was a contributing factor to the rapid obsolescence of CP/M after 1981.

One of the last notable CP/M-capable machines to appear was the Commodore 128 in 1985, which had a Z80 for CP/M support in addition to its native mode using a 6502-derivative CPU. Using CP/M required either a 1571 or 1581 disk drive which could read soft-sector 40-track MFM-format disks.

The first computer to use a 3.5-inch floppy drive, the Sony SMC-70,[86] ran CP/M 2.2. The Commodore 128, Bondwell-2 laptop, Micromint/Ciarcia SB-180,[87] MSX and TRS-80 Model 4 (running Montezuma CP/M 2.2) also supported the use of CP/M with 3.5-inch floppy disks. CP/AM, Applied Engineering's version of CP/M for the Apple II, also supported 3.5-inch disks (as well as RAM disks on RAM cards compatible with the Apple II Memory Expansion Card).[88] The Amstrad PCW ran CP/M using 3-inch floppy drives at first, and later switched to the 3.5 inch drives.

File system

[edit]

File names were specified as a string of up to eight characters, followed by a period, followed by a file name extension of up to three characters ("8.3" filename format). The extension usually identified the type of the file. For example, .COM indicated an executable program file, and .TXT indicated a file containing ASCII text. Characters in filenames entered at the command prompt were converted to upper case, but this was not enforced by the operating system. Programs (MBASIC is a notable example) were able to create filenames containing lower-case letters, which then could not easily be referenced at the command line.

Each disk drive was identified by a drive letter, for example, drive A and drive B. To refer to a file on a specific drive, the drive letter was prefixed to the file name, separated by a colon, e.g., A:FILE.TXT. With no drive letter prefixed, access was to files on the current default drive.[89]

File size was specified as the number of 128-byte records (directly corresponding to disk sectors on 8-inch drives) occupied by a file on the disk. There was no generally supported way of specifying byte-exact file sizes. The current size of a file was maintained in the file's File Control Block (FCB) by the operating system. Since many application programs (such as text editors) prefer to deal with files as sequences of characters rather than as sequences of records, by convention text files were terminated with a control-Z character (ASCII SUB, hexadecimal 1A). Determining the end of a text file therefore involved examining the last record of the file to locate the terminating control-Z. This also meant that inserting a control-Z character into the middle of a file usually had the effect of truncating the text contents of the file.

With the advent of larger removable and fixed disk drives, disk de-blocking formulas were employed which resulted in more disk blocks per logical file allocation block. While this allowed for larger file sizes, it also meant that the smallest file which could be allocated increased in size from 1 KB (on single-density drives) to 2 KB (on double-density drives) and so on, up to 32 KB for a file containing only a single byte. This made for inefficient use of disk space if the disk contained a large number of small files.

File modification time stamps were not supported in releases up to CP/M 2.2, but were an optional feature in MP/M and CP/M 3.0.[21]

CP/M 2.2 had no subdirectories in the file structure, but provided 16 numbered user areas to organize files on a disk. To change user one had to simply type "User X" at the command prompt, X being the user number. Security was non-existent and considered unnecessary on a personal computer. The user area concept was to make the single-user version of CP/M somewhat compatible with multi-user MP/M systems. A common patch for the CP/M and derivative operating systems was to make one user area accessible to the user independent of the currently set user area. A USER command allowed the user area to be changed to any area from 0 to 15. User 0 was the default. If one changed to another user, such as USER 1, the material saved on the disk for this user would only be available to USER 1; USER 2 would not be able to see it or access it. However, files stored in the USER 0 area were accessible to all other users; their location was specified with a prefatory path, since the files of USER 0 were only visible to someone logged in as USER 0. The user area feature arguably had little utility on small floppy disks, but it was useful for organizing files on machines with hard drives. The intent of the feature was to ease use of the same computer for different tasks. For example, a secretary could do data entry, then, after switching USER areas, another employee could use the machine to do billing without their files intermixing.

Graphics

[edit]
MBASIC text output displayed on a monochrome monitor typical for that time

Although graphics-capable S-100 systems existed from the commercialization of the S-100 bus, CP/M did not provide any standardized graphics support until 1982 with GSX (Graphics System Extension). Owing to the small amount of available memory, graphics was never a common feature associated with 8-bit CP/M operating systems. Most systems could only display rudimentary ASCII art charts and diagrams in text mode or by using a custom character set. Some computers in the Kaypro line and the TRS-80 Model 4 had video hardware supporting block graphics characters, and these were accessible to assembler programmers and BASIC programmers using the CHR$ command. The Model 4 could display 640 by 240 pixel graphics with an optional high resolution board.

Derivatives

[edit]
CP/M derivative SCP running on an East German robotron PC 1715
CP/J version 2.21 running on an Elwro 804 Junior

Official

[edit]

Some companies made official enhancements of CP/M based on Digital Research source code. An example is IMDOS for the IMSAI 8080 computer made by IMS Associates, Inc., a clone of the famous Altair 8800.

Compatible

[edit]

Other CP/M compatible OSes were developed independently and made no use of Digital Research code. Some contemporary examples were:

  • Cromemco CDOS from Cromemco
  • MSX-DOS for the MSX range of computers is CP/M-compatible and can run CP/M programs.
  • The Epson QX-10 shipped with a choice of CP/M or the compatible TPM-II or TPM-III.
  • The British ZX Spectrum compatible SAM Coupé had an optional CP/M-2.2 compatible OS called Pro-DOS.
  • The Amstrad/Schneider CPC series 6xx (disk-based) and PCW series computers were bundled with an CP/M disk pack.
  • The Husky computer ran a ROM-based menu-driven program loader called DEMOS which could run many CP/M applications.
  • ZSDOS is a replacement BDOS for CP/M-80 2.2 written by Harold F. Bower and Cameron W. Cotrill.
  • CPMish is a new FOSS CP/M 2.2-compatible operating system which originally contained no DR code. It includes ZSDOS as its BDOS and ZCPR (see earlier) as the command processor. Since Bryan Sparks, the president of DR owners Lineo, granted permission in 2022 to modify and redistribute CP/M code, developer David Given is updating CPMish with some parts of the original DR CP/M.
  • LokiOS is a CP/M 2.2 compatible OS. Version 0.9 was publicly released in 2023 by David Kitson as a solo-written Operating System exercise, intended for the Open Spectrum Project and includes source code for the BIOS, BDOS and Command-line interface as well as other supporting applications and drivers. The distribution also includes original DR Source code and a utility to allow users to hot-swap OS components (e.g., BDOS, CCP) on the fly.
  • IS-DOS for the Enterprise computers, written by Intelligent Software.
  • VT-DOS for the Videoton TV Computer, written by Intelligent Software.

Enhancements

[edit]

Some CP/M compatible operating systems extended the basic functionality so far that they far exceeded the original, for example the multi-processor capable TurboDOS.

Eastern bloc

[edit]

A number of CP/M-80 derivatives existed in the former Eastern Bloc under various names, including SCP (Single User Control Program [de]), SCP/M, CP/A,[90] CP/J, CP/KC, CP/KSOB, CP/L, CP/Z, MICRODOS, BCU880, ZOAZ, OS/M, TOS/M, ZSDOS, M/OS, COS-PSA, DOS-PSA, CSOC, CSOS, CZ-CPM, DAC, HC and others.[91][92] There were also CP/M-86 derivatives named SCP1700, CP/K and K8918-OS.[92] They were produced by the East German VEB Robotron and others.[92][91][90]

Legacy

[edit]

A number of behaviors exhibited by Microsoft Windows are a result of backward compatibility with MS-DOS, which in turn attempted some backward compatibility with CP/M. The drive letter and 8.3 filename conventions in MS-DOS (and early Windows versions) were originally adopted from CP/M.[93] The wildcard matching characters used by Windows (? and *) are based on those of CP/M,[94] as are the reserved filenames used to redirect output to a printer ("PRN:"), and the console ("CON:"). The drive names A and B were used to designate the two floppy disk drives that CP/M systems typically used; when hard drives appeared, they were designated C, which survived into MS-DOS as the C:\> command prompt.[95] The control character ^Z marking the end of some text files can also be attributed to CP/M.[96] Various commands in DOS were modelled after CP/M commands; some of them even carried the same name, like DIR, REN/RENAME, or TYPE (and ERA/ERASE in DR-DOS). File extensions like .TXT or .COM are still used to identify file types on many operating systems.

In 1997 and 1998, Caldera released some CP/M 2.2 binaries and source code under an open source license, also allowing the redistribution and modification of further collected Digital Research files related to the CP/M and MP/M families through Tim Olmstead's "The Unofficial CP/M Web site" since 1997.[97][98][99] After Olmstead's death on 12 September 2001,[100] the distribution license was refreshed and expanded by Lineo, who had meanwhile become the owner of those Digital Research assets, on 19 October 2001.[101][102][1][103] In October 2014, to mark the 40th anniversary of the first presentation of CP/M, the Computer History Museum released early source code versions of CP/M.[104]

As of 2018, there are a number of active vintage, hobby and retro-computer people and groups, and some small commercial businesses, still developing and supporting computer platforms that use CP/M (mostly 2.2) as the host operating system.[citation needed]

See also

[edit]

References

[edit]

Further reading

[edit]
[edit]
Revisions and contributorsEdit on WikipediaRead on Wikipedia
from Grokipedia
CP/M, originally standing for Control Program/Monitor and later Control Program for Microcomputers, is a mass-market operating system developed by American computer scientist in 1974 for early microcomputers equipped with the Intel 8080 microprocessor. Written in the PL/M programming language, it was designed to manage file storage and retrieval on 8-inch floppy disks, providing a standardized interface that separated applications from hardware specifics, thus enabling portability across compatible systems. demonstrated the first working prototype in Pacific Grove, California, marking it as the first commercially successful personal computer operating system. founded in 1974 to commercialize CP/M, which quickly became the dominant operating system for 8-bit microcomputers during the late 1970s and early 1980s. By 1981, it supported over 3,000 computer models from various manufacturers, generating $5.4 million in annual revenue for DRI. The system's architecture, influenced by mainframe operating systems like DEC's TOPS-10, included three main components: the Basic Input/Output System (BIOS) for hardware interaction, the Basic Disk Operating System (BDOS) for file management, and the Console Command Processor (CCP) for user commands, fostering a rich ecosystem of software applications. CP/M's influence extended to multi-user variants like MP/M (1979) and 16-bit adaptations such as CP/M-86 for the Intel 8086 processor, though it faced competition from UNIX derivatives and eventually IBM's PC-DOS in the 1980s. Its legacy endures as a foundational technology in personal computing, with early source code versions from 1975 to 1979 released by the Computer History Museum in 2014 for non-commercial use, highlighting its role in democratizing software development for microcomputers.

History

Origins and Development

, a computer science instructor at the Naval Postgraduate School in Monterey, California, began developing CP/M in the early 1970s during his spare time, drawing inspiration from Digital Equipment Corporation's operating systems such as RT-11 for the PDP-11 and OS/8 for the PDP-8, which emphasized command-line interfaces and file handling suitable for minicomputers. , who held a Ph.D. in computer science and had experience with Intel's early microprocessors through consulting work, aimed to create a portable software environment for the emerging microprocessor-based systems, viewing them as full-fledged computers rather than mere controllers. In 1974, completed CP/M-80 version 1.0, targeted at the Intel 8080 microprocessor, initially serving as a monitor program to manage input/output for the ICOM-1 floppy disk controller, which he co-developed with hardware designer John Torode to interface Shugart Associates' eight-inch drives with S-100 bus systems. The system's core design prioritized hardware independence via a modular Basic Input/Output System (BIOS) that abstracted device-specific operations, enabling easy adaptation across different machines; it also featured simple file management through fixed-length file control blocks (FCBs) for directory operations and a straightforward command-line interface modeled after DEC conventions, such as the Peripheral Interchange Program (PIP) for file transfers. These elements allowed CP/M to function with minimal memory overhead, typically under 4 KB for the core, while supporting basic program loading and execution from floppy disks. CP/M 1.4, released in 1978, refined these foundations with enhanced directory handling that supported up to 64 entries per disk and introduced user areas—logical partitions allowing multiple users to maintain separate file namespaces on the same volume without complex permissions. This version decoupled the operating system further from specific hardware, splitting it into relocatable modules for easier customization. To promote adoption, Digital Research, founded by in 1974, adopted a licensing model that granted non-exclusive rights to hardware vendors for a fixed fee, such as the $25,000 paid by IMSAI for unlimited distribution with their 8080-based systems, and similar arrangements with MITS, the Altair 8800 creators. This approach enabled rapid proliferation on S-100 bus computers, as manufacturers could bundle CP/M without per-unit royalties, fostering a standardized software ecosystem for the hobbyist and professional markets.

Commercial Success and Evolution

CP/M achieved significant commercial success in the late 1970s as the dominant operating system for microcomputers, powering thousands of systems from manufacturers like IMSAI, Cromemco, and Osborne, and fostering a vibrant ecosystem of software applications due to its portability across 8080 and Z80-based hardware. In 1979, Digital Research released CP/M 2.0, which expanded the system's capabilities to include up to 16 user areas for segregating files into logical directories, directory labels for better organization, and enhanced console support for additional devices such as printers and modems, enabling more flexible multi-device environments. These improvements addressed limitations in earlier versions, allowing CP/M to scale with growing hardware complexity and contributing to its widespread adoption in business and hobbyist markets. In 1979, CP/M 2.2 further refined the system by introducing wildcard file matching with '?' and '*' characters for efficient file operations, improved error handling with more informative messages to aid troubleshooting, and support for disks up to 512 KB, accommodating larger storage media prevalent in emerging systems. This version solidified CP/M's position as the standard for 8-bit computing, with Digital Research licensing it to over 200 hardware vendors and supporting a library of more than 1,000 applications by the early 1980s. By 1983, CP/M 3.0 (also known as CP/M Plus) added advanced features like RAM disk support for virtual high-speed storage, date and time stamping on files for better record-keeping, and upgraded console drivers for compatibility with graphical and high-resolution displays, enhancing usability in professional settings. To address the shift toward 16-bit architectures, Digital Research introduced CP/M-86 in 1982, tailored for the Intel 8086 processor, which provided a larger 1 MB address space compared to the 64 KB limit of 8-bit CP/M and rudimentary concurrent execution capabilities for running multiple processes. Complementing this, multi-user variants emerged: MP/M in 1979 enabled shared access among multiple terminals on a single machine, ideal for small office networks, while MP/M-86 in 1983 extended these features to 16-bit systems for more robust multi-user environments. Additionally, in 1982, Richard Conn developed ZCPR (Z-80 CP/M), an open enhancement released through 1985, which replaced the standard Console Command Processor (CCP) with superior command parsing, support for aliases, and customizable macros, allowing users to tailor the interface without altering core system files. These evolutions extended CP/M's relevance into the mid-1980s, bridging 8-bit and 16-bit eras while maintaining backward compatibility.

Decline and Replacement

The introduction of the IBM Personal Computer in 1981 marked a pivotal shift in the personal computing landscape, with Microsoft securing the operating system contract and adapting 86-DOS into MS-DOS as the default OS. MS-DOS achieved backward compatibility with CP/M through mechanisms like File Control Blocks (FCBs) and the FAT file system, which drew conceptual inspiration from CP/M's directory structure and allocation methods, easing the transition for existing software and users. This bundling with IBM hardware rapidly propelled MS-DOS to dominance, as the IBM PC standard gained widespread adoption in business and consumer markets. Digital Research's response was hampered by delays in developing CP/M-86 for the Intel 8086/8088 architecture, with the version for the IBM PC not arriving until April 1982—several months after MS-DOS. Priced at approximately $240, CP/M-86 was significantly more expensive than MS-DOS at $40, deterring widespread adoption despite its advanced features. The company's failure to secure the IBM contract stemmed from a missed meeting in July 1981, where founder was unavailable due to a prior flying commitment, and subsequent negotiations faltered over nondisclosure agreement concerns. CP/M's market dominance in the early 1980s eroded quickly as hardware standardized on 16-bit x86 processors, sidelining the 8-bit Z80 architecture that CP/M primarily supported. By 1985, CP/M's share had dwindled to marginal levels amid the IBM PC-compatible surge, with MS-DOS capturing the majority of new installations. The last major release, CP/M-86 version 1.1 for the IBM PC, came in March 1983, adding hard drive support but failing to reverse the tide. Digital Research ceased active support for CP/M following its acquisition by Novell in July 1991 for $80 million, as the new parent prioritized network software over legacy systems. The decline orphaned thousands of CP/M applications, stranding a vast ecosystem of business software and forcing developers into costly porting efforts to MS-DOS or newer platforms. This transition disrupted productivity for users reliant on CP/M's specialized tools, contributing to economic losses estimated in the millions as companies migrated data and retrained staff, ultimately accelerating the standardization of the PC ecosystem.

System Architecture

Hardware Abstraction Model

CP/M achieves hardware portability through a layered abstraction model that isolates application software from underlying hardware variations. The system employs a three-layer architecture consisting of the Basic Disk Operating System (BDOS), the Basic Input/Output System (BIOS), and the application programs themselves. Application programs interact exclusively with the BDOS via standardized function calls, while the BDOS, in turn, invokes the BIOS for all hardware input/output operations, preventing direct hardware access by user software and ensuring compatibility across diverse systems. This design supports processors such as the Zilog Z80, Intel 8080, and 8085 for the original CP/M-80 variant, with later versions like CP/M-86 extending compatibility to the Intel 8086 and 80286. The BIOS layer handles machine-specific adaptations, allowing the BDOS and higher-level components to remain processor-agnostic and facilitating ports to new hardware without rewriting application code. Device independence is maintained through the BIOS, which provides uniform interfaces for peripherals including consoles, readers, printers, auxiliary I/O devices, and disks, implemented via a table of jump vectors that route calls to appropriate hardware routines. CP/M utilizes a 64 KB address space, with a fixed system area in high memory for the resident BIOS and BDOS, and the Transient Program Area (TPA) in low memory below for transient programs and the console command processor (CCP). During the boot process, a cold boot loads the BIOS and BDOS into the fixed high-memory region from ROM or disk, initializes the system, and then loads the CCP into the TPA to establish the command interface. A warm boot, invoked via a jump to the BIOS entry point, reloads only the CCP from disk while preserving the BIOS and BDOS in memory, enabling quick restarts without full reinitialization.

Core Components

CP/M's core components consist of three primary software modules: the Basic Input/Output System (BIOS), the Basic Disk Operating System (BDOS), and the Console Command Processor (CCP). These modules work together to provide a layered interface between user programs and hardware, ensuring portability across different systems. The BIOS handles low-level hardware interactions, the BDOS provides a standardized interface for disk and file operations, and the CCP serves as the interactive user interface. The BIOS is the lowest-level module, responsible for direct hardware control through low-level drivers for input/output operations, clock functions, and disk access. It implements 16 standard functions in CP/M version 2, accessed via a jump table in assembly code, including CONIN for console input (function 3) and SELDSK for selecting a disk drive (function 9). These functions abstract hardware specifics, such as serial I/O and sector reads/writes, allowing the rest of the system to operate independently of the underlying machine. The BDOS acts as the system call interface, offering a hardware-independent layer with 37 functions in CP/M 2.2 for managing file operations, console I/O, and other services. It handles tasks like opening and closing files (functions 15 and 16), sequential reads and writes (functions 20 and 21), and directory searches using the File Control Block (FCB), a 36-byte structure passed as a parameter for file references. Programs invoke BDOS functions in 8-bit CP/M via assembly instructions such as LD C, function_number; CALL 5, with parameters in DE. The BDOS, in turn, calls the BIOS through jumps to its function table for hardware execution. The CCP functions as the user shell, processing console input to parse commands, execute programs, and manage resident interface programs (RIPs) that extend system functionality without reloading the full CCP. It displays the current drive prompt (e.g., A>) and invokes BDOS calls to load and run transient programs from disk into the Transient Program Area (TPA). Unlike the BIOS, the CCP is standardized and not modified by OEMs. OEMs customize the BIOS to accommodate specific hardware configurations, such as disk controllers or console devices, while the BDOS and CCP remain unchanged across implementations to ensure compatibility. These components reside in the upper memory regions, typically above the 48 KB TPA, with the BIOS at the highest addresses.

Memory Layout

CP/M organizes its 64 KB memory space into a fixed high-memory system area for resident operating system components and a larger Transient Program Area (TPA) in low memory for user programs, ensuring compatibility across diverse 8-bit hardware while maximizing available space for applications. The fixed system area, located in the highest portion of memory, typically consumes around 5 KB, encompassing the core modules and essential buffers; this leaves approximately 48-56 KB for the TPA, depending on the specific system configuration and buffer allocations during installation. The Basic Input/Output System (BIOS) resides in the highest memory addresses, generally occupying 256-512 bytes to provide hardware-specific interfaces while remaining protected from user code overlays. Immediately below the BIOS lies the Basic Disk Operating System (BDOS), spanning 2-3 KB and managing file operations, console I/O, and auxiliary services through standardized calls. The Console Command Processor (CCP) follows the BDOS, using about 2 KB to handle user commands and interface with the BDOS; a dedicated directory buffer of 128 bytes is also positioned within this system area for file directory caching. Positioned between the BDOS and TPA are 7 disk buffers totaling 896 bytes, facilitating efficient data transfers from storage devices without intruding into program space. The TPA begins at fixed address 0x100 (256 decimal) and extends upward to the upper limit of available RAM, enabling straightforward loading of user programs as .COM files that originate at this address. Relocation is static, with programs compiled using ORG 0x100 and relying on absolute addressing rather than dynamic memory allocation, which simplifies development but limits flexibility to the TPA's boundaries. In contrast, CP/M-86, the 16-bit adaptation for the Intel 8086 processor, employs a segmented memory architecture to support up to 1 MB of addressable space, expanding the TPA significantly beyond the 64 KB constraint of 8-bit systems while maintaining backward compatibility for many CP/M-80 applications through emulation layers.

Software Environment

Command Processing

The Console Command Processor (CCP) provides the primary user interface in CP/M, displaying a prompt such as A> to indicate the current default drive and readiness for command input. Commands are entered as up to 4-character names followed by optional arguments, file specifications in the form [drive:]filename[.type], and support for input/output redirection, such as TYPE file > PRN to output a file's contents to the printer device. File names are limited to 1-8 alphanumeric characters for the base name and 0-3 for the type, with wildcards like ? for single characters or ***** for multiple, enabling flexible specifications like *DIR .ASM. CP/M's built-in commands, embedded directly in the CCP for immediate execution without disk access, handle common operations such as file management and system control. The ERA command deletes specified files, prompting for confirmation if wildcards match multiple files (e.g., ERA . All files (Y/N)?). SAVE writes the contents of the Transient Program Area (TPA) to a disk file in 256-byte pages (e.g., SAVE 10 X.COM to save 10 pages as X.COM). DIR lists directory entries for files matching a specification (e.g., DIR B:*.TXT), showing names, types, and extent counts. USER switches between user areas (0-15) to access separate file sets (e.g., USER 1). Other built-ins like TYPE display ASCII file contents and REN rename files (e.g., REN OLD.TXT=NEW.TXT). If the CCP encounters an unrecognized command or file, it displays the error message "Bad command or file name" and returns to the prompt. Appending ? to a built-in command keyword provides usage help, such as ERA? explaining syntax and options. For extended functionality, Resident Interface Programs (RIPs) can be loaded into memory immediately after the CCP to augment the interface, such as SUBMIT.COM, which processes batch files containing sequences of commands stored as $$$.SUB. Later third-party enhancements like ZCPR, a replacement for the CCP developed in the early 1980s, introduced features such as menu-driven interfaces, command history recall, and programmable aliases to improve usability over the standard CP/M shell.

Program Execution

In CP/M, user programs are typically distributed as .COM files, which are flat binary executables containing machine code without relocation information. These files are loaded directly into the Transient Program Area (TPA), starting at memory address 0x0100, by the Console Command Processor (CCP). The TPA extends upward from this base address until it reaches the bottom of the resident system area, allowing programs to utilize available RAM above the first 256 bytes reserved for system buffers. The execution of a .COM file begins when the CCP parses a command line entered by the user, identifies it as a transient program request, and invokes Basic Disk Operating System (BDOS) functions to open the specified file on disk. The BDOS then reads the file contents sequentially into the TPA, overwriting any previous transient program data. Once loaded, control transfers to the program at address 0x0100 via a direct jump instruction from the CCP, enabling the program to execute while accessing system services through BDOS calls at entry point 0x0005. Upon completion, the program typically returns control to the CCP by invoking BDOS function 0, which performs a warm boot and reloads the CCP if it has been overlaid. CP/M distinguishes between transient and resident programs to manage memory efficiently. Transient programs, the standard for most applications, fully occupy and overwrite the TPA during execution, requiring reloading from disk for subsequent runs. In contrast, resident programs, known as Resident Interface Programs (RIPs) in later implementations, are loaded into the fixed memory region between the BDOS and the CCP, allowing them to persist across transient executions without reloading. This design enables RIPs to provide ongoing services, such as extended command processing, but limits their size to the available space in that region. CP/M's memory management lacks hardware protection mechanisms, relying instead on programmer discipline to avoid corrupting the system area above the TPA. A transient program can inadvertently or maliciously overwrite the BDOS, BIOS, or CCP by accessing addresses beyond its allocated TPA bounds, potentially causing system instability or crashes without any enforcement by the operating system. This absence of isolation made robust error handling essential for reliable software operation. For automated execution of multiple commands, CP/M supports batch processing via the SUBMIT command, which reads a text file with a .SUB extension containing sequential command lines. The CCP processes each line as if entered interactively, substituting parameters from the original SUBMIT invocation where indicated by special markers like $?, allowing chained execution of transients or built-ins without manual intervention. This facility streamlined repetitive tasks but required careful file formatting to handle errors and pauses.

Development and Utilities

Development under CP/M relied on a suite of command-line tools provided by Digital Research for assembling, linking, debugging, and managing programs, primarily targeted at 8080 and Z80 processors. The MAC macro assembler was the primary tool for translating assembly language source code into executable formats, supporting macro definitions for code reuse and generating either .COM files for direct memory loading or .HEX files for Intel hexadecimal output suitable for PROM programming or transfer. MAC operated via the console command processor (CCP), processing input files with options for listing and symbol tables, and was upward compatible with the earlier non-macro ASM assembler. Debugging was facilitated by the Dynamic Debugging Tool (DDT), an interactive resident debugger that loaded programs into memory for examination and modification. DDT enabled memory inspection through display commands, setting breakpoints at specific addresses, and single-step execution to trace program flow, making it essential for resolving issues in assembly-language code. Invoked as "DDT filename.COM," it overlaid the target program while preserving the CP/M environment, allowing patches via inline assembly and disassembly for analysis. Linking and utility programs supported modular development and system maintenance. The LINK-80 utility combined multiple relocatable object files (.REL) produced by MAC into a single executable, resolving external references and supporting overlays for larger programs exceeding memory limits. STAT provided statistical information on files, such as allocation details and timestamps, and on devices like disk drives, aiding in resource management without altering data. The Peripheral Interchange Program (PIP) handled file copying between disks, devices, and even console input/output, using syntax like "PIP dest=src" for transfers, formatting, and verification, serving as a foundational tool for data movement. Software installation in CP/M involved manual distribution on floppy disks, with users employing CCP commands such as PIP to copy files from distribution media to system or user areas, followed by potential reconfiguration via utilities like STAT for drive assignments. No automated installers existed; setup required explicit commands to populate directories and verify integrity, often documented in accompanying manuals for each application. Third-party development tools expanded CP/M's ecosystem, with notable examples including Microsoft's MBASIC interpreter, which provided an interactive BASIC environment for rapid prototyping and scripting, supporting structured programming features like subroutines and file I/O. Applications like MicroPro's WordStar word processor and Ashton-Tate's dBASE II database system were developed using these tools, leveraging CP/M's BDOS for file operations while offering domain-specific interfaces for text editing and data management.

File System and Storage

Disk Organization

CP/M supports up to 16 disk drives, designated by the letters A through P, allowing users to organize storage across multiple volumes without built-in partitioning mechanisms. Each disk typically follows a fixed physical layout optimized for 8-inch single-sided single-density (SSSD) floppy media, consisting of 77 tracks with 26 sectors per track, where each sector holds 128 bytes of data. Tracks 0 and 1 are reserved for the system image: track 0 sector 1 contains the boot loader, with the rest of tracks 0 and 1 holding the CCP, BDOS, and BIOS necessary for loading the full CP/M image. The directory is located starting at track 2, typically occupying the first 16 sectors for 64 entries. In CP/M 1.x, the directory accommodates up to 64 entries, each 32 bytes long, providing basic file metadata storage. CP/M 2.x supports up to 256 entries in some configurations but uses 64 entries in the standard 8-inch SSSD setup, while maintaining the same physical sector allocation principles for the directory. Allocation of storage space occurs at the block level, with block sizes of 128 bytes, 256 bytes, 512 bytes, or 1 KB, and a maximum of 512 blocks per disk; the system employs a bitmap—known as the allocation vector (ALV)—derived from directory entries and maintained in memory to track free and used blocks, rather than storing it persistently on disk. This bitmap approach facilitates efficient space management by marking blocks as available or occupied based on file extent pointers in the directory. Disks are formatted using the FORMAT utility, which initializes the tracks, clears the directory, and sets up the reserved areas without support for partitioning, ensuring a uniform volume structure across drives. CP/M Plus introduces enhancements for larger disks, supporting capacities up to 1 MB through configurable disk parameter blocks that allow for increased tracks and sectors, along with sector skewing techniques to optimize access times by rearranging sector order for faster sequential reads. These improvements maintain backward compatibility while addressing limitations of earlier versions on higher-density media.

File Handling

File handling in CP/M is mediated through the File Control Block (FCB), a fixed 36-byte data structure that serves as the primary interface for all file operations. The FCB includes a 1-byte drive specifier (defaulting to 0 for the current drive), an 8-byte filename field padded with spaces, a 3-byte extension (filetype) field also space-padded, a 1-byte extent number (offset 12) for the current 16 KB extent (with larger files using multiple directory entries), and the remaining bytes dedicated to record count, a 16-byte allocation map for data blocks, current record, and random record fields. User access is controlled via the BDOS user login function (32), with the user number stored in the directory entry status byte rather than the FCB. This structure ensures consistent, low-level access to file metadata without higher-level abstractions like paths. The Basic Disk Operating System (BDOS) provides a set of standardized functions for manipulating files via the FCB, invoked through software interrupts. Key operations include OPEN (function 15), which validates and initializes the FCB for an existing file by parsing its fields and returning a file descriptor (0xFF for success); CREATE (function 22), which allocates a new directory entry and clears the FCB's allocation map; DELETE (function 19), which marks the file's directory entries as unused after confirmation; READ (function 20) and WRITE (function 21), each transferring one 128-byte logical record sequentially from or to the file, with the FCB's random record field enabling positioned access in extended modes; and CLOSE (function 16), which updates the directory with the final record count and releases resources. These functions enforce sequential access as the default, limiting random seeks to applications that manually manage the FCB's record pointer, and all operations require the FCB to be passed by address in the DE register (8-bit CP/M) or DX (16-bit variants). To support multi-user environments and file organization, CP/M implements 16 isolated user areas (numbered 0 through 15) per disk drive, where the current user number determines visibility and access—files created under one user number are inaccessible to others without explicit switching via the BDOS user login function (function 32). This mechanism logically partitions the shared directory into private spaces, enabling file separation without physical duplication, though cross-user operations like copying require utilities that temporarily adjust the current user context. The total directory supports up to 64 (or 256 in some configurations) files across all users combined, with entries segregated by user number. Filename conventions in CP/M adhere to an 8.3 format, with the first 8 characters for the name and the next 3 for the extension, both uppercase and space-padded, separated implicitly without a visible dot in storage but represented as "FILE.TXT" in commands. Wildcard support facilitates bulk operations: the '?' character matches any single position in the name or extension, while '' fills the remainder of the field with implicit question marks, allowing patterns like "A?B." to select files such as "AXB.TXT" during directory searches or utility invocations. The BDOS parses these in the FCB during functions like OPEN or CREATE, expanding them to specific matches. Despite its simplicity, the file system imposes notable limitations: it lacks support for subdirectories, relying solely on user areas for hierarchy; the total directory size limits the combined number of files across users; and files are created as read-write by default, though system files may carry read-only attributes set in the directory entry, typically via utilities like STAT. These constraints prioritize efficiency on limited hardware but restrict scalability for larger file collections.

Extensions and Capabilities

Multi-user and Networking

MP/M, introduced by Digital Research in 1979, extended the single-user CP/M operating system to support multi-user environments on a single CPU. Developed by engineer Tom Rolander, it enabled console sharing among multiple terminals, with support for up to 16 user stations connected via serial interfaces, allowing concurrent program execution and resource access. The system incorporated message passing capabilities for inter-user communication and utilized the same Basic Disk Operating System (BDOS) as CP/M to maintain compatibility with existing applications. Resource sharing in MP/M focused on central peripherals like disks and printers, managed through the Basic Input/Output System (BIOS) for console multiplexing, while lacking native file locking mechanisms that could lead to data corruption in concurrent writes. Networking was rudimentary, limited primarily to serial links between systems, with no built-in support for Ethernet or TCP/IP protocols. The architecture relied on non-preemptive multitasking, where users voluntarily yielded control, and all operations occurred on a single processor without dynamic memory partitioning. In 1981, Digital Research released MP/M-86, a 16-bit evolution targeting Intel 8086-based systems, introducing dynamic partitioning for memory allocation and enhanced multi-tasking for up to 16 concurrent processes. It included network support through an integrated NET server for resource sharing across linked machines, building on MP/M's foundation but extending compatibility to CP/M-86 applications. Third-party implementations later added Ethernet connectivity, such as adaptations for serial-to-Ethernet bridges, though native networking remained proprietary and non-standardized without TCP/IP. In 1982, Digital Research released Concurrent CP/M-86, which incorporated preemptive multitasking, improved resource management, and basic graphical user interface elements like windowing for multiple sessions, addressing many of MP/M's limitations while preserving backward compatibility, with version 3.1 following in 1984. CP/NET, released in 1981, provided a dedicated networking layer for CP/M systems, enabling distributed file and printer sharing over serial or custom links using a proprietary protocol, without support for modern internet standards.

Graphics and Peripherals

CP/M in its core form provided only text-based output through an 80-column by 24-row console managed by the Basic Input/Output System (BIOS), lacking any native support for graphical interfaces or advanced display modes. This design prioritized compatibility across diverse 8-bit hardware, such as Zilog Z80-based systems, where graphics capabilities were hardware-dependent and not abstracted by the operating system. To address the need for graphics, Digital Research introduced the Graphics System eXtension (GSX) in 1983 as an optional add-on for CP/M-80 and CP/M-86, enabling device-independent vector and bitmapped graphics. GSX consisted of a core library (GDOS, or Graphics Device Operating System) loaded as GSX.SYS, paired with hardware-specific input/output system (GIOS) drivers for devices like monitors, plotters, and dot-matrix printers. It supported features such as line drawing, filled polygons, text rendering in multiple fonts, and basic windowing for menus, allowing applications to produce consistent output across supported hardware without direct device programming. For instance, on systems like the IBM PC, GSX facilitated resolutions up to the hardware's limits, such as 640x200 pixels in color modes when paired with appropriate adapters. In CP/M Plus (version 3.0, released in 1983), GDOS was integrated more natively, extending graphics support to vector-based plotting and printer output, which enabled early computer-aided design (CAD) tools and charting software. Applications leveraging these extensions included Digital Research's Graph utility for bar and pie charts, as well as ports of AutoCAD that utilized GSX for rudimentary 2D drafting on supported peripherals like Epson dot-matrix printers. However, graphics remained constrained by era-specific hardware, with no support for modern interfaces like USB and resolutions typically capped at 80x25 characters for text or low-resolution bitmaps for graphics. Beyond displays, CP/M handled peripherals through customizable BIOS routines, requiring system integrators to modify the low-level I/O code for non-standard devices such as modems, joysticks, or hard disk controllers. For example, implementations on systems like the Commodore 64 included tailored BIOS entries to interface with serial ports for modems or custom storage, ensuring compatibility without altering the core operating system. This approach allowed flexibility for peripherals like RS-232 serial devices but demanded hardware-specific adaptations, as CP/M provided no dynamic driver loading mechanism in early versions.

Derivatives

Official Variants

Digital Research developed several official variants of CP/M to extend its functionality across different hardware architectures, support multitasking and multi-user environments, and enable networking capabilities, all while maintaining core compatibility principles. These variants were designed to leverage the original CP/M's modular structure, allowing adaptations for 16-bit processors and specialized applications without abandoning the 8-bit ecosystem's software base. Official documentation consistently highlighted backward compatibility, enabling many CP/M-80 applications to run on newer platforms through emulation or direct support mechanisms. CP/M-86, released in 1981, represented Digital Research's first major 16-bit adaptation of CP/M for Intel 8086 and 8088 processors, providing a single-user, single-task environment with enhanced memory addressing up to 1 MB. It preserved the CP/M interface, including the BDOS and CCP components, to ensure familiarity for developers and users migrating from 8-bit systems. The system supported segmented memory models aligned with the 8086 architecture and included utilities like PIP for file transfers, emphasizing portability across Intel-based hardware. Official manuals underscored its role as a bridge to 16-bit computing while allowing recompilation of 8080/Z80 code for native execution. MP/M-86, introduced alongside CP/M-86 in 1981, extended the platform to multi-user operations on 8086 systems, supporting up to four concurrent users with shared access to peripherals and files. It built on CP/M-86's foundation by incorporating a master console for system management and user-specific consoles, with features like dynamic resource allocation and console queuing for I/O operations. This variant maintained backward compatibility with CP/M-86 applications, allowing them to run under user sessions, and was distributed with source code for custom hardware integration. Documentation positioned MP/M-86 as an enterprise-oriented evolution, suitable for shared computing environments without requiring full reprogramming. Concurrent CP/M-86, launched in 1983, advanced multitasking on 8086/8088 platforms by introducing virtual consoles—up to four simultaneous sessions—that enabled window-like task switching and background processing. It supported both dynamic (interactive) and buffered (batch) modes for concurrent execution of CP/M-86 programs, with utilities such as VCMODE for console management and enhanced password protection for multi-user security. Unlike earlier single-task variants, it allowed seamless integration of foreground editing, printing, and computation, while ensuring compatibility with existing CP/M-86 binaries through a unified file system. The system's design emphasized productivity gains, with official guides noting its adaptation for IBM PC compatibility and 8087 coprocessor support. In 1982, Digital Research released CP/M-68K for the Motorola 68000 processor, targeting 16/32-bit systems like early workstations and providing a single-user OS with relocatable code segments and up to 64 KB TPA expansion via banking. This port retained CP/M's command structure and file handling, supporting 8-bit application emulation through software interpreters where needed, and was written partly in Pascal for portability. It included development tools like the L068 linker and emphasized hardware abstraction for custom 68000-based machines, as detailed in programmer guides that stressed seamless transitions from Z80 environments. CP/NET, introduced in 1981, served as Digital Research's official networking extension for CP/M and MP/M systems, enabling shared access to peripherals, disks, and programs across microcomputer clusters via serial or custom links. It operated transparently under host CP/M instances, using SNIOS modules for network I/O and supporting configurations from simple peer-to-peer to star topologies with a dedicated file server. The system provided logical network independence from physical hardware, with error handling and function extensions like remote file operations, while preserving CP/M compatibility for networked applications. Official references highlighted its role in resource sharing for cost-effective multi-machine setups. Following Digital Research's acquisition by Novell in 1991, CP/M saw continued official support through integration with NetWare environments, with final enhancements to CP/M 3.0—a 1982 Z80 variant featuring banked memory for up to 1 MB addressing, time-stamping, and improved console I/O—released for legacy systems. CP/M 3.0 maintained full upward compatibility with CP/M 2.2 software and added features like directory hashing for faster access, as outlined in system guides distributed post-acquisition. Novell's stewardship focused on embedding CP/M elements into network products, ensuring backward compatibility for 8-bit applications in enterprise settings until the mid-1990s.

Compatible Implementations

86-DOS, developed in 1980 by Tim Paterson at Seattle Computer Products, was an early third-party implementation designed for 8086-based S-100 bus systems and served as a CP/M-compatible operating system for the 16-bit processor. It replicated key CP/M elements, including the file control block (FCB) structure for file operations and similar application programming interfaces (APIs), allowing many CP/M-80 programs to be adapted with minimal changes. This compatibility stemmed from Paterson's use of the CP/M manual as a reference, making 86-DOS a functional clone that addressed the delay in Digital Research's CP/M-86 release. Later, Microsoft licensed and modified 86-DOS into MS-DOS for the IBM PC, extending its influence on PC-compatible software ecosystems. DR-DOS, introduced in 1988 by Digital Research, built directly on the foundations of CP/M-86 while adding full MS-DOS compatibility to broaden its appeal on IBM PC compatibles. As a descendant of CP/M, it retained core CP/M APIs and file handling mechanisms, enabling execution of legacy CP/M-86 applications alongside DOS software through integrated emulation and compatibility layers. This evolution allowed DR-DOS to compete in the DOS-dominated market while preserving access to the extensive CP/M software library. In embedded and specialized environments, operating systems like ROM-DOS from DataLight and PTS-DOS from Personal Telematic Systems provided MS-DOS compatibility, targeting resource-constrained devices such as industrial controllers and point-of-sale terminals. ROM-DOS, optimized for ROM-based booting, supported file formats and basic API calls, facilitating legacy software migration in embedded systems. Similarly, PTS-DOS aided transitions from older environments to 16-bit embedded applications. Behind the Iron Curtain, East German implementations included MicroDOS, a CP/M clone developed in the 1980s for Z80-based Kleincomputer (KC) series machines like the KC85/3. MicroDOS mirrored CP/M's basic disk operating system (BDOS) and console functions, enabling the execution of standard CP/M-80 software on locally produced hardware amid restricted access to Western imports. This clone supported floppy disk operations and program loading compatible with CP/M 2.2, promoting software portability within the Eastern Bloc's constrained computing ecosystem. Soviet-influenced variants in Czechoslovakia featured the Didaktik M, an educational computer from the early 1990s that ran CP/J, a modified CP/M implementation tailored for classroom use. CP/J extended CP/M with networking capabilities via the JUNET protocol for multi-user sessions, allowing shared access to educational CP/M programs across linked Didaktik machines in schools. This adaptation emphasized CP/M's file system and command structure while adding pedagogical features like simplified multi-terminal support, making it suitable for informatics education under resource limitations.

Modern Recreations

In recent years, hobbyist developers have created new implementations of CP/M to preserve and extend its functionality on modern hardware, focusing on compatibility with original software while incorporating enhancements for contemporary use. LokiOS, introduced in 2023, is a from-scratch reimplementation of CP/M 2.2 designed for Z80 processors, maintaining full binary compatibility with legacy programs through features like "Memory As Disk" for efficient memory management. Developed collaboratively by enthusiasts on the Vintage Computer Federation (VCFed) forums, it supports modern storage options beyond traditional floppy disks, enabling larger virtual drives suitable for archiving extensive software collections. Emulation projects have also advanced, with ongoing efforts like a JavaScript-based browser emulator developed by Retro Game Coders providing simulation of CP/M environments to run original applications without dedicated hardware. Complementing this, Z80pack serves as a versatile simulator for Z80 and 8080 systems on personal computers, emulating CP/M 2.2 and 3.0 alongside specific hardware like the IMSAI 8080, allowing seamless execution of vintage software on Linux, Windows, or macOS platforms. These tools emphasize high-fidelity reproduction of CP/M's basic disk operating system (BDOS) and BIOS calls, facilitating testing and preservation of period-specific programs. Open-source ports have brought CP/M to affordable single-board computers, such as implementations on the Raspberry Pi using the SIMH emulator to simulate Z80-based systems like the Altair 8800, enabling users to boot and interact with CP/M distributions directly on ARM hardware. Numerous GitHub repositories host recreations of CP/M BIOS code, tailored for custom Z80 boards or microcontrollers, including variants for the RC2014 platform and Raspberry Pi Pico that adapt the original BIOS to support SD card storage and serial interfaces while preserving core CP/M APIs. These ports prioritize modularity, allowing developers to integrate CP/M into embedded projects without altering the underlying 8-bit architecture. Recent educational initiatives have highlighted these recreations for learning purposes. The EerieLinux blog series, starting in late 2024, explores CP/M's internals through hands-on emulation tutorials, covering setup on modern systems and dissection of its file system and command structure to bridge historical computing with current practices. In 2025, OSNews published an introduction to CP/M that underscores emulation's role in education, demonstrating how tools like Z80pack and SIMH allow newcomers to experience the OS's influence on early software development without vintage hardware. The VCFed community continues to drive these efforts through forums dedicated to compatibility testing, where members validate recreations against original disk images and share archived CP/M distributions to ensure long-term accessibility.

Legacy

Influence on Operating Systems

CP/M exerted significant influence on the design of subsequent operating systems, particularly MS-DOS, by establishing foundational elements of the microcomputer OS model. Its Basic Disk Operating System (BDOS) provided a standardized interface that MS-DOS emulated through Interrupt 21h (INT 21h) calls, where functions 00h to 24h largely mirrored CP/M's BDOS equivalents for tasks like file I/O and console operations. This API compatibility, including the use of File Control Blocks (FCBs) for file handling, facilitated straightforward porting of applications between systems. Additionally, CP/M's convention of 8.3 filenames—eight characters for the name and three for the extension—became a hallmark of MS-DOS, optimizing for limited storage while maintaining readability. Drive letter designations, such as A: and B: for primary and secondary storage devices, were directly adopted from CP/M's user-friendly disk referencing scheme, simplifying multi-drive management in early PCs. The file system architecture of CP/M also shaped MS-DOS's early implementations. CP/M employed a simple block allocation method via a directory-based map, allocating fixed-size blocks (typically 128-byte records) without hierarchical directories, a structure echoed in the initial versions of MS-DOS's File Allocation Table (FAT). FAT, while introducing cluster-based allocation for efficiency on larger media, derived its core concept of sequential block chaining and extent handling from CP/M's approach, ensuring no subdirectories in base MS-DOS until version 2.0 added them in 1983. This similarity allowed MS-DOS to support CP/M-formatted disks and files natively in early releases, promoting interoperability. Command-line utilities further reflected this heritage: MS-DOS's DIR command for listing files paralleled CP/M's DIR, while COPY evolved from CP/M's PIP (Peripheral Interchange Program) for file transfers. Batch processing, via MS-DOS .BAT files, built on CP/M's SUBMIT utility, which executed sequential commands from text files, enabling automated workflows. Beyond technical specifics, CP/M standardized the microcomputer operating system paradigm, fostering software portability across diverse hardware and enabling a vast ecosystem of applications. By providing a hardware-agnostic layer through its BIOS, BDOS, and CCP components, CP/M supported thousands of programs—such as WordStar, dBase, and SuperCalc—that were readily ported to MS-DOS due to architectural parallels, accelerating the IBM PC's software adoption. This portability contributed to over a million CP/M installations by the mid-1980s, setting the stage for MS-DOS's dominance. CP/M's emphasis on a concise command-line interface inspired the simplicity of early PC environments, blending minicomputer efficiency with accessibility. In recognition of these innovations, particularly in disk-based OS design, CP/M received an IEEE Milestone award in 2019.

Preservation and Emulation

Efforts to preserve CP/M have centered on archiving software and disk images to combat physical degradation and obsolescence. The Internet Archive hosts extensive collections, such as the Humongous CP/M Archive Collection, which includes thousands of .TAR files containing disk images, web rips, and software from various CP/M systems dating back to the 1970s and 1980s. Similarly, the TOSEC project maintains comprehensive dumps of CP/M software, integrated into its broader retro software catalog available on the Internet Archive, ensuring verifiable preservation of original binaries and ensuring compatibility verification through DAT files. Emulation has been crucial for running preserved CP/M software without original hardware. The SIMH simulator, originally developed in the 1970s and actively maintained through the 2020s via its GitHub repository, provides full system simulation for CP/M environments, including Altair 8800 and other Z80-based machines, allowing users to boot disk images and execute applications with high fidelity. For variants on non-Z80 architectures like the Tandy Color Computer (CoCo) and Dragon systems, which supported CP/M through specific ports or extensions, emulators such as XRoar enable accurate reproduction of these 6809-based setups, including cartridge and disk support for compatible software. Hardware revival projects recreate CP/M-compatible systems using modern components to extend usability. The RC2014 platform offers modular Z80 kits, such as the Pro CPM Kit, which run CP/M 2.2 at 7.3728 MHz with 64 KB RAM and support for CompactFlash storage, allowing enthusiasts to assemble and boot original software on new hardware. FPGA-based implementations, like the MultiComp core ported to the MiSTer platform, simulate multiple Z80 systems including CP/M, providing cycle-accurate execution via SDRAM and SD card image loading for preserved disks. Preservation faces significant challenges from physical media decay and format variability. Disk rot affects floppy media used in CP/M systems, leading to data loss over decades due to oxidation and environmental factors, while proprietary or implementation-specific disk formats—such as those varying by controller without standardized parameters—complicate imaging and transfer. Solutions include emulators like those for the TRS-80, which handle LDOS and NEWDOS formats alongside CP/M, enabling extraction and simulation of affected disks, and S-100 bus recreations that replicate original interfaces for direct hardware readout. In educational contexts, CP/M preservation supports teaching operating system history through accessible tools. Tutorials published in 2025 on OSNews and related blogs introduce CP/M concepts for modern learners, emphasizing its role in early computing via emulated environments to demonstrate file systems and command interfaces. Projects like LokiOS provide hands-on compatibility by offering a from-scratch CP/M 2.2 recreation for experimentation on contemporary hardware.

References

Add your contribution
Related Hubs
User Avatar
No comments yet.