.png)
Because on a machine this small, you can understand the whole thing.
A modern computer is built in layers, and almost all of them are hidden from you. Somewhere underneath the app you are using there is a processor doing one small thing at a time, but you will never see it, and nothing you do on a modern machine will show it to you.
An Einstein will. There are no layers here to speak of. You write an instruction, the processor carries it out, and something happens on screen. When your game runs slowly, the reason is a number you can count. When it breaks, the cause is somewhere inside a machine small enough to hold in your head. Everything on screen is there because you put it there, one byte at a time - and by the end of this course you will know exactly how each one got there.
You will also see where a lot of modern computing came from. Characters, memory addresses, interrupts, the loop that redraws the screen sixty times a second: these ideas are all here, in their simplest form, close enough to touch.
And it is satisfying. Moving something around the screen with code you wrote yourself, on a machine you understand completely, is a different feeling from watching something move because you called a function that somebody else wrote.
The Tatung Einstein is a British computer built around the Zilog Z80 processor - the same chip as the ZX Spectrum and the Amstrad CPC, though the machine around it is quite different. The ROM it boots from is dated 1983 and 1984.
It was aimed at small businesses and schools rather than the games market, and it never sold in the numbers the Spectrum did. That is part of the appeal. It is a capable little machine that comparatively few people have written games for, which means there is room to do something new on it.
You do not need to own one. Everything in this course runs on an emulator on your own computer, and the next section gets that working.
The goal is a complete game, written entirely in Z80 assembly, running on the Einstein. By the end you will be able to:
You will not start there. You start by getting a single word onto the screen, because before anything else you need to know that your code assembles, loads and runs. From there the course builds up in steps, each one adding a piece you will still be using at the end:
Each section leaves you with a program that runs. Nothing is left as an exercise for later, and you are never asked to type in code that will only make sense in three sections' time.
Nothing.
You do not need to have programmed before, in assembly or in anything else. Registers, addresses, flags and the general business of a processor with nowhere to hide are all explained in plain English as they come up, in the order you need them, and nothing is assumed that has not been covered.
If you have programmed before, you will move faster, and you should expect assembly to feel strange rather than difficult. There are no variables, no functions in the sense you are used to, and no types. There is a small set of places to put numbers and a small set of things you can do to them, and everything else is built out of that.
If you have written assembly for another eight-bit machine, you will move faster still. Be ready for some of your habits to need adjusting: every one of these machines handles graphics and input its own way, and the Einstein is not the machine you learned on.
Four things, all free:
The next section installs all of it and finishes with an Einstein booting on your own machine. Nothing in this course asks you to buy anything.
From here, every section follows the same shape.
| Part | What it is for |
|---|---|
| Why this matters | The problem your game runs into without this. |
| The explanation | What the machine does, how to make it do it, and what it costs you - in cycles, in bytes, or in a register you no longer have free. |
| The code | A complete program you can assemble and run. Short, and with nothing in it left unexplained. |
| Change one thing | Two or three small edits to make yourself, each with a question attached. |
| When it goes wrong | The mistakes that are easy to make here, and what they look like on screen. |
| Summary | What you can now do. |
Type the programs in and run them. Then do Change one thing, which is where most of the learning actually happens. Reading a listing that works gives you the feeling of understanding it, and that feeling is hard to tell apart from the real thing until something breaks. Changing one value, guessing what will happen and then finding out is quick, and it tells you honestly whether you have got it.
S2. Setting up. Installing the assembler, the emulator, the editor and the extension that joins them together, and booting an Einstein for the first time.