OS-9

From Wikipedia, the free encyclopedia

For the Macintosh operating system, see Mac OS 9.

OS-9 is a family of real-time, process-based, multitasking, multi-user, Unix-like operating systems, developed in the 1980s, originally by Microware Systems Corporation for the Motorola 6809 microprocessor. It is currently owned by RadiSys Corporation.

The OS-9 family was popular for general-purpose computing and remains in use in commercial embedded systems and amongst hobbyists. Today, OS-9 is a product name used by both a Motorola 68000-series machine language OS and a portable (PowerPC, x86, etc.) version written in C, originally known as OS-9000.

Contents

[edit] History

The first version ("OS-9 Level One") , which dates back to 1979-80, was written in assembly language for the Motorola 6809 CPU, and provided a single 64KB address space in which all processes ran. It was developed as a supporting operating system for the BASIC09 project, contracted for by Motorola as part of the 6809 development. A later 6809 version ("Level Two") takes advantage of memory mapping hardware, supported up to 2MB of memory (ca 1980) in most implementations, included a GUI on some platforms, and so on.

In 1983, OS-9/6809 was ported to Motorola 68000 assembly language and extended (called OS-9/68K); and a still later (1989) version was rewritten mostly in C for further portability. The portable version was initially called OS-9000 and was released for 80386 PC systems around 1989, then ported to PowerPC around 1995. These later versions lack the memory mapping facilities of OS-9/6809 Level Two simply because they do not need them. They used a single flat address space that all processes share; memory mapping hardware, if present, is mostly used to ensure that processes access only that memory they have the right to access. The 680x0 and 80386 (and later) MPUs all directly support far more than 1MB of memory in any case.

As a consequence of early pervasive design decisions reflecting the easily used reentrant code capabilities of the 6809 processor, programs intended for OS-9 use reentrant code exclusively. OS-9 also uses position independent code and data because the 6809 also supported it directly. The OS-9 kernel loads programs (including shared code), and allocates data, wherever sufficient free space is available in the memory map. This allows the entire OS and all applications to be placed in ROM or Flash memory, and eases memory management requirements when programs are loaded into RAM and run. Programs, device drivers, and I/O managers under OS-9 are all 'modules' and can be dynamically loaded and unloaded (subject to link counts) as needed.

OS-9/6809 ran on Motorola EXORbus systems using the Motorola 6809, SS-50 and SS-50C bus systems from companies such as SWTPC, Tano, Gimix, Midwest Scientific, and Smoke Signal Broadcasting, STD-bus 6809 systems from several suppliers, personal computers such as the Fujitsu FM-7 and FM-77, and many others.

Nitros-9 for the Tandy_Color_Computer 3
Nitros-9 for the Tandy_Color_Computer 3

The best known hardware (due to its low price and broad distribution) was the TRS-80 Color Computer (CoCo) and its clones such as the British Dragon series. Even on the CoCo, a quite minimalist hardware platform, it was possible under OS-9/6809 Level One to have more than one interactive user running concurrently (eg, one on the console keyboard, another in the background, and perhaps a third interactively via a serial connection) as well as several other non-interactive processes. The major limitations (in both access time and maximum capacity) is that no mass storage other than floppy disk were supported by Radio Shack, nor did Radio shack ever release a version of the CoCo with better hardware (ie, more hardware resources). Hard disks were only available from 3rd party sources. Radio Shack continued to emphasize the games orientation for the machine until it was discontinued.

On a computer like an SS-50 machines (eg, those from Gimix, Sourthwest Technical Products, etc), which had more memory, and I/O controllers that did not load the CPU as did the CoCo, multiple users were common, even with only 64KB of RAM (ie, Level One). With hardware supporting memory management circuits (ie, address translation) and OS-9 Level 2, GUI use was successfully routine, even on the minimal resourced CoCo. This was several years prior to successful GUIs on the 16-bit IBM PC class machines, and many years prior to properly working multi-tasking, multi-user, access-controlled operating systems on IBM PC type machines or on any of Apple's machines.

OS-9's multi-user and multi-tasking capabilities make it usable as a general-purpose interactive computer system. Many third-party interactive applications have been written for it, such as the Dynacalc spreadsheet, the VED text formatter, and the Stylograph and Screditor-3 WYSIWYG word processors. TSC's nroff emulating formatter was ported to OS-9 by MicroWay, as well.

