Action!

Medium
Cartridge
Year
1983
Publisher
Optimized Systems Software, Inc.
Type
Language
Category
Compiled structured language with editor, monitor and library (cartridge)
Developer
Clinton Parker (Action Computer Services)
Language
6502 machine language
Requirements
Any Atari 400/800/XL/XE; Action! cartridge; disk drive recommended; Action! RunTime package (or modern equivalents) to run compiled programs without the cartridge
Yellow OSS box for Action!, with the slogan "Powerful! Flexible! Fast!" and the Optimized Systems Software logo

Overview

Action! is a compiled, structured programming language for the Atari 8-bit, sold on cartridge by Optimized Systems Software from 1983. The language and its development system were written by Clinton Parker, whose company Action Computer Services holds the copyright on the runtime. The OSS manual sums up the pitch: it is much faster than Atari BASIC, has a better editor, is just as easy to learn, and runs almost as fast as assembly language. It became the language of choice for many hobbyist game authors and for serious software such as Keith Ledbetter's BBS Express!, which was written in compiled Action!. Bill Wilkinson's Antic column notes that in May 1986 OSS won Antic's Lifetime Achievement award for tools that included Action!.

The system

The manual divides Action! into five parts that live together on one cartridge:

  • Monitor: the command shell. From here you enter the editor, COMPILE, RUN, set options, and debug.
  • Editor: a full-screen text editor with no line numbers. It offers find and substitute, tabs, windows, line breaking and joining, and restoring a changed line. It knows nothing about the language, so you can use it as a plain text editor too. You move between editor and monitor with CTRL-SHIFT-M.
  • Language: procedures and functions (PROC/FUNC … RETURN), IF/ELSEIF/ELSE/FI, FOR, WHILE and UNTIL with DO … OD loops, pointers, arrays and record TYPEs. Every identifier must be declared before use.
  • Compiler: turns source in memory, or on disk, directly into 6502 machine code.
  • Library: ready-made routines that cover the Atari BASIC repertoire and more, including Print/PrintE/PrintF, Graphics, Plot, DrawTo, Sound, Stick, file I/O and string conversion.

The three fundamental data types reflect what a 6502 handles well. BYTE (0–255, also usable as CHAR), CARD (unsigned 16-bit, 0–65,535) and INT (signed 16-bit). Using a BYTE as a loop counter makes the loop faster. There is no floating point, which is a large part of why Action! is so much faster than BASIC.

A small example that sums the numbers 1 to 100. Note the C-like ==+ operator and the %U/%E format codes in PrintF:

CARD sum
BYTE i

PROC Main()
  sum=0
  FOR i=1 TO 100
  DO
    sum==+i
  OD
  PrintF("Sum=%U%E",sum)
RETURN

Type it in the editor, press CTRL-SHIFT-M, then enter COMPILE and RUN at the monitor.

Behind the scenes

The cartridge is one of OSS's bank-switched designs. It packs 16K of ROM into a smaller window of address space, which leaves more RAM free while you program. There is a catch the manual states openly: compiled code calls library routines inside the cartridge, so a program will not run without Action! installed. OSS solved this with the Action! RunTime Package (manual revised March 1984). It compiles programs so that they run on their own, and can even produce .COM external commands for OS/A+ and DOS XL. RunTime-built programs could be shared freely, but anyone who wanted to sell Action! software had to buy a commercial licence. OSS also sold an Action! Toolkit disk of extra routines.

Programs written in Action! include the official Atari port of the Kermit file-transfer program by John Howard Palevich, released as Action! source, and many magazine games. Former users remember both how much freedom it gave them compared with assembler and the frustration of bugs fixed permanently in the ROM.

Open-source release and modern builds

In February 2015 an AtariAge member posted the original Action! 3.6 source code, which he had received years earlier from ICD, the company that had taken over OSS's product line. The release was announced as being under the GPL, and a SourceForge project (atari-action) was set up to collect fixes and a MADS-syntax port. The source runs to about 15,000 lines with very few comments. Patched builds have appeared since. jihem's atari_action repository, for example, targets an 800XL with Ultimate 1MB, SIDE2 and SpartaDOS X, and recommends "Action! 3.7X build Sun 29 Oct 2023".

Using it today

  • Emulator: attach the Action! cartridge image (OSS bank-switched type) in Altirra or Atari800 on any configuration, with a disk image for your sources (.ACT is the conventional extension).
  • Distributing programs: link your program with the RunTime library, or with one of the community replacements, so that people without the cartridge can run it.
  • Learning: the original manual has a useful appendix, "Converting BASIC Concepts to ACTION! Programs", and a "PRIMES" sieve benchmark to try. GBXL's revised 2015 edition of the manual is also widely circulated.
  • Gotchas: every identifier, whether variable, procedure or function, must be declared before it is used, so put globals and helper routines above the code that calls them.

Credits