Post

Visualizzazione dei post da aprile, 2020

Storage of variables in Apple-1 Integer BASIC

Immagine
by Claudio Parmigiani The purpose of this document is to clarify how variables are stored in RAM and how this information can be used. This information applies to Apple-1 (both Originals and Replicas) and to most of the emulators. A brief recap, taken from the Apple-1 PRELIMINARY BASIC USERS MANUAL: Let us suppose, from now on, that the memory configuration is "standard" according to the indications in the manual: PRIMARY RAM BANK from address $0000 to $0FFF (4096 bytes) OPTIONAL RAM BANK from address $E000 to $EFFF (4096 bytes) BASIC will be loaded in the optional RAM BANK. We will not consider memory manipulation made by LOMEM or HIMEM commands. When BASIC is running the user’s RAM, by default, is from $0800 to $0FFF (2047 bytes). 1. Program not using variables A BASIC program is stored so that its end coincides with the last byte of memory available. In the two examples above, the one-liner 10 PRINT “HELLO” is stored from $0FF4 to $0FFF . If a