From an alternate…
{{ digitsEl }}...

In a slightly different reality…

Sinclair ZX Spectrum


A new ROM.
A new LANGUAGE.
The same machine.

from only £125!

This is the astonishing new ZX Spectrum — a powerful professional’s computer in everything but price!

There are two versions — 16K or a really powerful 48K. Both have a full 16 colours, sound generation, a full-size moving-key keyboard and high-resolution graphics. Plus structured programming, syntax colouring and report codes!

  • Massive RAM — 16K or 48K
  • 16 colours, 2 per screen cell
  • Full-size moving-key keyboard, with repeat facility on each key.
  • User defined graphics
  • 10× faster than ZX81 BASIC
  • Integer & floating-point maths
  • UP TO 64 text chars per line
  • High resolution — 256 × 192 pixels
  • Bit-mapped sprites — up to 6!
  • Professional programming language
  • Sound — BEEP w/ pitch & duration
  • Modular programs
  • FAST graphics
  • High speed LOAD and SAVE

“The world’s best personal computer for under £500.”

The Project

We’ve time-travelled back to the 1980s and changed the past…
A home computer classic modified with the power of Retrofabulation™

The same hardware constraints, turbocharged with today’s software knowledge. Could it have been faster, funner, better, knowing what we know now?

Yes.

Improving on a classic

Isomorphic translation

The user’s program is held as text while they type; as compact tokens for listing; and as fast, VM bytecode at runtime, converting back whenever needed. That gives us readable listings and extremely fast execution speed, without wasting memory.

16 colours

The original Spectrum spent one attribute bit per screen block on a rarely-used FLASH code. If we reclaim that bit as a second brightness bit, a cell's two colours can each be bright or normal, for a full 16-colour palette, two colours per cell, and occupying the same amount of screen memory.

More readable text

Characters are spaced semi-proportionally on a 4×8 pixel-grid, so text reads more easily. The space character is 4 pixels wide, so it kicks the next word into the next colour cell: individual words can be coloured differently without colour-clash.

Reusing Open Source

Forty years of code from enthusiasts and volunteers: Let’s bring it back to the 80s for everyone to enjoy.

Bresenham's line and circle routines run 50× faster than Sinclair's originals.

Built-in sprite and scrolling primitives elevate what a beginner can achieve in a few lines of code.

Modern turbo-loaders can reliably LOAD and SAVE up to 20% faster than the original ROM.

Structured coding

Structured code can run faster than GOTO-based BASIC — as BBC BASIC proved — and it's easier to learn, and it instills good habits from the start.

More detail in next section.

BONUS! Magazine mode

Typing hex listings from magazines was the bane of every micro-user's life. A built-in mode for entering machine code, with user-friendly error detection and correction: it could have saved tens of thousands of child-typing-hours across the world!

A New Old Language

A modern, structured programming language, targetted at a micro with limited RAM. Organisational structures include functions/procedures and modules.

import gfx as g
import time as t

