An operating system in the style of TI-OS for x86.

software (29) operating-system (2) programming-language (7)

Table of Contents
  1. Introduction
  2. The Shell
  3. Editor
  4. PandorOS BASIC
  5. Other Features
  6. Char Map
  7. Online Help
  8. Customization
  9. Links

Select anchorIntroduction

PandorOS is a small and playful operating system that was modelled after the TI-OS from Texas Instruments. It was the first operating system I wrote that I consider “done” in one way or another. It’s at least done in a way that it boots, you are able to load and store files, persist them on disk and write your own programs.

Select anchorThe Shell

The PandorOS shell is basically an interactive BASIC interpreter that uses the prompt #> . As all variables in the system are global, you could easily initialize variables and invoke programs by typing !run "".

As all commands are valid BASIC commands, you could also create sub-shells that were BASIC programs.

In the top bar, the shell provided access to the system menu, where you could do the following:

The virtual terminal system is pretty cool, as you can write a program in the Shell 0 terminal, and without closing the editor, try it out on the Shell 1 terminal.

This feature provides very rough multitasking capabilities. It is not possible to switch between shells while programs are running, though.

Select anchorEditor

PandorOS text editor showing a very simple four-line text file

PandorOS has a very simple editor built in, that can be invoked with !Edit <fileName>. The editor is a very simple, line based editor where the user can change files to create either data or program files.

Select anchorPandorOS BASIC

The PandorOS BASIC was modelled after TI BASIC, a very crude and simple BASIC dialect.

It uses -based assignments, so value → variable style whereas most programming languages use a variable = value style.

There was also a distinction between orders (top level statements) and functions (arithmetic operators).

Here’s a really small program counting from 1 to 10:

1 -> A

Label Loop

Print A
A + 1 -> A

If A < 10
  Goto Loop

As you can see, it uses a typical goto style programming, but does not employ line numbers, but tagged labels. Also the If statement is implemented by conditionally executing the next line of code or not.

Another, slightly more complex file is the following AUTORUN.BAS file:


"INIT.BAS" -> Str0

If Not Exists(Str0)
  Goto Create


Label Create
Print("Create '", Str0, "' in order to customize init sequence.")

This loads the current file system from the ATA0.0 storage device, then checks if a file called INIT.BAS exists and runs it, if so. Otherwise, it will print a small info message what the user can do to perform custom OS initialization.

All available commands can be found in the source code, they are defined in the orders.lst and functions.lst files.

Select anchorOther Features

Select anchorChar Map

As PandorOS uses the code page 437, a lot of characters were available that could not be entered via the keyboard.

Select anchorOnline Help

Similar to TI-OS, PandorOS features the so called Catalog, an index of all possible BASIC operations. Contrary to TI-BASIC, which had only a list of tokens, the PandorOS Catalog also had a nice online help included that explained what the system commands and tokens do:

Select anchorCustomization

The system color scheme was also customizable and could be persisted to disk. There were more options in the planning, but never implemented.

Select anchorLinks