Machine Types
This document summarizes the machines and models available in Klive IDE.
Choosing a machine
Switch machines from Machine › Machine Type or the Select machine… dialog (Cmd/Ctrl+Shift+M). Choosing a machine explains the dialog, editing the favourites, and where each machine’s own menus and settings appear. The sections below list every machine and model with its ID.
ZX Spectrum 48K
Sinclair’s 1982 home computer, the machine most Spectrum software was written for: a Z80 at 3.5 MHz, Sinclair BASIC in a 16K ROM, and 48K of RAM.
Machine ID: sp48
Available models:
pal: The original ZX Spectrum 48K model with PAL video output.ntsc: The original ZX Spectrum 48K model with NTSC video output.pal-16k: The original ZX Spectrum 48K model with PAL video output and 16K RAM.
The 16K, the 48K and the 128K (not the Pentagon) have two options of the ULA, in the machine’s menu and in Settings › Machine: Snow Effect (on by default) and Late ULA Timing, the one T-state later timing of many real machines (off by default). How the Screen Is Drawn explains both.
The 16K, the 48K and the 128K (not the Pentagon) take the ZX Interface 1 with two Microdrives, or the DivMMC, under Machine › Interfaces. See The Interface 1 and Microdrives.
The 48K’s, the 128K’s and the +2A/+3’s timing is checked against the community’s test programs, whose expected results come from real machines: see How Klive’s Accuracy Is Tested.
ZX Spectrum 128K
The 1985 successor of the 48K, with 128K of paged RAM, a second ROM with the 128 BASIC editor and its start menu, and an AY-3-8912 sound chip; the Pentagon 128 clone is a model of it.
Machine ID: sp128
One machine with two models. Both run the ZX Spectrum 128K’s ROMs and have its $7FFD paging and
AY chip; they differ in timing:
sp128: The original ZX Spectrum 128K.pentagon: The Pentagon 128, a Russian 128K clone much of the demoscene writes for. It runs at 3.5 MHz with a longer frame (224 T-states by 320 lines, 71,680 T-states, about 48.8 frames per second), has no memory or I/O contention, and has no floating bus: an unattached port reads$FF.
Which one to pick. Choose the Pentagon for software written for it, such as demos whose effects are timed to its frame, or to check that your own code runs on both machines. Choose the 128K for everything else. Running, debugging, injecting code, the tape Loader, snapshots and Klive state files work the same on both.
The Pentagon has the Beta 128 disk interface: two drives (A and B) that take TR-DOS disk images
(.trd and .scl), and TR-DOS itself. Klive cannot ship the TR-DOS ROM, so you name your own copy
under Settings › Machine > TR-DOS ROM; until you do, the Pentagon runs without its disks. See
Using TR-DOS Disks on the Pentagon 128.
A .z80 or .szx snapshot of a Pentagon 128 opens on the Pentagon model. A 128K snapshot opens on
the 128K model, unless your project already uses the Pentagon: a 128K .sna file does not say
which of the two machines it came from. A snapshot saved from the Pentagon is written as a Pentagon
128.
ZX Spectrum +2A/+3/+2E/+3E
Amstrad’s Spectrums: the +2A with a built-in tape recorder and the +3 with a 3-inch floppy drive, plus the +2E/+3E, the same hardware with modern ROMs that add hard disks and SD cards.
Machine ID: spp3e
One machine with two families of ROMs. The hardware is Amstrad’s +2A/+3 (the gate array, the
$7FFD/$1FFD paging, the floppy controller and the AY chip) in every model; the models differ in
their drives and in the ROMs they boot.
The +2E/+3E models boot Garry Lancaster’s +3E ROMs, a modern replacement for the Amstrad ones:
nofdd: ZX Spectrum +2E (without floppy disk drive).fdd1: ZX Spectrum +3E (with a single floppy disk drive).fdd2: ZX Spectrum +3E (with two floppy disk drives).
The +2A/+3 models boot Amstrad’s original ROMs, unmodified:
plus2a: ZX Spectrum +2A (v4.1 ROMs, no floppy disk drive).plus2a-es: ZX Spectrum +2A (Spanish v4.1 ROMs).plus3-fdd1,plus3-fdd2: ZX Spectrum +3 (v4.1 ROMs, one or two floppy disk drives).plus3-v40-fdd1,plus3-v40-fdd2: ZX Spectrum +3 v4.0 (the 1987 ROMs of the first +3s).plus3-es-fdd1,plus3-es-fdd2: ZX Spectrum +3 (Spanish v4.1 ROMs).
Which one to pick. Choose a +2A or +3 model when a program must behave exactly as on the
original machine: software that calls the Amstrad ROM directly, or needs a particular ROM version
or the Spanish ROMs. Choose a +2E or +3E model for everyday use: the +3E ROMs are compatible with
the Amstrad ones and add their own improvements. Running, debugging, injecting code, the tape
Loader, .dsk disks, snapshots and Klive state files work the same on every model.
A .z80 or .szx snapshot of a +2A or +3 opens on a +2E/+3E model by default, with a warning that
it runs on the +E ROMs. When your project already uses a +2A or +3 model, the snapshot stays on it
and the warning goes. A snapshot saved from a +2A or +3 model is written as a +2A or +3.
ZX Spectrum Next
The FPGA-based successor of the Spectrum: compatible with the 48K, 128K and +3, with a faster Z80N, far more memory, Layer 2, tilemaps, hardware sprites, the Copper and a DMA.
Machine ID: zxnext
Available models: the original ZX Spectrum Next (KS2).
Tapes load and save through the 48K ROM’s tape routines and the Next’s own EAR input (see Tapes).
Timex TC2048/TC2068/TS2068
Timex’s versions of the Spectrum, sold in Portugal and, as the TS2068, in the United States, with extra screen modes and, on the 2068s, a cartridge port and a sound chip.
Machine ID: timex
Available models:
tc2048: The Timex Computer 2048, a 48K Spectrum made in Portugal, whose ULA is Timex’s SCLD.tc2068: The Timex Computer 2068, the European 2068 (PAL, 50 Hz).ts2068: The Timex Sinclair 2068, the American 2068 (NTSC, 60 Hz).
Every model runs 48K software, and adds the SCLD’s features:
- Screen modes, selected by port
$FFbits 0-2:0the normal screen;1a second screen at$6000(attributes at$7800);2extended colour, one attribute byte for every 8 × 1 pixels, at$6000plus the pixel byte’s offset;6a 512 × 192 two-colour screen, whose even columns come from$4000and odd columns from$6000. Bits 3-5 pick that mode’s ink (the paper is its complement, and the border shows the paper colour); the TC models show these colours BRIGHT, the TS2068 does not. Reading port$FFreturns what was written. - Interrupt control: port
$FFbit 6 set stops the frame interrupt.
The CPU runs at the SCLD’s 3.528 MHz. The TC2048 and TC2068 keep the 48K’s frame (224 T-states by 312 lines); the TS2068’s is 262 lines (58,688 T-states, 60 frames a second).
The TC2048 has a built-in Kempston joystick port, driven by joystick 1’s bindings (Machine > Input > Kempston Joystick).
The TC2068 and TS2068 add:
- Bank switching in 8K chunks. Each of the eight 8K chunks of the address space comes from the
HOME bank (the 16K ROM and 48K of RAM), or - when its bit in port
$F4is set - from the cartridge (the DOCK) or, with port$FFbit 7 set, from the 8K Extension ROM (EXROM). The screen always comes from HOME. The memory and disassembly views and the breakpoints name the chunksH0-H7,D0-D7andX0-X7. - An AY-3-8912 sound chip on ports
$F5(register select) and$F6(data), clocked at 1.764 MHz, with the PSG panel. - Two joysticks, read through the AY’s register 14 (Machine > Input > Joysticks).
- Cartridges: Machine > Cartridge > Insert Cartridge… puts a
.dckfile into the DOCK, and the media strip shows it. The machine restarts, because its ROM looks for a cartridge when it starts. - Ports
$FE,$F4,$F5,$F6and$FFare decoded on their full low byte.
ROMs. Klive cannot ship Timex’s ROMs. Name your own copy under Settings › Machine (the
Timex ROM option, shown while a Timex model runs): the TC2048’s is 16K; a 2068’s is one 24K file, its 16K HOME ROM
followed by its 8K EXROM. Until you do, the machine boots the Sinclair 48K ROM (a 2068 then has no
EXROM). Klive knows the TS2068 ROM (CRC-32 48004230): with it, running and debugging code, and
loading tapes from the IDE, use its own main loop and tape routines. With a 2068 ROM Klive has not
seen, the machine runs, but the IDE cannot start a program or a tape in it.
Running, debugging, injecting code (code built for the 48K runs as it is), tapes, snapshots and Klive state files work on every model.
Snapshots. A .szx or .z80 snapshot of a TC2048, TC2068 or TS2068 opens on its model, with its
screen mode, its chunk map and the 2068s’ AY; a .szx also keeps the cartridge’s pages. A Timex
machine saved as .sna loads as a 48K, and Klive names what it loses.
Scorpion ZS-256
A Russian Spectrum 128 clone with 256K of RAM and a built-in TR-DOS disk interface.
Machine ID: scorpion
Available models:
zs256: The Scorpion ZS-256, a Russian 128K-compatible machine with 256K of RAM and a built-in Beta 128 disk interface.
The Scorpion runs on the ZX Spectrum 128K’s core, and adds:
- 256K of RAM in sixteen banks. Port
$7FFDpages banks as on the 128K; port$1FFDbit 4 adds 8 to the bank at$C000(banks 8-15), bit 0 puts RAM bank 0 at$0000, and bit 1 puts the service monitor ROM there.$7FFDbit 5 locks$7FFDonly, never$1FFD. Both ports are decoded on more address lines than the 128K’s. - Four ROMs: the 128K editor, 48K BASIC, the service monitor and TR-DOS. The memory and
disassembly views and the breakpoints name them
R0-R3, and the banksB0-B15. - The Beta 128 disk interface, built in, with two drives (
.trdand.scldisks), as on the Pentagon 128 - see Using TR-DOS Disks on the Pentagon 128. - Timing: 3.5 MHz, the 48K’s frame (224 T-states by 312 lines, 69,888 T-states), and no memory or I/O contention. Unattached ports read the floating bus.
ROMs. Klive cannot ship the Scorpion’s 64K ROM. Name your own copy under Settings › Machine ›
Scorpion ZS-256 ROM. Until you do, the Scorpion boots the ZX Spectrum 128K’s ROMs, the service monitor’s page reads
$FF, and TR-DOS comes from the TR-DOS ROM you name under Settings › Machine > TR-DOS ROM. With the 128K
ROMs, running and debugging code, the Tape Loader and booting a disk work as on the 128K and the
Pentagon. With the Scorpion’s own ROM the machine runs, but the IDE cannot start a program, a tape or
a disk in its editor, which Klive does not know; load them by hand.
Snapshots. A .szx or .z80 snapshot of a Scorpion opens on it with all sixteen banks and
$1FFD. A Scorpion saved as .sna loads as a 128K without banks 8-15, and Klive refuses it while
$1FFD is in use.
Cambridge Z88
Sir Clive Sinclair’s 1987 A4-sized portable: a Z80 running the OZ operating system from ROM, with a 640-pixel-wide LCD and three card slots.
Machine ID: z88
Available models:
OZ50: Cambridge Z88 (OZ v5.0B Int.)OZ47: Cambridge Z88 (OZ v4.7)OZ40: Cambridge Z88 (OZ v4.0 UK)OZ40FI: Cambridge Z88 (OZ v4.01 SE/FI)OZ30: Cambridge Z88 (OZ v3.0 UK)OZ323IT: Cambridge Z88 (OZ v3.23 IT)OZ326FR: Cambridge Z88 (OZ v3.26 FR)OZ319ES: Cambridge Z88 (OZ v3.19 ES)OZ321DK: Cambridge Z88 (OZ v3.21 DK)OZ318DE: Cambridge Z88 (OZ v3.18 DE)
Klive can open, run and debug Z88 snapshots saved by the OZvm emulator; see Using Z88 Snapshots.
Sinclair ZX81
Sinclair’s 1981 low-cost computer: a Z80 at 3.25 MHz, BASIC in an 8K ROM, 1K of RAM, and a black-and-white picture that the CPU itself helps to draw.
Machine ID: zx81
Available models:
zx81-16k: Sinclair ZX81 with 16K RAM.zx81-1k: Sinclair ZX81 with its own 1K RAM.zx81-64k: Sinclair ZX81 with 64K RAM.zx81-16k-us: The US machine (Timex Sinclair 1000), NTSC, with 16K RAM.zx81-1k-us: The US machine with 1K RAM.
Sinclair ZX80
Sinclair’s first computer, the ZX81’s 1980 predecessor: BASIC in a 4K ROM, 1K of RAM, and a screen that goes blank while a program runs.
Machine ID: zx80
Available models:
zx80-16k: Sinclair ZX80 with 16K RAM.zx80-1k: Sinclair ZX80 with its own 1K RAM.zx80-8krom-16k: Sinclair ZX80 with the 8K ROM upgrade (the ZX81 ROM) and 16K RAM.
HT-1080Z
A Hungarian school computer of the early 1980s, compatible with the Tandy TRS-80 Model I, with Level II BASIC in ROM.
Machine ID: ht1080z
Available models:
ht1080z-s2: HT-1080Z Series II, 16K RAM, with the accented letters Á É Ö Ü á é ö ü.ht1080z-s1: HT-1080Z Series I, 16K RAM, with the TRS-80’s character set.ht1080z-64: HT-1080Z/64, 48K RAM, with all the Hungarian accented letters, Greek and mathematical signs, and an AY-3-8910 sound chip.ht1080z-s1-48k,ht1080z-s2-48k: Series I and Series II with 48K RAM.
See Using the HT-1080Z.
Videoton TVC
A Hungarian home and school computer of the second half of the 1980s: a Z80 at 3.125 MHz, a 6845 video chip with 2-, 4- and 16-colour graphics, and BASIC in ROM.
Machine ID: tvc
Available models:
tvc64: Videoton TVC 64K, BASIC 1.2, one 16K video RAM bank.tvc64p: Videoton TVC 64K+, BASIC 2.2, four 16K video RAM banks.
Either model takes the HBF floppy interface with VT-DOS (machine configuration tvcHbf).
See The Videoton TVC.
Enterprise 64/128
A British home computer of 1985: a Z80 at 4 MHz, the NICK video chip with up to 256 colours, the DAVE chip for memory paging, stereo sound and interrupts, and the EXOS operating system with IS-BASIC on a cartridge.
Machine ID: ep
Available models:
ep128: Enterprise 128, 128K RAM, EXOS 2.1 and IS-BASIC 2.1.ep64: Enterprise 64, 64K RAM, EXOS 2.0 and IS-BASIC 2.0.
Both models start with IS-BASIC in the cartridge slot and Klive’s FILE: device, which reads and
writes host files.
See The Enterprise 64 and 128.
SAM Coupé
A British home computer of 1989 from Miles Gordon Technology: a Z80B at 6 MHz, a custom ASIC with four screen modes and a 128-colour palette, a Philips SAA 1099 for six-channel stereo sound, and SAM BASIC in ROM. Disks are 800K 3.5” floppies in the MGT format.
Machine ID: sam
Available models:
sam512: SAM Coupé 512K, ROM 3.0.sam256: SAM Coupé 256K, ROM 3.0.
Both models start with one disk drive and the mouse interface fitted. Machine menu items choose a second drive, no drive, and ROM 3.1 instead of 3.0.
See The SAM Coupé.