let cx% = 126; let cy% = 66 # centre
drawNumbers( cx% // 4, cy% // 8 )
let r# = 60 # Length of second hand
let sx% = cx%; let sy% = cy% # ‘previous’
g.mode( "xor" )
loop:
 t.waitFrame()
 let s# = t.uptime() % 60.0
 let a# = s# / 30 × π # Angle of sec hand
 g.moveTo( cx%, cy% )
 g.line( sx#, sy# ) # Erase previous
 sx% = r# × sin(a); sy% = r# × cos(a)
 g.moveTo( cx%, cy% )
 g.line(sx#, sy#) # Draw new one

def drawNumbers( x%, y% ):
 for h% in range( 1, 12 ):
  let a# = ( h% / 12 ) × π × 2
  at( x% + 20 × sin( a ), y% - 10 × cos( a ) )
  print( h% )
1 2 3 4

1Modules

Modules can be built-in (ROM), loaded from tape, or defined as part of the program. They help organise the code, and keep code navigation fast.

Modules promote extensibility too: type in a module from a computer magazine, and easily use that feature in your programs.

2Maximum readability

Syntax colouring, proportional font, and automatic block indentation.

Code is as readable as it could be on a 1980s TV screen.

3Block-structure

A block-structured language, in the style of 1991’s Python.

Control flow is explicit and clear, which is great for beginners. The unambiguous structure also helps it be very fast to execute.

4Static typing & sigils

A compromise between performance and compactness-of-code, identifiers can include BASIC-style sigils to indicate the type of the value: $ for strings; % for integers; # for real numbers.

Performance is a feature

Code editor, keypress to screen update response time
20ms
worst case, at maximum line length
Bytecode interpreter, fetch-and-dispatch overhead
15µs
Fill the whole screen with text
200ms
900 characters, mix of widths

A new face for the old Speccy... 1 2 3

[Font sample showing two lines of nonsense text.]

Font features

  1. A remarkably consistent x-height, despite the tight 8-pixel grid, makes for a steady visual rhythm and easy reading.
  2. At small sizes and on a fuzzy TV, similar letterforms blur together. So the ‘h’ and ‘n’ are kept distinct, and confusable sets like 1, I, l (one, capital-i, el) have been carefully designed for clarity.
    In printed hex output, 0, B, 8 are easily confusable too. We’ve designed for that.
  3. A little attitude in shapes like the ‘o’/‘p’ and ‘v’/‘w’ keeps things lively.

Character set

The character set includes support for most European languages, plus common typographical and mathematical symbols.

It’s ASCII-compatible (of course), and includes almost the whole repertoires of the Amiga’s Latin-1 (1985), Mac Roman (1984) and Windows Codepage 1252 (1987).

This means that as well as © (copyright symbol), there’s ™ and ®; punctuation like proper ‘quote marks’ French «guillemots» and bullets •. Maths, including ≠ (not-equal) and π (tasty). And letters for writing Scandinavian languages, like þÞ and Ðð.

Café mañana

Many 1980s computers represented accented characters — like the é in café, or ü in Mötley Crüe — as individual, whole characters, but this takes up a lot of space in ROM; there are dozens of common combinations, especially when you add capitals and lower-case: É é ä ö ï ü à À…

We encode diacritical marks as separate code-points, so they can be composed with almost any other letter. This reduces the size of the font in ROM, and increases its expressability.

IN PROGRESS

Explore the font

$ 41
Unicode equivalent: U+0041

Back to the . . . Present

Andrew, the maker of RetroFabulation ZX

Biography

I woke up one morning in February 2024 with the idea almost fully-formed: a grand, spurious ‘what if’ reimagining of the ZX Spectrum’s system software.

I had specific ideas about enabling a little, beginner-freindly language to run really fast on the Z80. I was sure we could (re)make the rest of it qualitively, and palpably ‘better’ too.

Why? Because it’s there.

It’s become a bit of an personal obsession; an itch I’ve enjoyed scratching. We seem to be amidst a retro-computing revival, so perhaps you’ll enjoy seeing where this goes too.


Andrew Forrest is a professional software engineer based in Glasgow. He got his Computer Science degree from the University of Strathclyde in 1995 and in the decades since, he has developed systems for recycling companies, well-known Scottish food companies, the power-generation industry, and the Scottish government. He’s always enjoyed a bit of digital archeology too: pulling apart ancient legacy systems and making them work better.

He learned to program on the family ZX81, then later on ZX Spectrum and Commodore Amiga. These days he uses a Mac. Sometimes he performs in plays and musicals.

If you have a problem, if noone else can help, and if you can find him on LinkedIn, maybe you can hire, the A.

Interested?
Follow The Project.

We're working toward a Kickstarter campaign to fund the final stages of development. Leave your email and we'll send you one message when it launches — plus some very occasional update messages.

No spam or ads. One message when the Kickstarter launches, plus irregular updates. Unsubscribe whenever you want.