ZX Spectrum Emulators
Part One
ZX SPECTRUM, the friendliest of computers, has had emulators created for it that can reproduce its operation on almost all serious 16-bit machines (IBM, AMIGA, ATARI ST/TT), as well as on 8-bit computers: ACORN ARCHIMEDES, SAM COUPE and C-64. The last of these computers, however, emulates only ZX BASIC, which makes it almost 99.9% impossible to use the software available for the SPECTRUM.
I’ll begin this survey with PC emulators.
The first of them, called JPP, emulates the 48kB model. Its hardware requirements are quite high: a 386 processor or higher, and a VGA graphics card. JPP was written by Norwegian programmer Arnt Gulbrandsen, and his emulator is distributed free of charge.
The package consists of:
jpp— the actual emulatorpjpp(perfect-jpp) — only for very fast 486SX/486DX processorsspconv— a converter that enables transmission between different file formats, allowing compatibility with other emulatorsspecdisc— a useful tool for transferring data from a ZX SPECTRUM; it can read the disk formats of the SAM COUPE and the PLUS D drive, popular in England
The package also includes files containing ROM with errors corrected that had occurred in the standard ROM.
The heart of the whole system is the Z-80 processor. Unfortunately, JPP’s emulation of it has some shortcomings:
- Commands associated with register R do not work correctly.
- The LDIR command takes more cycles than other commands.
- Two “unused” bits in the register can disrupt a program if they are used (they do not physically exist).
- Interrupt timing is delayed after the instructions CALL, JR, JP and RET.
These shortcomings do not, however, prevent about 90% of programs from running correctly on JPP.
The graphics screen is displayed using 320×240 mode with 16 colours. The screen refresh rate is 16.67 Hz (compared with 50 Hz on the original), which means that some programs that use BORDER as an additional part of the screen will not look the same as they do on the original SPECTRUM.
The bit from port 254 responsible for producing sound has been moved to the PC Speaker built into every IBM PC, where it performs its role properly.
KEMPSTON is emulated using a standard joystick.
Transferring programs between JPP and a SPECTRUM is no longer a problem if you have a PLUS D drive or a MICRODRIVE. The other method involves transmission via an RS-232 connection. Although slow and inconvenient, it is the only method available if you do not have the equipment mentioned above.
A major improvement would be a (software) interface for a cassette recorder, which the author has announced for future versions of the emulator.
JPP saves programs by creating a file with the .SNA extension, 49178 bytes long. The first 27 bytes are a header containing the values of all the registers, the border colour, etc. The remaining bytes are 48kB of uncompressed RAM.
Unfortunately, it is not possible to save individual blocks of memory, for example with SAVE "dupa" SCREEN$. This is a major inconvenience for those writing, for instance, individual procedures that will be compiled at different memory addresses.
The emulator is available from the ZX LAND editorial office, or by ordering directly from the author:
********************
* ARNT GULBRANDSEN *
KOMETV.8
* N-7036 TRONDHEIM *
NORWAY
********************
The next emulator I’ll describe is SPECEM, written by Kevin J. Phair. He finished work on it in 1992, releasing version 1.4. The program has somewhat lower hardware requirements: at least a 286 processor with an EGA graphics card or better. It is very easy to use.
ZX SPECTRUM Emulators
Fragment 2/2
In the ROM, the tape LOAD/SAVE routines have been replaced with hard disk support routines. This makes it possible to save and read files in the same way as on tape; it is a great convenience compared with the save format used by the previously described emulator.
The current values of all registers and the hexadecimal code of the instruction being executed are displayed on screen. You can enable or disable interrupts and sound, and stop the emulation.
The package also includes the small PDEX program, which allows conversion of the PLUS D format. Advertisements for games (MIDNIGHT RESISTANCE, BATTY, POOL, etc.) are included with the emulator.
The program is free.
Author's address:
********************
KEVIN J. PHAIR
* 28 BANCROFT ROAD *
TALLAGHT
DUBLIN 24
UNITED KINGDOM
********************
I’ll devote the next part of the article to the best PC-based emulator, called Z80, which:
- emulates the 48kB/128kB models
- has an AY sound generator
- allows programs to be loaded through the cassette interface, including those using SPEEDLOCK and other non-standard systems
- supports “level-based” games
- allows interrupts to be disabled
- simulates the MULTIFACE
- displays effects in the border (BORDER), etc.
WILL
Share your thoughts about the article