← Manual LibraryVCC Plus 3.7.1 · Reading on the web

Try the exercises in VCC Plus. Example links download files here; open them in the app to work beside the emulator.

The complete book · PDF editionBook 11: Working with OS-9 — A Comprehensive Manual

51 pages · VCC Plus 3.7.1 · Keep a copy to read or print.

Download PDF
Contents

Chapter 11 of 14

Who owns this terminal?

OS-9 can run several shells on one CoCo 3. In the prepared boot, Shell+ starts on /Term and additional shells run on window devices. All of them share one physical keyboard. OS-9 chooses which guest window receives it. macOS separately decides whether your typing reaches the emulator at all.

Identify your terminal

Click the CoCo display and enter tmode. The first line on the main console is /Term. The options below include eko for character echo, eor for the end-of-record character, and eof for the end-of-file character. Here eor=0D is a carriage return. These are options on the current terminal path. You can inspect them without changing them.

Run devs to inspect the active window devices. On the supplied profile, the startup procedure uses W2, W3 and W4. Use the practice system with W7 free for this exercise. If W7 is already in use by your work, choose a fresh practice session. A window may display output even when it has no shell reading the keyboard.

Draw the station’s signal meter

At the main terminal enter the following two commands. iniz holds an attachment to the new device. wcreate defines its screen and colors. Screen type 8 selects a 320 × 192, 16-color graphics screen. The rectangle in the creation command is measured in character cells. It starts at the top left and spans 40 columns by 24 rows. The final three values select the foreground, background and border palette entries.

iniz /w7
wcreate /w7 -s=8 0 0 40 24 03 00 00

Send three pairs of drawing commands to W7 while you are still typing in /Term. The numbers after display are hexadecimal bytes. 1B 40 sets the draw pointer, and 1B 4A fills a rectangle from that pointer to the supplied opposite corner. Each coordinate consists of a high byte and a low byte. The driver interprets positions under its current scaling. The three bars share the same lower edge at Y = $0088.

display 1b 40 00 60 00 68 1b 4a 00 a0 00 88 >/w7
display 1b 40 00 c0 00 48 1b 4a 01 00 00 88 >/w7
display 1b 40 01 20 00 28 1b 4a 01 60 00 88 >/w7
display 1b 21 >/w7

The last command selects W7 for display. Look for three bars rising from left to right. In the captured palette the bars are green and the background is white. The staircase is the useful test even if your colors differ.

The actual guest graphics window displays three solid green bars. Their lower edges align and each successive bar is taller.

Return to the shell and release the window

With the guest display focused, press CoCo Clear. VCC Plus maps the Mac Home key to Clear. On the prepared profile we returned to the original terminal in one press. If your active windows are ordered differently, cycle until you see the original Term prompt. Trying to type a cleanup command on the graphic would send keys to the wrong window.

Back on /Term enter:

display 1b 24 >/w7
deiniz /w7
tmode

1B 24 ends the display window. deiniz releases the attachment you took with iniz. tmode should again identify /Term. You have created a graphics device, drawn into it, selected it, regained keyboard control and released the device while the same guest operating system continued running.

A second OS-9 window still belongs to the CoCo. The optional guest connection to the Mac shell crosses into macOS and has its own permission control. Use the terminal name and the command interpreter to decide which machine will receive your next command.

For the window protocol, see The NitrOS-9 Project, The NitrOS-9 Level 2 Windowing System, pp. 7–8 (creation), 20–23 (end and setup), 44 (selection), 49 and 58 (bar and draw pointer).

Original VCC Plus manuals © 2026 Brian K. Holman. Third-party references retain their authors’ copyrights and licenses. Artwork notices. Edition 3.7.1; source and export identity. Printable edition: PDF source and export identity.

A closer look

Open original