Atari Assembler Editor

Last updated
Atari Assembler Editor
Original author(s) Kathleen O'Brien
Developer(s) Shepardson Microsystems
Initial release1981;43 years ago (1981)
Platform Atari 8-bit
Size 8KB
Type Assembler
License Proprietary software

Atari Assembler Editor (sometimes written as Atari Assembler/Editor) is a ROM cartridge-based development system released by Atari, Inc. in 1981. It is used to edit, assemble, and debug 6502 programs for Atari 8-bit computers without the need for additional tools. It was programmed by Kathleen O'Brien of Shepardson Microsystems, the company which wrote Atari BASIC, and Assembler Editor shares many design concepts with that language implementation.

Contents

Assembly times are slow, making the cartridge challenging to use for larger programs. In the manual, Atari recommended the Assembler Editor as a tool for writing subroutines to speed up Atari BASIC, [1] which would be much smaller than full applications. The Atari Macro Assembler was offered as an alternative with better performance and more features, such as macros, but it is disk-based, copy-protected, and does not include an editor or debugger. Despite the recommendation, commercial software was written using the Assembler Editor, such as the games Eastern Front (1941) , [2] Caverns of Mars , [3] Galahad and the Holy Grail , [4] and Kid Grid . [5]

The source code to the original Assembler Editor was licensed to Optimized Systems Software who shipped EASMD based on it.

Development environment

The Assembler Editor is a two-pass 6502 assembler in an 8KB cartridge. Both source and object code can be in memory simultaneously, allowing repeated editing, assembly, and running of the resulting code without accessing a disk or tape drive. [6]

Edit

The cartridge starts in EDIT mode. The programmer enters lines of assembly source into the Atari BASIC-like editor. Source text must be prefixed with a line number or it is interpreted as a command. Like Atari BASIC, Assembler Editor includes an ENTER command that can be used to combine files together into a single larger program listing. Unlike Atari BASIC, Assembler Editor includes commands for automatically creating spaced-out line numbers, as well as renumbering lines and deleting them en masse. A FIND command is useful when working with labels. [7]

Instructions are listed in the order they will be placed in memory. The starting point for instructions is specified with the *= directive, so, for instance, code intended to be placed in the special "page six" would be prefixed with the line *= $0600. [8] Variable names can be assigned to specific addresses, and this was often combined with an increment *= *+1 to directly encode offsets into tables. [9]

Values following instructions are normally interpreted as "the value at this memory address", but an actual numeric value can be provided as an "immediate operand" by appending it with a hash, like LDA #12, which loads the accumulator with the decimal value 12. Hexadecimal is indicated with a dollar sign, LDA #$12 loads the accumulator with 12 hex, or 18 decimal. Indirect addressing is supported using parentheses; LDA ($600) uses the values in location $600,$601 to produce a 16-bit address, and then loads the accumulator with the value found at that location. [10]

Errors are reported with numeric codes that can be looked up in the manual. There are 19 assembler-specific codes and 16 additional codes for operating system input/output errors. [11]

Assemble

Code is assembled by typing the ASM command into the editor. [12]

Assembler Editor was widely derided as the slowest assembler on the platform. Much of this is from sharing code with Atari BASIC, also written by Shepardson Microsystems. Atari BASIC uses slow routines used to convert numeric constants in code to an internal binary-coded decimal representation via operating system routines. All numbers, even line numbers, have to be converted to binary-coded decimal. It also means that 1E2 is a legal line number. [13]

Debug

The debugger, really a monitor, is entered with the BUG command. [14] The X command returns to EDIT mode. [15] The debugger allows the viewing and changing of registers and memory locations, code tracing, single-step and disassembly. [16]

History

Assembler Editor was written by Kathleen O'Brien of Shepardson Microsystems. The company had been hired by Atari to help fit Microsoft 6502 BASIC onto an 8KB ROM, something programmers at Atari were struggling with. Instead, Bill Wilkinson suggested designing an entirely new version of BASIC, which became Atari BASIC. [17]

While Atari BASIC was being written, primarily by Paul Laughton, O'Brien's husband, O'Brien worked on the Assembler Editor. [17] It was written by punching codes into a punch tape machine, running the tape through an EPROM burner, and then testing the resulting ROM in an Atari 800. The cartridge was completed before Atari BASIC, and O'Brien spent some time working on portions of that project as well. [17]

