Basic extensions

The SamRam is a hardware device Johan and I built for our Spectrums. It consists of a 32K static RAM chip which contains a modified copy of the normal Basic ROM and a number of other useful routines, like a monitor and snapshot software. You can compare it to a Multiface I interface, but it's more versatile. Another useful feature was a simple hardware switch which allowed use of the shadow 32K Ram, present at 8000-FFFF in most Spectrums, but hardly ever actually used.

For more details on the low-level hardware features of the SamRam read chapter 5. In this chapter I'll explain the software features of the SamRam software, somewhat bombastically called the `SamRam 32 Software System' or the `Sam Operating System'. By the way, all similarity between existing computers is in fact purely coincidental and has in no way been intended. Really!

The SamRam offers a few new Basic commands, and a lot of useful routines that are activated by an NMI, i.e. by pressing F5. First I'll discuss the Basic extension.

Select the SamRam by starting the emulator with the -s switch, or by selecting it from the F9 menu. Normal Basic functions as usual; the character set is different from the original one. There are four new commands:
 *RS, *MOVE, *SAVE and *SPECTRUM,
and two new functions, DEC and HEX, which have replaced ASN and ACS. DEC takes a string argument containing a hexadecimal number, and returns the decimal value of it. HEX is the inverse of the DEC function, and yields a four-character string.