Under the Hood
Articles about how Klive’s emulators work, and what you need to build Klive yourself and contribute to it.
Every machine is a C core compiled to WebAssembly, sharing one Z80, driven frame by frame from TypeScript.
How the emulator cores are builtThe core decides whether to stop, TypeScript decides what a stop means, and tests prove the stops are exact.
How the debugger decides where to stopHow the Next core follows the FPGA’s VHDL, and the harness that tests it through the hardware’s own interface.
The ZX Spectrum Next core and the FPGAKeyframes, a self-checking input journal, and replay that puts the whole machine in the past.
How reverse debugging worksFive producers of dots, two answers for every dot, and the pipeline that turns them into one colour.
ZX Spectrum Next: how the screen is drawnHow the ZX81’s ULA and Z80 cooperate to produce a picture, and how Klive emulates it.
ZX81: how the screen is drawnThe ZX81’s tape format and its signal, from the ROM’s point of view.
ZX81: how programs go to tapeOne T-state per character, the black dashes a video-memory access leaves, and Klive’s catch-up renderer.
HT-1080Z: how the screen is drawnA 6845 that only counts, one video RAM the CPU and the display take turns at, the three colour modes and the cursor that is a frame interrupt.
Videoton TVC: how the picture is madeGet the source code, install the WASM toolchain, and improve the documentation.
Contribute