As part of Shepardson's work, a number of common routines were incorporated into the Atari computer's operating system, including the floating point math functions. These were written by O'Brien, the first floating point math code she worked on. [17] The low performance of key functions affected both Atari BASIC and the Assembler Editor and was a topic that Wilkinson often wrote about. [18]

Example code

The following is 6502 code for Hello World! written for the Assembler Editor:

10; HELLO.ASM20; ---------30;40; THIS ATARI ASSEMBLY PROGRAM50; WILL PRINT THE "HELLO WORLD"60; MESSAGE TO THE SCREEN70;0100; CIO EQUATES0110; ===========0120*=$0340;START OF IOCB0130IOCB0140;0150ICHID*=*+1;DEVICE HANDLER0160ICDNO*=*+1;DEVICE NUMBER0170ICCOM*=*+1;I/O COMMAND0180ICSTA*=*+1;I/O STATUS0190ICBAL*=*+1;LSB BUFFER ADDR0200ICBAH*=*+1;MSB BUFFER ADDR0210ICPTL*=*+1;LSB PUT ROUTINE0220ICPTH*=*+1;MSB PUT ROUTINE0230ICBLL*=*+1;LSB BUFFER LEN0240ICBLH*=*+1;MSB BUFFER LEN0250ICAX1*=*+1;AUX BYTE 10260ICAX2*=*+1;AUX BYTE 10270;0280GETREC=5;GET TEXT RECORD0290PUTREC=9;PUT TEXT RECORD0300;0310CIOV=$E456;CIO ENTRY VECTOR0320RUNAD=$02E0;RUN ADDRESS0330EOL=$9B;END OF LINE0340;0350; SETUP FOR CIO0360; -------------0370*=$06000380STARTLDX#0;IOCB 00390LDA#PUTREC;WANT OUTPUT0400STAICCOM,X;ISSUE CMD0410LDA#MSG&255;LOW BYTE OF MSG0420STAICBAL,X; INTO ICBAL0430LDA#MSG/256;HIGH BYTE0440STAICBAH,X; INTO ICBAH0450LDA#0;LENGTH OF MSG0460STAICBLH,X; HIGH BYTE0470LDA#$FF;255 CHAR LENGTH0480STAICBLL,X; LOW BYTE0490;0500; CALL CIO TO PRINT0510; -----------------0520JSRCIOV;CALL CIO0530RTS;EXIT TO DOS0540;0550; OUR MESSAGE0560; -----------0570MSG.BYTE"HELLO WORLD!",EOL0580;0590; INIT RUN ADDRESS0600; ----------------0610*=RUNAD0620.WORDSTART0630.END

These commands can be interactively entered to assemble the code, enter the debugger, run the program, then exit the debugger when it is finished:

ASM BUG G600 X

Legacy

Shortly after Shepardson delivered Assembler Editor and Atari BASIC to Atari, Bob Shepardson, the owner, decided to return to being a one-person company. [19] O'Brien, Laughton, and Wilkinson formed their own company, Optimized Systems Software (OSS), to continue development of the Atari products. They licensed the original source code for BASIC, Assembler Editor, and Atari DOS, which they had collectively written. [20]

In 1981, OSS released an improved version of Assembler Editor, EASMD on floppy disk. EASMD was replaced by MAC/65 in 1982. MAC/65 was one of the fastest assemblers on the platform. [13] Much of the improved performance of MAC/65 is the result of tokenizing lines of code as they're entered—at is the case with Atari BASIC—to reduce the amount of work needed at assembly time. [6]

Assembler Editor continued to be available from Atari, and increased in popularity as the price dropped to US$10 or 5 in the latter half of the 1980s. [21]

Related Research Articles

<span class="mw-page-title-main">MOS Technology 6502</span> 8-bit microprocessor from 1975

The MOS Technology 6502 is an 8-bit microprocessor that was designed by a small team led by Chuck Peddle for MOS Technology. The design team had formerly worked at Motorola on the Motorola 6800 project; the 6502 is essentially a simplified, less expensive and faster version of that design.

<span class="mw-page-title-main">Atari 8-bit computers</span> Home computer series introduced in 1979

The Atari 8-bit computers, formally launched as the Atari Home Computer System, are a series of 8-bit home computers introduced by Atari, Inc. in 1979 with the Atari 400 and Atari 800. It is the first home computer architecture with coprocessors, enabling more advanced graphics and sound than most of its contemporaries. Video games are key to its software library, and the 1980 first-person space combat simulator Star Raiders is considered the platform's killer app.

