article

Action!
Developer: Optimized Systems Software
Latest Release: 3.6
Release date: 1983
Platform: Atari 400/800/XL/XE
Genre: Programming Language
Media: cartridge
License: Copyright © 1994 Fine Tooned Engineering

Action! was a programming language, editor and in-memory 6502 compiler created by Clinton Parker working for Optimized Systems Software and running on the Atari 8-bit family of microcomputers. Its syntax was similar to that of ALGOL 68, and it was well-known for its speed. A library was available as a separate product called the Action! Toolkit.

It was released in 1983 and officially sold as a cartridge and later "cracked" to disk. "ATR" format files containing a version which may be run on modern systems under emulation are available on some websites.

Data Types


Action! has three numerical datatypes BYTEs, CARDinals and INTegers. The BYTE datatype is a single unsigned 8-bit byte, CARD is unsigned and two bytes long, and INT is signed and two bytes. Action! also has CHARs, ARRAYs, POINTERs and user defined TYPEs.

Unfortunately, no floating point support was available, and all data types were static. This meant variables had to be declared ahead of time and no dynamic memory management.

An example of a user-defined TYPE:

TYPE CORD=x,y CORD point point.x=42 point.y=23

Reserved keywords


AND FI OR UNTIL =< ( ARRAY FOR POINTER WHILE <> ) BYTE FUNC PROC XOR # . CARD IF RETURN = > [ CHAR INCLUDE RSH - >= ] DEFINE INT SET * < " DO LSH STEP / <= ' ELSE MOD THEN & $ ; ELSEIF MODULE TO % ! @ EXIT OD TYPE

Programming


Programming in Action! required working with the editor and compiling/debugging in the monitor. The ATASCII-style editor was a full-screen, scrolling display capable of displaying two windows. Features were block editing, global search and replace, and full-screen cursor control. Compiling took place in the monitor, a mode that allowed compiling and debugging.

Action! was a one-pass compiler. It compiled the source code entirely in memory. This allowed great speed, but limited the amount of code that could be compiled.

All arithmetic calculations were done in signed integer math, especially multiplication and division. Initializing variables to negative values didn't work, they needed to be in two's complement form (Example: 65535 instead of -1).

No inline assembler was included in the program; machine code had to be input directly, in hexadecimal.

Because of the lack of dynamic memory allocation, Action! did not support recursion.

Example code


The following is example code for Sieve of Eratosthenes written in Action:

BYTE RTCLOK=20, ; addr of sys timer SDMCTL=559 ; DMA control BYTE ARRAY FLAGS(8190) CARD COUNT,I,K,PRIME,TIME PROC SIEVE() SDMCTL=0 ; shut off Antic RTCLOK=0 ; only one timer needed COUNT=0 ; init count FOR I=0 TO 8190 ; and flags DO FLAGS(I)='T OD FOR I=0 TO 8190 ; and flags DO IF FLAGS(I)='T THEN PRIME=I+I+3 K=I+PRIME WHILE K<=8190 DO FLAGS(K)='F K==+PRIME OD COUNT==+1 FI OD TIME=RTCLOK ; get timer reading SDMCTL=34 ; restore screen PRINTF("%E %U PRIMES IN",COUNT) PRINTF("%E %U JIFFIES",TIME) RETURN

External links


Historical programming languages | Procedural programming languages | Atari 8-bit family software

 

This article is licensed under the GNU Free Documentation License. It uses material from the "Action programming language".

Home Pageartsbusinesscomputersgameshealthhospitalshomekids & teensnewsphysiciansrecreationreferenceregionalscienceshoppingsocietysportsworld