Weft-8 Classroom

nine exercises · a real 8-bit machine · one lesson

How a computer
actually works.

Not a simulation of a lesson about computers — a computer. Sixteen registers, four flags, twenty-seven instructions, and no if statement, so the student builds one. Every exercise starts incomplete: the machine runs, does something, and the class can see exactly what is missing.

exercise 6 · call a subroutine
        CALL seven
        ; ... and now? R3 must hold 9
        HLT
seven:  LDI 7
        MOV R4, R0
        ; how do you get back?
if you never come back, R3 stays 0 — and the machine will tell you.

The nine

About 50–70 minutes for a first lesson, and every one of them is checked by the machine, not by the teacher.

01

Put a number somewhere

LDI fills the accumulator, MOV moves it

02

Add two numbers

what ADD Ra, Rb really means

03

Double a number

SHL is multiply-by-two

04

Count to ten

a loop needs a counter and a branch

05

Remember something

STORE and LOAD reach RAM

06

Call a subroutine

CALL pushes, RET pops — and the code after proves it

07

Decide something

CMP sets the flags, JZ branches — this is your first if

08

Say something out loud

OUT hands a byte to a port

What makes it teachable

the weft-8 family — one machine, seven faces

the Loomthe machine and its editor — where it all starts Weft Puzzlesfive puzzles solved in assembly, a robot on a grid Clip Loomclipboard programs you can read: strip, squeeze, wrap Weft-8 on hardwarethe same machine in C, three-way parity with the JS one weft8-kitrules small enough to sign off
Weft-8 Classroomyou are here
Weft-8 beside x86 and ARMthe same four jobs in three machines

Every one of these runs the same engine — weft8.js from the Loom, byte for byte. Learn it once and you have learned all seven.