<span class="mw-page-title-main">Atari BASIC</span> Dialect of the BASIC programming language

Atari BASIC is an interpreter for the BASIC programming language that shipped with Atari 8-bit computers. Unlike most American BASICs of the home computer era, Atari BASIC is not a derivative of Microsoft BASIC and differs in significant ways. It includes keywords for Atari-specific features and lacks support for string arrays.

Integer BASIC is a BASIC interpreter written by Steve Wozniak for the Apple I and Apple II computers. Originally available on cassette for the Apple I in 1976, then included in ROM on the Apple II from its release in 1977, it was the first version of BASIC used by many early home computer owners.

Commodore BASIC, also known as PET BASIC or CBM-BASIC, is the dialect of the BASIC programming language used in Commodore International's 8-bit home computer line, stretching from the PET (1977) to the Commodore 128 (1985).

The Atari Microsoft BASIC and Atari Microsoft BASIC II variants of the 6502-version of Microsoft BASIC ported to the Atari 8-bit computers. The first version, released 1981, required 32 KB of RAM and was supplied on floppy disk. The second version, released the next year, had most of the code on a ROM cartridge with additional functions on an optional floppy.

<span class="mw-page-title-main">Action! (programming language)</span> Atari 8-bit computer programming language

Action! is a procedural programming language and integrated development environment written by Clinton Parker for the Atari 8-bit computers. The language, which is similar to ALGOL, compiles to high-performance code for the MOS Technology 6502 of the Atari computers. Action! was distributed on ROM cartridge by Optimized Systems Software starting in 1983. It was one of the company's first bank-switched 16 kB "Super Cartridges". The runtime library is stored in the cartridge; to make a standalone application requires the Action! Toolkit which was sold separately by OSS.

<span class="mw-page-title-main">Turbo-BASIC XL</span>

Turbo-BASIC XL is an enhanced version of the BASIC programming language for Atari 8-bit computers. It is a compatible superset of the Atari BASIC that shipped with the Atari 8-bit systems. Turbo-Basic XL was developed by Frank Ostrowski and published in the December 1985 issue of German computer magazine Happy Computer. A version for the 400/800 models was released shortly after as Frost Basic 1.4. Several modified versions working with different DOS systems have been released by other authors.

<span class="mw-page-title-main">WDC 65C02</span> CMOS microprocessor in the 6502 family

The Western Design Center (WDC) 65C02 microprocessor is an enhanced CMOS version of the popular nMOS-based 8-bit MOS Technology 6502. It uses less power than the original 6502, fixes several problems, and adds new instructions. The power usage is on the order of 10 to 20 times less than the original 6502 running at the same speed; its reduced power consumption has made it useful in portable computer roles and industrial microcontroller systems. The 65C02 has also been used in some home computers, as well as in embedded applications, including medical-grade implanted devices.

Optimized Systems Software (OSS) was a company that produced disk operating systems, programming languages with integrated development environments, and applications primarily for Atari 8-bit computers. The founders of OSS previously developed Atari DOS, Atari BASIC, and the Atari Assembler Editor for Atari, Inc., and many OSS products are substantially improved versions. OS A+ and DOS XL are based on Atari DOS. BASIC A+, BASIC XL, and BASIC XE are based on Atari BASIC. EASMD and MAC/65 are modeled on the Atari Assembler Editor. Action! is an ALGOL-inspired compiled programming language with an integrated full-screen editor. OSS also sold some software for the Apple II.

Shepardson Microsystems, Inc. (SMI) was a small company producing operating systems and programming languages for CP/M, the Atari 8-bit family and Apple II computers. SMI is most noted for the original Apple II disk operating system, Atari BASIC, and Atari's disk operating system. Shepardson Microsystems was founded by Robert Shepardson in Saratoga Springs, New York.

<span class="mw-page-title-main">Acorn MOS</span> Computer operating system

The Machine Operating System (MOS) or OS is a discontinued computer operating system (OS) used in Acorn Computers' BBC computer range. It included support for four-channel sound, graphics, file system abstraction, and digital and analogue input/output (I/O) including a daisy-chained expansion bus. The system was single-tasking, monolithic and non-reentrant.

<span class="mw-page-title-main">CBASIC</span> Compiled BASIC programming language for CP/M

CBASIC is a compiled version of the BASIC programming language written for the CP/M operating system by Gordon Eubanks in 1976–1977. It is an enhanced version of BASIC-E.

