Description #
Z80 Assembly is the low-level language for the Zilog Z80 microprocessor, popular in early personal computers and embedded systems. It extends the Intel 8080 instruction set with additional registers and instructions.
History #
Introduced in 1976, the Z80 powered machines like the ZX Spectrum, TRS-80, and Game Boy. It became widely adopted for its enhanced features and compatibility with 8080 software.
Hello World Code #
(Similar to 6502, output routines depend on hardware; here is a conceptual example)
LD HL, message
print_loop:
LD A, (HL)
CP 0
JR Z, done
CALL print_char ; hypothetical print routine
INC HL
JR print_loop
done:
RET
message:
DB "Hello, World!", 0
How to Run #
Option 1: Online
Try Z80 assembly with Z80 Online Assembler.
Option 2: Local
Key Concepts #
- 8-bit architecture with extended registers (IX, IY)
- Compatible with Intel 8080 instructions
- Rich set of addressing modes and instructions
- Widely used in home computers and embedded devices
- Supports interrupts, I/O ports, and timers
- Assembly programming requires hardware knowledge
- Used in educational retro computing projects
- Has a mature ecosystem of assemblers and tools
- Can interface with various peripherals via ports
- Enables efficient low-level programming
Try It Online #
Fun Facts #
- The Game Boy’s CPU is a modified Z80 variant.
- The ZX Spectrum popularized home computing in the UK using Z80.
- Z80 added instructions for block moves and bit manipulation over 8080.
- The CPU remained in production for decades due to its popularity.
- Enthusiasts still program and emulate Z80 systems worldwide.