In 1999, nineteen years after the first release of OS-9, Apple Computer released Mac OS 9. Microware sued Apple that year for trademark infringement, but a judge rejected the claim, dismissing the suit in the following year. The judge said that there is little chance for confusion, but one still periodically finds postings to the news://comp.os.os9 newsgroup from Macintosh users who are, at the very least, confused about the purpose of that group.

[edit] Comparisons with Unix

OS-9's notion of processes and I/O paths is quite similar to that of Unix in nearly all respects, but there are some significant differences:

  • The file system is not a single tree, but instead is a forest with each tree corresponding to a device.
  • OS-9 does not have a Unix-style fork() system call--instead it has a system call which creates a process running a specified program, performing much the same function as a fork-exec or a spawn.
  • OS-9 processes keep track of two "current directories" rather than just one; the "current execution directory" is where it will by default look first to load programs to run (which is of course similar to the use of PATH environment variable under UNIX).
  • OS-9 has had a modular design from the beginning, influenced by notions of the designers of the 6809 and how they expected software would be distributed in the future (see the three-part series of articles in Jan-Mar 1979 Byte by Terry Ritter, et al of Motorola who designed the CPU).
The module structure requires more explanation:
  • OS-9 keeps a "module directory", a memory-resident list of all modules that are in memory either by having been loaded, or by having been found in ROM during an initial scan at boot time.
  • When one types a command to the OS-9 shell, it will look first in the current module directory for a module of the specified name and will use it (and increase its link count) if found, or it will look on disk for an appropriately named file if not.
  • In OS-9/6809 and OS-9/68000, the module directory is flat, but OS-9000 made the module directory tree-structured. The OS-9000 shell looks in one's alternate module directory for a MODPATH environment variable, analogous to the PATH variable in all versions, indicating the sequence of module directories in which to look for pre-loaded modules.
  • Modules are not only used to hold programs, but can also be created on the fly to hold data, and are the way in which OS-9 supports shared memory.
  • OS-9/non-68000 supports POSIX threads. A single process can start any number of threads.

[edit] 21st century uses

  • Versions of OS-9/68K run on a wide variety of 68000 family platforms, including the Sharp X68000 in Japan, some personal computers intended by their designers as upgrades from the Color Computer (e.g., the 68070 and 68340-based MM/1, and on other computers from Frank Hogg Laboratories, PEP, and Delmar Co.) It was also ported to the Atari ST by Recc-o-ware in the early 1990s, and was distributed by Cumana in Europe. A port to the Amiga is also purported to exist.
  • OS-9/68K is also found in some embedded applications, including the Quanta Delta television broadcast character generator, still in production by ScanLine Technologies in Utah. While the user-level interface code on this system started at boot time, there was a hidden, undocumented keyboard sequence that would provide a user with a root shell prompt in a scroll window on the device's edit-channel monitor.
  • In the embedded market, where OS-9 has found application in such devices as the Fairlight CMI synthesizers, robotics, in-car navigation systems, and Philips' Compact Disc-Interactive (CD-i) industry standard.
  • The TRS-80 Color Computer (and clones) still has users and an annual conference in Chicago; as of 2005 the 15th Annual "Last" Chicago CoCoFest is scheduled for April 2006. A group of Canadian programmers rewrote OS-9/6809 Level II for the CoCo 3 (w/ address translation hardware) for efficiency, and to take advantage of the native mode of the Hitachi 6309. Today's serious CoCo users now typically have replaced the 68B09E in the CoCo 3 with an Hitachi 63B09E and run the rewrite, called NitrOS9. The combination is surprisingly fast, considering that it runs on an expressly low cost, 8-bit computer system.
  • The DigiCart/II Plus audio playback unit runs OS-9/68K. It is a solid state replacement for radio station style cart players. These units are used in radio and at places like Walt Disney World where they play park announcements.

[edit] Trivia/Easter Eggs

The OS-9 version 2.4 manual had this entry describing UNIX in the Glossary of Appendix C of "Using Professional OS-9":

UNIX:
An operating system similar to OS-9, but with less functionality and 
special features designed to soak up excess memory, disk space and CPU 
time on large, expensive computers.

This entry was, curiously, removed in the version 3.0 manual.

The OS-9 shell had an Easter egg in its command history function, invoked by CTRL-A. Upon a fresh boot, the command history was supposedly empty, but if the user typed a single space followed by a backspace, then hit CTRL-A, the names of the authors would be displayed: 'by K. Kaplan, L. Crane, R. Doggett'.

[edit] External links