The 65xx family of microprocessors, consisting of the MOS Technology 6502 and its derivatives, the WDC 65C02, WDC 65C802 and WDC 65C816, and CSG 65CE02, all handle interrupts in a similar fashion. There are three hardware interrupt signals common to all 65xx processors and one software interrupt, the BRK instruction. The WDC 65C816 adds a fourth hardware interrupt—ABORT, useful for implementing virtual memory architectures—and the COP software interrupt instruction, intended for use in a system with a coprocessor of some type.

<span class="mw-page-title-main">Atari 8-bit computer software</span>

Many games, utilities, and educational programs were available for Atari 8-bit computers. Atari, Inc. was primarily the publisher following the launch of the Atari 400/800 in 1979, then increasingly by third parties. Atari also distributed "user written" software through the Atari Program Exchange from 1981 to 1984. After APX folded, many titles were picked up by Antic Software.

<i>De Re Atari</i> 1982 technical book

De Re Atari, subtitled A Guide to Effective Programming, is a book written by Atari, Inc. employees in 1981 and published by the Atari Program Exchange in 1982 as an unbound, shrink-wrapped set of three-holed punched pages. It was one of the few non-software products sold by APX. Targeted at developers, it documents the advanced features of the Atari 8-bit computers and includes ideas for how to use them in applications. The information in the book was not available in a single, collected source at the time of publication.

<span class="mw-page-title-main">GNUSim8085</span>

GNUSim8085 is a graphical simulator, assembler and debugger for the Intel 8085 microprocessor in Linux and Windows. It is among the 20 winners of the FOSS India Awards announced on February, 2008. GNUSim8085 was originally written by Sridhar Ratnakumar in fall 2003 when he realized that no proper simulators existed for Linux. Several patches, bug fixes and software packaging have been contributed by the GNUSim8085 community. GNUSim8085 users are encouraged to contribute to the simulator through coding, documenting, testing, translating and porting the simulator.

<span class="mw-page-title-main">SpartaDOS X</span> Disk operating system

SpartaDOS X is a disk operating system for the Atari 8-bit family of computers that closely resembles MS-DOS. It was developed and sold by ICD, Inc. in 1987-1993, and many years later picked up by the third-party community SpartaDOS X Upgrade Project, which still maintains the software.

<span class="mw-page-title-main">MAC/65</span> Atari 8-bit family 6502 assembler

MAC/65 is a 6502 assembler written by Stephen D. Lawrow for the Atari 8-bit family of home computers. MAC/65 was first released on disk by Optimized Systems Software in 1982, with the program requiring 16 KB RAM. A bank switched "SuperCartridge" from OSS followed in January 1984 for US$99, occupying only 8 KB.

<span class="mw-page-title-main">BASIC interpreter</span> Interpreter that enables users to enter and run programs in the BASIC language

A BASIC interpreter is an interpreter that enables users to enter and run programs in the BASIC language and was, for the first part of the microcomputer era, the default application that computers would launch. Users were expected to use the BASIC interpreter to type in programs or to load programs from storage.

References

Citations

  1. Manual 1981, p. 63.
  2. Crawford, Chris (1982). Source Code for Eastern Front (1941). The ATARI Program Exchange.
  3. The Creative Atari: Dog Daze and Caverns of Mars. 1983.
  4. Crockford, Douglas (1982). Galahad and the Holy Grail Manual (PDF). The ATARI Program Exchange.
  5. Ellison, Peter (April 1984). "Interview: Arti Haroutunian". ROM (5): 8.
  6. 1 2 Hague 2009.
  7. Manual 1981, p. 15.
  8. Manual 1981, p. 7,31.
  9. Manual 1981, p. 31.
  10. Manual 1981, pp. 10–12.
  11. Manual 1981, pp. 43–44.
  12. Manual 1981, p. 25.
  13. 1 2 Wetmore 1983, p. 29.
  14. Manual 1981, p. 35.
  15. Manual 1981, p. 41.
  16. Manual 1981, pp. 35–41.
  17. 1 2 3 4 Interview 2015.
  18. Wilkinson, Bill (February 1985). "INSIGHT: Atari". Compute!. p. 139.
  19. Wilkinson 1982, p. vi.
  20. Wilkinson 1982, pp. vi–vii.
  21. Ratcliff, Matthew (20 November 1989). "Atari Assembler Editor Reference".

Bibliography