Hacker News new | ask | show | jobs
by libraryofbabel 56 days ago
Much nostalgia. The TI-83 Z80 was how I learned assembly as a teenager, so I could write better calculator games than was possible with TI Basic. Many others here had a similar experience, I’m sure. It’s been a couple decades, but I’m sure I’d still remember most of it if you put me down in front of a bunch of Z80 asm code.

One thing that I remember vividly was you had no MUL or DIV, so you have to implement them yourself with shifts, adds, subtraction, etc. This was an extremely useful learning experience

2 comments

Same story here (basic was too slow for a phoenix/movable-ship-shooter game).

Do you think you could remember most of Z80 ASM? I looked at some old ASM I wrote long ago, and it's hard to follow the logic of the program, since most lines are messing around with the registers. But basics like 'ld hl,xyz' and 'jp/jnz' still make sense.

> Do you think you could remember most of Z80 ASM?

I find when you learn things at 15 they tend to stick around. (Stuff I learned last week, not so much!) Even just looking at your example, I remembered that HL is a 16 bit register and you can split it into two 8 bit registers H and L if you want. I think most of it would come back; I wrote quite a lot of it, both for the TI-83 and later for a Z80 that I bought and put on a breadboard and wired up to some RAM and EEPROM, about as bare metal as it gets.

> most lines are messing around with the registers

Isn’t that just the nature of assembly? :)

I learned much of what I know about computer and low-level systems engineering from Minecraft. Watched lots of videos making CPUs and built many components myself including a full ALU with a look-ahead adder and hardware multiplication.