The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

CPU::Z80::Assembler::AsmTable - Z80 assembly/disassembly table

SYNOPSIS

  use CPU::Z80::Assembler::AsmTable;
  asm_table()->{asm}{"adc"}{"a"}{","}{"("}{"hl"}{")"}{""} is [0x8E]
  asm_table()->{disasm}{0x8E}{""} is ["adc", "a", ",", "(", "hl", ")"]

DESCRIPTION

This module provides a single function that returns a complete Z80 assembly / disassembly hash table.

EXPORTS

By default the "asm_table" subroutine is exported.

FUNCTIONS

asm_table

This function returns the assembly/disassembly hash table.

Starting at the "asm" key, and following one sub-hash table for each token, with an empty token at the end of the list produces an array of opcode bytes of the corresponding Z80 assembly.

Starting at the "disasm" key, and following one sub-hash table for each opcode byte, with an empty byte at the end of the list, produces an array of tokens of the corresponding disassembled Z80 instruction.

The following special tokens are defined:

N

One byte;

NN

One word;

NNl

The low byte of the word;

NNh

The high byte of the word;

NNo

The offset byte of a JR/DJNZ instruction that is converted to NN by adding address + 1;

DIS

The offset of a (ix+DIS) expression;

NDIS

The offset of a (ix-NDIS) expression.

BUGS and FEEDBACK

See CPU::Z80::Assembler.

SEE ALSO

CPU::Z80::Assembler

AUTHORS, COPYRIGHT and LICENCE

See CPU::Z80::Assembler.